core 1.5.0
Shared MPI block decomposition, asynchronous ghost-layer exchange, SDF geometry, load balancing (header-only C++20)
Loading...
Searching...
No Matches
scene.hpp File Reference

Go to the source code of this file.

Classes

struct  peclet::core::geom::GridDesc< Real >
 Descriptor for one sampled field inside a shared sample pool. More...
 
struct  peclet::core::geom::Transform< Real >
 Conformal placement: canonical -> parent frame. Identity by default. More...
 
struct  peclet::core::geom::ShapeNode< Real >
 One node of a flat shape tree. POD, trivially copyable, safe in a Kokkos View. More...
 
struct  peclet::core::geom::PoolPtr< T >
 Adaptors so a raw pointer can stand in for a Kokkos View (Views already provide operator()), letting host tests and device kernels share one evaluator. More...
 
struct  peclet::core::geom::TablePtr< T >
 
struct  peclet::core::geom::Instance< Real >
 One placed copy of a shape tree (contract 7). More...
 
struct  peclet::core::geom::SceneView< Real >
 Non-owning bundle of everything a scene evaluation needs (resolved decision 4). More...
 

Namespaces

namespace  peclet
 
namespace  peclet::core
 
namespace  peclet::core::geom
 

Enumerations

enum  peclet::core::geom::ShapeKind : int {
  peclet::core::geom::kGrid = 0 , peclet::core::geom::kSphere = 1 , peclet::core::geom::kHollowCylinder = 2 , peclet::core::geom::kBox = 3 ,
  peclet::core::geom::kHollowCylinderShell = 4 , peclet::core::geom::kCapsule = 5 , peclet::core::geom::kTorus = 6 , peclet::core::geom::kCone = 7 ,
  peclet::core::geom::kEllipsoid = 8 , peclet::core::geom::kSuperquadric = 9 , peclet::core::geom::kCsgBase = 32 , peclet::core::geom::kUnion = 32 ,
  peclet::core::geom::kIntersection = 33 , peclet::core::geom::kDifference = 34
}
 Node kind tag. More...
 
enum class  peclet::core::geom::GridExtension : int { peclet::core::geom::kObject = 0 , peclet::core::geom::kContainer = 1 , peclet::core::geom::kClamp = 2 }
 NOT YET A NODE KIND: prim::Rounded (offset/rounding) stays a compile-time wrapper for now. More...
 

Functions

template<class Real >
PECLET_HD Vec3< Real > peclet::core::geom::toCanonical (const Transform< Real > &tr, Vec3< Real > p)
 Map a point from the parent frame into this transform's canonical frame.
 
template<class Real , class Pool >
PECLET_HD Real peclet::core::geom::sampleGrid (Vec3< Real > p, const GridDesc< Real > &d, const Pool &pool)
 Trilinear sample of a grid field, with the clamp-plus-residual off-grid extension selected by d.extension.
 
template<class Real , class Grids , class Pool >
PECLET_HD Real peclet::core::geom::evalLeaf (const ShapeNode< Real > &n, Vec3< Real > p, const Grids &grids, const Pool &pool)
 Evaluate a single LEAF node at a point already in that node's canonical frame.
 
template<class Real >
PECLET_HD Vec3< Real > peclet::core::geom::instanceCentre (const Instance< Real > &inst)
 Rigid-body surface velocity of instance inst at world point p: linVel + angVel x (p - c), with c the pinned centre when there is one and the body's translation otherwise (an unpinned center is the NaN sentinel and must never enter the arithmetic).
 
template<class Real >
PECLET_HD Vec3< Real > peclet::core::geom::instanceVelocity (const Instance< Real > &inst, Vec3< Real > p)
 
template<class Real , class Nodes , class Grids , class Pool >
PECLET_HD Real peclet::core::geom::evalTree (const Nodes &nodes, int nodeCount, int root, Vec3< Real > p, const Grids &grids, const Pool &pool)
 Evaluate the shape tree rooted at root at point p (in the root's parent frame).
 
template<class Real , class Grids , class Pool >
PECLET_HD Vec3< Real > peclet::core::geom::leafGrad (const ShapeNode< Real > &n, Vec3< Real > p, const Grids &grids, const Pool &pool)
 Closed-form gradient of one leaf in its canonical frame (unnormalised, mirroring the prim::* contracts).
 
template<class Real , class Nodes , class Grids , class Pool >
PECLET_HD Real peclet::core::geom::evalTreeGrad (const Nodes &nodes, int nodeCount, int root, Vec3< Real > p, const Grids &grids, const Pool &pool, Vec3< Real > &grad)
 evalTree WITH its analytic gradient, one traversal (Layer 0's runtime layer catching up with the compile-time leaves' exact grads).
 
template<class Real >
PECLET_HD Real peclet::core::geom::evalInstance (const SceneView< Real > &sc, int i, Vec3< Real > p)
 Signed distance of ONE instance at world point p.
 
template<class Real >
PECLET_HD Real peclet::core::geom::evalCandidates (const SceneView< Real > &sc, Vec3< Real > p, const int *candidates, int nCandidates)
 Signed distance of a scene over a CANDIDATE LIST (contract 9): the union of the listed instances, i.e.
 
template<class Real >
PECLET_HD Real peclet::core::geom::evalScene (const SceneView< Real > &sc, Vec3< Real > p)
 Convenience: the union of EVERY instance.
 

Variables

constexpr int peclet::core::geom::kMaxTreeDepth = 16
 Maximum shape-tree depth the iterative evaluator supports.