EBGeometry
1.0
|
Declaration of various analytic distance functions. More...
#include <algorithm>
#include <random>
#include "EBGeometry_BoundingVolumes.hpp"
#include "EBGeometry_SignedDistanceFunction.hpp"
#include "EBGeometry_NamespaceHeader.hpp"
#include "EBGeometry_NamespaceFooter.hpp"
Go to the source code of this file.
Classes | |
class | PlaneSDF< T > |
Signed distance function for a plane. More... | |
class | SphereSDF< T > |
Signed distance field for sphere. More... | |
class | BoxSDF< T > |
Signed distance field for an axis-aligned box. More... | |
class | TorusSDF< T > |
Signed distance field for a torus. More... | |
class | CylinderSDF< T > |
Signed distance field for a cylinder. More... | |
class | InfiniteCylinderSDF< T > |
Inifinitely long cylinder class. Oriented along the y-axis. More... | |
class | CapsuleSDF< T > |
Capsulate/pill SDF. Basically a cylinder with spherical endcaps, oriented along the specified axis. More... | |
class | InfiniteConeSDF< T > |
Signed distance field for an infinite cone. Oriented along +z. More... | |
class | ConeSDF< T > |
Signed distance field for an finite cone. Oriented along +z. More... | |
class | RoundedBoxSDF< T > |
Box of arbitrary dimensions centered at the origin, with rounded corners. More... | |
class | PerlinSDF< T > |
Ken Perlins gradient noise function. More... | |
Functions | |
template<class T > | |
constexpr const T | clamp (const T &v, const T &lo, const T &hi) |
Clamp function. Returns lo if v < lo and hi if v > hi. Otherwise returns v. More... | |
template<class T > | |
constexpr const Vec3T< T > | clamp (const Vec3T< T > &v, const Vec3T< T > &lo, const Vec3T< T > &hi) |
Clamp function. Returns lo if v < lo and hi if v > hi. Otherwise returns v. More... | |
Declaration of various analytic distance functions.
This file contains various analytic signed distance fields. Some of these also include member function for fetching parameters, and users are free to add such functions also to other shapes.
|
constexpr |
Clamp function. Returns lo if v < lo and hi if v > hi. Otherwise returns v.
[in] | v | Value to be clamped. |
[in] | lo | Lower clamping value. |
[in] | hi | Higher clamping value. |
|
constexpr |
Clamp function. Returns lo if v < lo and hi if v > hi. Otherwise returns v.
[in] | v | Value to be clamped. |
[in] | lo | Lower clamping value. |
[in] | hi | Higher clamping value. |