Class PointSamplingVisitorImpl

java.lang.Object
cz.fidentis.analyst.engines.sampling.impl.PointSamplingVisitorImpl
All Implemented Interfaces:
MeshVisitor, PointSamplingVisitor
Direct Known Subclasses:
CurvatureSampling, NoSampling, PoissonDiskSubSampling, RandomSampling, UniformSpaceSampling

public abstract class PointSamplingVisitorImpl extends Object implements PointSamplingVisitor
An abstract class for point sampling methods.
  • Constructor Details

    • PointSamplingVisitorImpl

      protected PointSamplingVisitorImpl(int max)
      Constructor.
      Parameters:
      max - Maximal number of required samples. Must be bigger than zero
      Throws:
      IllegalArgumentException - if the input parameter is wrong
  • Method Details

    • visitMeshFacet

      public abstract void visitMeshFacet(MeshFacet facet)
      Description copied from interface: MeshVisitor
      The inspection method to be implemented by specific visitors.
      Specified by:
      visitMeshFacet in interface MeshVisitor
      Specified by:
      visitMeshFacet in interface PointSamplingVisitor
      Parameters:
      facet - Mesh facet to be visited.
    • getSamples

      public abstract List<MeshPoint> getSamples()
      Description copied from interface: PointSamplingVisitor
      Returns a list of vertices reduced according to the strategy. The returned mesh points are backed by original points.
      Specified by:
      getSamples in interface PointSamplingVisitor
      Returns:
      selected vertices of inspected meshes
    • isBackedByOrigMesh

      public abstract boolean isBackedByOrigMesh()
      Description copied from interface: PointSamplingVisitor
      If true, then the returned points samples are points from the original mesh. Therefore, the transformation of the original mesh also transform these samples. If false, then new points are returned that are independent on the original mesh.
      Specified by:
      isBackedByOrigMesh in interface PointSamplingVisitor
      Returns:
      true if the point samples include points of the original mesh
    • setRequiredSamples

      public void setRequiredSamples(int max)
      Description copied from interface: PointSamplingVisitor
      Changes the number of required samples.
      Specified by:
      setRequiredSamples in interface PointSamplingVisitor
      Parameters:
      max - Maximal number of vertices. Must be bigger than zero
    • getRequiredSamples

      public int getRequiredSamples()
      Returns the number of required samples.
      Specified by:
      getRequiredSamples in interface PointSamplingVisitor
      Returns:
      the number of required samples
    • toString

      public String toString()
      Overrides:
      toString in class Object
    • setRealSamples

      protected void setRealSamples(int realSamples)