28 explicit operator bool()
const {
return proj.
face.valid(); }
70 float rayStart = 0.0f,
float rayEnd = FLT_MAX );
73 double rayStart = 0.0,
double rayEnd = DBL_MAX );
#define MRMESH_API
Definition MRMesh/MRMeshFwd.h:46
Definition MRDotNet/MRBitSet.h:39
Definition MRAABBTree.h:16
MRMESH_API MeshIntersectionResult rayMeshIntersect(const MeshPart &meshPart, const Line3f &line, float rayStart=0.0f, float rayEnd=FLT_MAX, const IntersectionPrecomputes< float > *prec=nullptr, bool closestIntersect=true, const FacePredicate &validFaces={})
MRMESH_API MultiMeshIntersectionResult rayMultiMeshAnyIntersect(const std::vector< Line3fMesh > &lineMeshes, float rayStart=0.0f, float rayEnd=FLT_MAX)
MRMESH_API void xyPlaneMeshIntersect(const MeshPart &meshPart, float zLevel, FaceBitSet *fs, UndirectedEdgeBitSet *ues, VertBitSet *vs)
std::function< bool(const MeshIntersectionResult &)> MeshIntersectionCallback
Definition MRMeshIntersect.h:77
MRMESH_API void rayMeshIntersectAll(const MeshPart &meshPart, const Line3f &line, MeshIntersectionCallback callback, float rayStart=0.0f, float rayEnd=FLT_MAX, const IntersectionPrecomputes< float > *prec=nullptr)
Definition MRCameraOrientationPlugin.h:7
std::function< bool(FaceId)> FacePredicate
Definition MRMesh/MRMeshFwd.h:413
Definition MRMesh/MRMeshFwd.h:364
Definition MRMeshIntersect.h:57
Line3< T > line
in the reference frame of mesh
Definition MRMeshIntersect.h:58
const Mesh * mesh
must be set a valid pointer before use
Definition MRMeshIntersect.h:60
const FaceBitSet * region
may remain nullptr, meaning all mesh
Definition MRMeshIntersect.h:62
const AABBTree * tree
must be set a valid pointer before use
Definition MRMeshIntersect.h:61
IntersectionPrecomputes< T > * prec
set it to a valid pointer for better performance
Definition MRMeshIntersect.h:59
Definition MRMeshIntersect.h:17
PointOnFace proj
stores intersected face and global coordinates
Definition MRMeshIntersect.h:19
float distanceAlongLine
stores the distance from ray origin to the intersection point in direction units
Definition MRMeshIntersect.h:25
MeshTriPoint mtp
stores barycentric coordinates
Definition MRMeshIntersect.h:22
Definition MRMesh/MRMeshPart.h:11
Definition MRMesh/MRMeshTriPoint.h:23
Definition MRMesh/MRMesh.h:23
Definition MRMeshIntersect.h:50
const Mesh * mesh
the intersection found in this mesh
Definition MRMeshIntersect.h:52
Definition MRPointOnFace.h:11
FaceId face
Definition MRPointOnFace.h:12