PhysicsBasedAnimationToolkit 0.0.10
Cross-platform C++20 library of algorithms and data structures commonly used in computer graphics research on physically-based simulation.
Loading...
Searching...
No Matches
pbat::geometry::sdf::RotationalRepeat< TScalar > Struct Template Reference

Circular repetition operation around axe. More...

#include <UnaryNode.h>

Inheritance diagram for pbat::geometry::sdf::RotationalRepeat< TScalar >:
pbat::geometry::sdf::UnaryNode

Public Types

using ScalarType = TScalar
 Scalar type.
 

Public Member Functions

 RotationalRepeat ()=default
 Default constructor.
 
 RotationalRepeat (ScalarType n_)
 Construct a new RotationalRepeat object.
 
template<class FSdf>
PBAT_HOST_DEVICE ScalarType Eval (Vec3< ScalarType > const &p, FSdf &&sdf) const
 Evaluate the signed distance function at a point.
 

Public Attributes

ScalarType n {TScalar(1)}
 Number of repetitions.
 

Detailed Description

template<common::CArithmetic TScalar>
struct pbat::geometry::sdf::RotationalRepeat< TScalar >

Circular repetition operation around axe.

Template Parameters
TScalarScalar type

Constructor & Destructor Documentation

◆ RotationalRepeat()

template<common::CArithmetic TScalar>
pbat::geometry::sdf::RotationalRepeat< TScalar >::RotationalRepeat ( ScalarType n_)
inlineexplicit

Construct a new RotationalRepeat object.

Parameters
n_Number of repetitions

Member Function Documentation

◆ Eval()

template<common::CArithmetic TScalar>
template<class FSdf>
PBAT_HOST_DEVICE ScalarType pbat::geometry::sdf::RotationalRepeat< TScalar >::Eval ( Vec3< ScalarType > const & p,
FSdf && sdf ) const
inline

Evaluate the signed distance function at a point.

Template Parameters
FSdfCallable type with signature ScalarType(Vec3<ScalarType> const&)
Parameters
p3 x 1 query point in 3D space
sdfInput SDF
Returns
Signed distance to the repeated shape

The documentation for this struct was generated from the following file: