Class CandidatePlaneRobust

java.lang.Object
cz.fidentis.analyst.engines.symmetry.impl.CandidatePlaneRobust
All Implemented Interfaces:
Comparable<CandidatePlaneRobust>
Direct Known Subclasses:
CandidatePlaneRobustMesh

public class CandidatePlaneRobust extends Object implements Comparable<CandidatePlaneRobust>
A symmetry plane extends standard plane with functions related to the similarity of planes and the measure of their quality (symmetry precision). This version is used by the robust symmetry calculation methods.
  • Field Details

  • Constructor Details

    • CandidatePlaneRobust

      public CandidatePlaneRobust(javax.vecmath.Tuple3d point1, javax.vecmath.Tuple3d point2, double avgDist)
      New candidate symmetry plane constructed from two points.
      Parameters:
      point1 - point in space
      point2 - point in space
      avgDist - the average distance between vertices and their centroid
      Throws:
      IllegalArgumentException - if the @code{plane} argument is null
    • CandidatePlaneRobust

      public CandidatePlaneRobust(CandidatePlaneRobust pu, CandidatePlaneRobust pv)
      Candidate symmetry plane constructed by averaging two planes.
      Parameters:
      pu - the closest existing candidate
      pv - newly created candidate
    • CandidatePlaneRobust

      public CandidatePlaneRobust(Plane plane)
      New candidate symmetry plane constructed from an original plane.
      Parameters:
      plane - Original plane. Must not be null
  • Method Details

    • getNormal

      public javax.vecmath.Vector3d getNormal()
    • getDistance

      public double getDistance()
    • getPlane

      public Plane getPlane()
    • getClosestPlane

      public CandidatePlaneRobust getClosestPlane(UniformGrid4d<CandidatePlaneRobust> cache)
      Returns the closest plane from the cache to this plane.
      Parameters:
      cache -
      Returns:
      the closest plane from the cache to this plane.
    • getEstimationVector

      public javax.vecmath.Vector4d getEstimationVector()
      Returns a 4D vector usable as a location for the storage in the UniformGrid4d
      Returns:
      a 4D vector usable as a location for the storage in the UniformGrid4d
    • getNumAverages

      public int getNumAverages()
    • distance

      protected double distance(CandidatePlaneRobust pv)
      Parameters:
      pv - the second plane
      Returns:
      planes distance
    • measureSymmetry

      public void measureSymmetry(List<MeshPoint> points, UniformGrid3d<MeshPoint> grid, double alpha)
      Symmetry measurement based on the Wendland’s function without additional weights The plane is normalized and numAvg set to zero!
      Parameters:
      points - Downsampled point cloud
      grid - The same cloud stored in the uniform grid
      alpha - the average distance between vertices and their centroid
    • getSymmetryMeasure

      public double getSymmetryMeasure()
      Returns the symmetry measure computed by the getSymmetryMeasure().
      Returns:
      the symmetry measure
    • compareTo

      public int compareTo(CandidatePlaneRobust o)
      Specified by:
      compareTo in interface Comparable<CandidatePlaneRobust>
    • toString

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

      protected static double similarityFunction(double length, double alpha)
      A similarity function Phi.
      Parameters:
      length -
      alpha -
      Returns:
      similarity value
    • setSymmetryMeasure

      protected void setSymmetryMeasure(double symmetry)
    • normalizeIfNeeded

      protected void normalizeIfNeeded()