Class BoundingBoxMaskProjector

java.lang.Object
cz.fidentis.analyst.engines.interactivemask.BoundingBoxMaskProjector
All Implemented Interfaces:
OctreeVisitor

public class BoundingBoxMaskProjector extends Object implements OctreeVisitor

Visits octree mesh and returns SurfaceMask projected onto the mesh. Points to project are described as a normalized 2D points with coordinates relative to mesh bounding box in x and y axes (i.e. in range invalid input: '<'0, 1>).

Using ray casting, intersection of 3D point on mesh is constructed from 2D point and orthogonal ray cast towards the mesh.

  • Field Details

    • PROJECTION_DISTANCE

      public static final float PROJECTION_DISTANCE
      Distance of the origin of orthogonal rays
      See Also:
  • Constructor Details

    • BoundingBoxMaskProjector

      public BoundingBoxMaskProjector(BoundingBoxMaskProjectorConfig config, List<javax.vecmath.Point2d> points)
      Constructor.
      Parameters:
      config - configuration for the visitor
      points - points to project
  • Method Details

    • getResult

      public SurfaceMask getResult()
      Gets the resulting projected mask.
      Returns:
      projected mask
    • visitOctree

      public void visitOctree(Octree octree)
      Description copied from interface: OctreeVisitor
      The main inspection method to be implemented by specific visitors.
      Specified by:
      visitOctree in interface OctreeVisitor
      Parameters:
      octree - octree to be visited