|
EBGeometry
Compact, header-only C++ library for fast evaluation of signed distance functions
|
Implicit function whose interior is a smoothly blended union of all input function interiors. More...
#include <EBGeometry_CSG.hpp>


Public Member Functions | |
| SmoothUnionIF ()=delete | |
| Disallowed, use the full constructor. | |
| SmoothUnionIF (const std::vector< std::shared_ptr< ImplicitFunction< T > > > &a_implicitFunctions, const T a_smoothLen, const std::function< T(const T &a, const T &b, const T &s)> a_smoothMin=SmoothMin< T >) | |
| Constructs the smooth union of the given implicit functions. | |
| ~SmoothUnionIF () override=default | |
| Destructor. | |
| T | value (const Vec3T< T > &a_point) const noexcept override |
| Evaluates the smoothly blended signed distance at a_point. | |
Public Member Functions inherited from EBGeometry::ImplicitFunction< T > | |
| ImplicitFunction ()=default | |
| Default constructor. | |
| virtual | ~ImplicitFunction ()=default |
| Default destructor. | |
| T | operator() (const Vec3T< T > &a_point) const noexcept |
| Call operator — alternative signature for the value function. | |
| template<class BV > | |
| BV | approximateBoundingVolumeOctree (const Vec3T< T > &a_initialLowCorner, const Vec3T< T > &a_initialHighCorner, const unsigned int a_maxTreeDepth, const T &a_safety=0.0) const |
| Compute an approximation to the bounding volume for the implicit surface using octree subdivision. | |
Protected Attributes | |
| std::vector< std::shared_ptr< const ImplicitFunction< T > > > | m_implicitFunctions |
| Stored implicit functions. | |
| T | m_smoothLen |
| Smoothing length. | |
| std::function< T(const T &, const T &, const T &)> | m_smoothMin |
| Smooth-minimum operator. | |
Implicit function whose interior is a smoothly blended union of all input function interiors.
Replaces the sharp min of UnionIF with a smooth-minimum operator, yielding a C1 (or better) interface where interiors overlap. Only the two closest values are blended; the blend region width is controlled by m_smoothLen.
| T | Floating-point precision. |
| EBGeometry::SmoothUnionIF< T >::SmoothUnionIF | ( | const std::vector< std::shared_ptr< ImplicitFunction< T > > > & | a_implicitFunctions, |
| const T | a_smoothLen, | ||
| const std::function< T(const T &a, const T &b, const T &s)> | a_smoothMin = SmoothMin< T > |
||
| ) |
Constructs the smooth union of the given implicit functions.
| [in] | a_implicitFunctions | List of implicit functions (must be non-empty; no null entries). |
| [in] | a_smoothLen | Smoothing length (must be > 0). |
| [in] | a_smoothMin | Smooth-minimum operator; defaults to SmoothMin<T>. |
|
overridevirtualnoexcept |
Evaluates the smoothly blended signed distance at a_point.
Finds the two closest function values and applies the stored smooth-minimum operator. Negative when inside the smooth union.
| [in] | a_point | 3D query point. |
Implements EBGeometry::ImplicitFunction< T >.