15#include "libmesh/bounding_box.h"
16#include "libmesh/parallel.h"
112 std::unique_ptr<AdaptiveRayContainmentCheck>
_pca;
113 std::unique_ptr<TriangleManifold>
_tri;
Ray-casting point-in-solid engine over a closed surface mesh represented as a collection of SurfaceEl...
Unified wrapper (facade) over the point-containment backends.
libMesh::BoundingBox _bounding_box
Cached method-independent AABB and element count for the accessors.
~PointContainmentClassifier()
SurfaceGeometry::SurfaceSide sideness(const Point &point) const
Classify a query point relative to the closed surface.
std::size_t _num_elements
Point rayDirection() const
The resolved ray direction of the ray-casting backend (user-selected direction for USER_SELECTED_RAY,...
PointContainmentClassifier(libMesh::MeshBase &mesh, const SurfaceElementSet *set, Method method, Real tolerance)
Builds PCA_RAY with default ray options or FIXED_X_RAY without unused options.
PointContainmentClassifier(libMesh::MeshBase &mesh, const SurfaceElementSet *set, Method method, Real tolerance, const RayOptions &options)
Builds the selected backend with explicit ray options.
bool contains(const Point &point) const
Convenience API aligned with TriangleManifold: INSIDE and ON both map to true.
std::unique_ptr< TriangleManifold > _tri
FIXED_X_RAY.
std::unique_ptr< AdaptiveRayContainmentCheck > _pca
One of the two backends is constructed; the other stays null.
std::size_t numElements() const
Number of surface elements (triangles) backing the classifier.
const libMesh::BoundingBox & boundingBox() const
Method-independent global axis-aligned bounding box of the surface.
Method
Backend algorithm used for point-containment queries.
@ USER_SELECTED_RAY
AdaptiveRayContainmentCheck with a user-supplied ray_direction, used exactly as given (no PCA,...
@ FIXED_X_RAY
TriangleManifold engine (fixed +x ray parity + solid-angle fallback).
@ PCA_RAY
AdaptiveRayContainmentCheck with a PCA-selected ray (default SBM behavior).
A group of surface elements wrapped for point-containment / distance queries.
Utility for querying point containment against a closed triangulated surface mesh.
SurfaceSide
The side of a closed surface where a query point is located.
@ OUTSIDE
The point lies strictly in the exterior of the closed surface.
The following methods are specializations for using the libMesh::Parallel::packed_range_* routines fo...
Ray-backend tuning + debug output; ignored by FIXED_X_RAY (TriangleManifold).
Point ray_direction
Direction used by USER_SELECTED_RAY; ignored by PCA_RAY.
const libMesh::Parallel::Communicator * comm