A cone (3 dimensions)
More...
#include <sdf_shape_3D.h>
|
const coord_3d | apex |
| The apex.
|
|
const double | c |
| The radius.
|
|
const coord_3d | dir |
| The direction of the axis, from the apex INSIDE.
|
|
A cone (3 dimensions)
The cone is defined by
where is along the cone's axis.
◆ SDFCone()
madness::SDFCone::SDFCone |
( |
const double |
c, |
|
|
const coord_3d & |
apex, |
|
|
const coord_3d & |
direc |
|
) |
| |
|
inline |
Constructor for cone.
- Parameters
-
c | Parameter in the definition of the cone |
apex | Apex of cone |
direc | Oriented axis of the cone |
◆ grad_sdf()
Computes the gradient of the SDF.
- Parameters
-
pt | Point at which to compute the gradient |
- Returns
- the gradient
References MADNESS_EXCEPTION.
◆ sdf()
double madness::SDFCone::sdf |
( |
const coord_3d & |
pt | ) |
const |
|
inline |
Computes the normal distance.
This SDF naively uses contours, and should be improved before serious usage.
- Parameters
-
pt | Point at which to compute the distance from the surface |
- Returns
- The signed distance from the surface
References apex, c, diff(), and dir.
◆ apex
The apex.
Referenced by sdf().
const double madness::SDFCone::c |
|
protected |
The radius.
Referenced by sdf().
◆ dir
The direction of the axis, from the apex INSIDE.
Referenced by sdf().
The documentation for this class was generated from the following file: