A circle (2 dimensions)
More...
#include <sdf_shape_2D.h>
◆ SDFCircle()
madness::SDFCircle::SDFCircle |
( |
const double |
radius, |
|
|
const coord_2d & |
center |
|
) |
| |
|
inline |
SDF for a sphere.
- Parameters
-
radius | The radius of the sphere |
center | The center of the sphere |
◆ grad_sdf()
Computes the gradient of the SDF.
- Parameters
-
pt | Point at which to compute the gradient |
- Returns
- the gradient
References center, and madness::g.
◆ sdf()
double madness::SDFCircle::sdf |
( |
const coord_2d & |
pt | ) |
const |
|
inline |
Computes the normal distance.
This SDF is exact, and easy to show.
- Parameters
-
pt | Point at which to compute the distance from the surface |
- Returns
- The signed distance from the surface
References center, and radius.
◆ center
const coord_2d madness::SDFCircle::center |
|
protected |
◆ radius
const double madness::SDFCircle::radius |
|
protected |
Radius of circle.
Referenced by sdf().
The documentation for this class was generated from the following file: