EBGeometry
Compact, header-only C++ library for fast evaluation of signed distance functions
Loading...
Searching...
No Matches
Classes | Namespaces | Functions | Variables
EBGeometry_CSG.hpp File Reference

Declaration of CSG operations for implicit functions. More...

#include <algorithm>
#include <cmath>
#include <cstddef>
#include <functional>
#include <memory>
#include <type_traits>
#include <utility>
#include <vector>
#include "EBGeometry_BVH.hpp"
#include "EBGeometry_ImplicitFunction.hpp"
#include "EBGeometry_Macros.hpp"
#include "EBGeometry_Vec.hpp"
#include "EBGeometry_CSGImplem.hpp"
Include dependency graph for EBGeometry_CSG.hpp:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Classes

class  EBGeometry::UnionIF< T >
 Implicit function whose interior is the union of all input function interiors. More...
 
class  EBGeometry::SmoothUnionIF< T >
 Implicit function whose interior is a smoothly blended union of all input function interiors. More...
 
class  EBGeometry::BVHUnionIF< T, P, BV, K >
 BVH-accelerated union of implicit functions. More...
 
class  EBGeometry::BVHSmoothUnionIF< T, P, BV, K >
 BVH-accelerated smooth union of implicit functions. More...
 
class  EBGeometry::IntersectionIF< T >
 Implicit function whose interior is the intersection of all input function interiors. More...
 
class  EBGeometry::SmoothIntersectionIF< T >
 Implicit function whose interior is a smoothly blended intersection of all input function interiors. More...
 
class  EBGeometry::DifferenceIF< T >
 Implicit function whose interior is the set difference A \ B. More...
 
class  EBGeometry::SmoothDifferenceIF< T >
 Implicit function representing a smoothly blended set difference A \ B. More...
 
class  EBGeometry::FiniteRepetitionIF< T >
 Implicit function that tiles a base function periodically within a finite repetition count. More...
 

Namespaces

namespace  EBGeometry
 Namespace containing all of EBGeometry's functionality.
 

Functions

template<class T , class P = ImplicitFunction<T>>
std::shared_ptr< ImplicitFunction< T > > EBGeometry::Union (const std::vector< std::shared_ptr< P > > &a_implicitFunctions)
 Constructs an implicit function whose interior is the union of the interiors of all input functions.
 
template<class T , class P1 , class P2 >
std::shared_ptr< ImplicitFunction< T > > EBGeometry::Union (const std::shared_ptr< P1 > &a_implicitFunctionA, const std::shared_ptr< P2 > &a_implicitFunctionB)
 Constructs an implicit function whose interior is the union of the interiors of A and B.
 
template<class T , class P = ImplicitFunction<T>>
std::shared_ptr< ImplicitFunction< T > > EBGeometry::SmoothUnion (const std::vector< std::shared_ptr< P > > &a_implicitFunctions, const T a_smooth)
 Constructs an implicit function whose interior is a smoothly blended union of all input function interiors.
 
template<class T , class P1 , class P2 >
std::shared_ptr< ImplicitFunction< T > > EBGeometry::SmoothUnion (const std::shared_ptr< P1 > &a_implicitFunctionA, const std::shared_ptr< P2 > &a_implicitFunctionB, const T a_smooth)
 Constructs an implicit function whose interior is a smoothly blended union of the interiors of A and B.
 
template<class T , class P , class BV , size_t K>
std::shared_ptr< ImplicitFunction< T > > EBGeometry::BVHUnion (const std::vector< std::shared_ptr< P > > &a_implicitFunctions, const std::vector< BV > &a_boundingVolumes)
 Constructs a BVH-accelerated union of implicit functions.
 
template<class T , class P , class BV , size_t K>
std::shared_ptr< ImplicitFunction< T > > EBGeometry::BVHSmoothUnion (const std::vector< std::shared_ptr< P > > &a_implicitFunctions, const std::vector< BV > &a_boundingVolumes, const T a_smoothLen) noexcept
 Constructs a BVH-accelerated smooth union of implicit functions.
 
template<class T , class P >
std::shared_ptr< ImplicitFunction< T > > EBGeometry::Intersection (const std::vector< std::shared_ptr< P > > &a_implicitFunctions)
 Constructs an implicit function whose interior is the intersection of the interiors of all input functions.
 
template<class T , class P1 , class P2 >
std::shared_ptr< ImplicitFunction< T > > EBGeometry::Intersection (const std::shared_ptr< P1 > &a_implicitFunctionA, const std::shared_ptr< P2 > &a_implicitFunctionB)
 Constructs an implicit function whose interior is the intersection of the interiors of A and B.
 
template<class T , class P >
std::shared_ptr< ImplicitFunction< T > > EBGeometry::SmoothIntersection (const std::vector< std::shared_ptr< P > > &a_implicitFunctions, const T a_smooth)
 Constructs an implicit function whose interior is a smoothly blended intersection of all input function interiors.
 
template<class T , class P1 , class P2 >
std::shared_ptr< ImplicitFunction< T > > EBGeometry::SmoothIntersection (const std::shared_ptr< P1 > &a_implicitFunctionA, const std::shared_ptr< P2 > &a_implicitFunctionB, const T a_smooth)
 Constructs an implicit function whose interior is a smoothly blended intersection of the interiors of A and B.
 
template<class T , class P1 = ImplicitFunction<T>, class P2 = ImplicitFunction<T>>
std::shared_ptr< ImplicitFunction< T > > EBGeometry::Difference (const std::shared_ptr< P1 > &a_implicitFunctionA, const std::shared_ptr< P2 > &a_implicitFunctionB)
 Constructs an implicit function whose interior is the set difference A \ B.
 
template<class T , class P1 = ImplicitFunction<T>, class P2 = ImplicitFunction<T>>
std::shared_ptr< ImplicitFunction< T > > EBGeometry::SmoothDifference (const std::shared_ptr< P1 > &a_implicitFunctionA, const std::shared_ptr< P2 > &a_implicitFunctionB, const T a_smoothLen)
 Constructs an implicit function representing a smoothly blended set difference A \ B.
 
template<class T , class P = ImplicitFunction<T>>
std::shared_ptr< ImplicitFunction< T > > EBGeometry::FiniteRepetition (const std::shared_ptr< P > &a_implicitFunction, const Vec3T< T > &a_period, const Vec3T< T > &a_repeatLo, const Vec3T< T > &a_repeatHi)
 Constructs a periodically tiled implicit function with finite extent.
 

Variables

template<class T >
std::function< T(const T &a, const T &b, const T &s)> EBGeometry::ExpMin
 Exponential smooth minimum for blending two signed-distance values.
 
template<class T >
std::function< T(const T &a, const T &b, const T &s)> EBGeometry::SmoothMin
 Quadratic polynomial smooth minimum for blending two signed-distance values.
 
template<class T >
std::function< T(const T &a, const T &b, const T &s)> EBGeometry::SmoothMax
 Quadratic polynomial smooth maximum for blending two signed-distance values.
 

Detailed Description

Declaration of CSG operations for implicit functions.

Author
Robert Marskar