Project
Loading...
Searching...
No Matches
o2::cad::surface::DummyBoundedSurface Class Referencefinal

A trivial bounded surface, a single 3D triangle, to exercise the BoundedSurface interface. More...

Inherits o2::cad::surface::BoundedSurface.

Public Member Functions

 DummyBoundedSurface (const Vec3 &firstVertex, const Vec3 &secondVertex, const Vec3 &thirdVertex)
 
void conservativeBounds (Vec3 &lower, Vec3 &upper) const override
 Accumulate a conservative axis-aligned bounding box of the trimmed patch.
 
bool containsPointOnSurface (const Vec3 &) const override
 True if the 3D point lies on the trimmed patch within tolerance.
 
void appendIntersections (const Vec3 &, const Vec3 &, double, double, std::vector< RayHit > &) const override
 Append every hit of the ray with the trimmed patch in [minDistance, maxDistance], with the outward normal; no tangential grazes.
 
double distanceSqToPatch (const Vec3 &point) const override
 Squared distance from a 3D point to the trimmed patch (used for Safety).
 
Vec3 normalAt (const Vec3 &) const override
 Outward-oriented normal at (or nearest to) the given point.
 
void parametricMetric (const Vec2 &, double &gUU, double &gUV, double &gVV) const override
 A triangle carries no parametric domain, so the form is the identity.
 
double capacityContribution () const override
 Signed divergence-theorem contribution to the enclosed volume.
 
bool capacityIsExact () const override
 Whether capacityContribution() is analytically exact for this surface.
 
void appendDisplayMesh (std::vector< Vec3 > &vertices, std::vector< std::array< int, 3 > > &triangles) const override
 Append this patch's visualization triangulation (navigation must never depend on it).
 
void appendDirectedEdges (std::vector< std::pair< Vec3, Vec3 > > &edges) const override
 Append the 3D directed boundary edges of the patch, for solid-closure validation.
 
- Public Member Functions inherited from o2::cad::surface::BoundedSurface
virtual ~BoundedSurface ()=default
 
virtual void appendCoverBoxes (std::vector< CoverBox > &boxes) const
 
double parametricLengthSqAt (const Vec2 &uv, const Vec2 &delta) const
 The 3D length squared spanned by a parametric displacement delta starting at uv.
 
virtual void appendRims (std::vector< SurfaceRim > &rims) const
 Append the trim boundary as rims, one polyline per loop; the default chains appendDirectedEdges().
 
void setBoundaryEdges (std::vector< BoundaryEdgeRef > refs)
 
const std::vector< BoundaryEdgeRef > & boundaryEdges () const
 
virtual bool sampleTrimCurve (size_t index, std::vector< Vec3 > &samples) const
 Sample trim curve index into 3D, in construction order; false when this face has no such curve.
 

Additional Inherited Members

- Public Types inherited from o2::cad::surface::BoundedSurface
using CoverBox = std::pair< Vec3, Vec3 >
 One axis-aligned cover box of the sub-patch BVH, as a (lower corner, upper corner) pair.
 
- Protected Attributes inherited from o2::cad::surface::BoundedSurface
std::vector< BoundaryEdgeRefmBoundaryEdges
 

Detailed Description

A trivial bounded surface, a single 3D triangle, to exercise the BoundedSurface interface.

Definition at line 509 of file testBVHSurfaceSolid.cxx.

Constructor & Destructor Documentation

◆ DummyBoundedSurface()

o2::cad::surface::DummyBoundedSurface::DummyBoundedSurface ( const Vec3 firstVertex,
const Vec3 secondVertex,
const Vec3 thirdVertex 
)
inline

Definition at line 512 of file testBVHSurfaceSolid.cxx.

Member Function Documentation

◆ appendDirectedEdges()

void o2::cad::surface::DummyBoundedSurface::appendDirectedEdges ( std::vector< std::pair< Vec3, Vec3 > > &  edges) const
inlineoverridevirtual

Append the 3D directed boundary edges of the patch, for solid-closure validation.

Implements o2::cad::surface::BoundedSurface.

Definition at line 567 of file testBVHSurfaceSolid.cxx.

◆ appendDisplayMesh()

void o2::cad::surface::DummyBoundedSurface::appendDisplayMesh ( std::vector< Vec3 > &  vertices,
std::vector< std::array< int, 3 > > &  triangles 
) const
inlineoverridevirtual

Append this patch's visualization triangulation (navigation must never depend on it).

Implements o2::cad::surface::BoundedSurface.

Definition at line 558 of file testBVHSurfaceSolid.cxx.

◆ appendIntersections()

void o2::cad::surface::DummyBoundedSurface::appendIntersections ( const Vec3 rayOrigin,
const Vec3 rayDirection,
double  minDistance,
double  maxDistance,
std::vector< RayHit > &  hits 
) const
inlineoverridevirtual

Append every hit of the ray with the trimmed patch in [minDistance, maxDistance], with the outward normal; no tangential grazes.

Implements o2::cad::surface::BoundedSurface.

Definition at line 532 of file testBVHSurfaceSolid.cxx.

◆ capacityContribution()

double o2::cad::surface::DummyBoundedSurface::capacityContribution ( ) const
inlineoverridevirtual

Signed divergence-theorem contribution to the enclosed volume.

Implements o2::cad::surface::BoundedSurface.

Definition at line 554 of file testBVHSurfaceSolid.cxx.

◆ capacityIsExact()

bool o2::cad::surface::DummyBoundedSurface::capacityIsExact ( ) const
inlineoverridevirtual

Whether capacityContribution() is analytically exact for this surface.

Implements o2::cad::surface::BoundedSurface.

Definition at line 556 of file testBVHSurfaceSolid.cxx.

◆ conservativeBounds()

void o2::cad::surface::DummyBoundedSurface::conservativeBounds ( Vec3 lower,
Vec3 upper 
) const
inlineoverridevirtual

Accumulate a conservative axis-aligned bounding box of the trimmed patch.

Implements o2::cad::surface::BoundedSurface.

Definition at line 518 of file testBVHSurfaceSolid.cxx.

◆ containsPointOnSurface()

bool o2::cad::surface::DummyBoundedSurface::containsPointOnSurface ( const Vec3 point) const
inlineoverridevirtual

True if the 3D point lies on the trimmed patch within tolerance.

Implements o2::cad::surface::BoundedSurface.

Definition at line 530 of file testBVHSurfaceSolid.cxx.

◆ distanceSqToPatch()

double o2::cad::surface::DummyBoundedSurface::distanceSqToPatch ( const Vec3 point) const
inlineoverridevirtual

Squared distance from a 3D point to the trimmed patch (used for Safety).

Implements o2::cad::surface::BoundedSurface.

Definition at line 534 of file testBVHSurfaceSolid.cxx.

◆ normalAt()

Vec3 o2::cad::surface::DummyBoundedSurface::normalAt ( const Vec3 point) const
inlineoverridevirtual

Outward-oriented normal at (or nearest to) the given point.

Implements o2::cad::surface::BoundedSurface.

Definition at line 544 of file testBVHSurfaceSolid.cxx.

◆ parametricMetric()

void o2::cad::surface::DummyBoundedSurface::parametricMetric ( const Vec2 ,
double &  gUU,
double &  gUV,
double &  gVV 
) const
inlineoverridevirtual

A triangle carries no parametric domain, so the form is the identity.

Implements o2::cad::surface::BoundedSurface.

Definition at line 547 of file testBVHSurfaceSolid.cxx.


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