core 1.8.1
Shared MPI block decomposition, asynchronous ghost-layer exchange, SDF geometry, load balancing (header-only C++20)
Loading...
Searching...
No Matches
peclet::core::geom::prim::Rounded< Shape > Struct Template Reference

Offset (rounded) shape: the inner solid grown outward by radius. More...

#include <primitives.hpp>

Public Types

using value_type = typename Shape::value_type

Public Member Functions

template<class Real>
PECLET_HD Real eval (Vec3< Real > p) const
template<class Real>
PECLET_HD Vec3< Real > grad (Vec3< Real > p) const

Public Attributes

Shape shape
value_type radius = value_type(0)

Static Public Attributes

static constexpr bool exact_distance = Shape::exact_distance
static constexpr bool analytic_gradient = Shape::analytic_gradient

Detailed Description

template<class Shape>
struct peclet::core::geom::prim::Rounded< Shape >

Offset (rounded) shape: the inner solid grown outward by radius.

Exactness is INHERITED – offsetting a true distance field by a constant is still a true distance field, which is why rounding is the cheapest way to get an exact rounded box or rounded cone.

Definition at line 405 of file primitives.hpp.

Member Typedef Documentation

◆ value_type

template<class Shape>
using peclet::core::geom::prim::Rounded< Shape >::value_type = typename Shape::value_type

Definition at line 406 of file primitives.hpp.

Member Function Documentation

◆ eval()

template<class Shape>
template<class Real>
PECLET_HD Real peclet::core::geom::prim::Rounded< Shape >::eval ( Vec3< Real > p) const
inline

Definition at line 413 of file primitives.hpp.

References PECLET_HD, radius, and shape.

◆ grad()

template<class Shape>
template<class Real>
PECLET_HD Vec3< Real > peclet::core::geom::prim::Rounded< Shape >::grad ( Vec3< Real > p) const
inline

Definition at line 417 of file primitives.hpp.

References PECLET_HD, and shape.

Member Data Documentation

◆ shape

template<class Shape>
Shape peclet::core::geom::prim::Rounded< Shape >::shape

Definition at line 407 of file primitives.hpp.

Referenced by eval(), and grad().

◆ radius

template<class Shape>
value_type peclet::core::geom::prim::Rounded< Shape >::radius = value_type(0)

Definition at line 408 of file primitives.hpp.

Referenced by eval().

◆ exact_distance

template<class Shape>
bool peclet::core::geom::prim::Rounded< Shape >::exact_distance = Shape::exact_distance
staticconstexpr

Definition at line 409 of file primitives.hpp.

◆ analytic_gradient

template<class Shape>
bool peclet::core::geom::prim::Rounded< Shape >::analytic_gradient = Shape::analytic_gradient
staticconstexpr

Definition at line 410 of file primitives.hpp.


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