Class Octree


  • public class Octree
    extends java.lang.Object
    • Field Detail

      • DIMENSION

        public static int DIMENSION
      • radius

        float radius
      • width

        int width
      • maxMemoryUsage

        public static double maxMemoryUsage
      • normals

        public java.util.Vector<Point3D> normals
      • postNormalSmooth

        public float postNormalSmooth
      • ITERATION_POWER

        public static double ITERATION_POWER
      • MEMORY_ALLOCATOR_BLOCK_SIZE

        public static int MEMORY_ALLOCATOR_BLOCK_SIZE
      • READ_SIZE

        public static int READ_SIZE
      • PAD_SIZE

        public static float PAD_SIZE
      • EPSILON

        public static float EPSILON
      • ROUND_EPS

        public static float ROUND_EPS
      • Degree

        private int Degree
    • Constructor Detail

      • Octree

        public Octree​(int _Degree)
    • Method Detail

      • setNodeIndices

        public void setNodeIndices​(OctNode node,
                                   int[] idx)
      • NonLinearSplatOrientedPoint

        public int NonLinearSplatOrientedPoint​(OctNode node,
                                               Point3D position,
                                               Point3D normal)
      • NonLinearSplatOrientedPoint

        public void NonLinearSplatOrientedPoint​(Point3D position,
                                                Point3D normal,
                                                int splatDepth,
                                                float samplesPerNode,
                                                int minDepth,
                                                int maxDepth)
      • NonLinearGetSampleDepthAndWeight

        public void NonLinearGetSampleDepthAndWeight​(OctNode node,
                                                     Point3D position,
                                                     float samplesPerNode,
                                                     float[] depth,
                                                     float[] weight)
      • NonLinearGetSampleWeight

        public float NonLinearGetSampleWeight​(OctNode node,
                                              Point3D position)
      • NonLinearUpdateWeightContribution

        public int NonLinearUpdateWeightContribution​(OctNode node,
                                                     Point3D position,
                                                     float weight)
      • pause

        public static void pause()
        Pauses the display until the user hits enter.
      • readLine

        public java.lang.String readLine​(java.io.InputStream in)
                                  throws java.io.IOException
        Throws:
        java.io.IOException
      • setTree

        public int setTree​(java.lang.String fileName,
                           int maxDepth,
                           int binary,
                           int kernelDepth,
                           float samplesPerNode,
                           float scaleFactor,
                           Point3D center,
                           float[] scale,
                           int resetSamples,
                           int useConfidence)
      • setFunctionData

        public void setFunctionData​(PPolynomial ReconstructionFunction,
                                    int maxDepth,
                                    int normalize,
                                    float normalSmooth)
      • finalize1

        public void finalize1​(int refineNeighbors)
      • finalize2

        public void finalize2​(int refineNeighbors)
      • GetDivergence

        public final float GetDivergence​(int[] idx,
                                         Point3D normal)
      • GetLaplacian

        public final float GetLaplacian​(int[] idx)
      • GetDotProduct

        public final float GetDotProduct​(int[] idx)
      • GetRestrictedFixedDepthLaplacian

        public int GetRestrictedFixedDepthLaplacian​(SparseSymmetricMatrix matrix,
                                                    int depth,
                                                    int[] entries,
                                                    int entryCount,
                                                    OctNode rNode,
                                                    float radius,
                                                    SortedTreeNodes sNodes)
      • LaplacianMatrixIteration

        public int LaplacianMatrixIteration​(int subdivideDepth)
      • SolveFixedDepthMatrix

        public int SolveFixedDepthMatrix​(int depth,
                                         SortedTreeNodes sNodes)
      • SolveFixedDepthMatrix

        public int SolveFixedDepthMatrix​(int depth,
                                         int startingDepth,
                                         SortedTreeNodes sNodes)
      • HasNormals

        public int HasNormals​(OctNode node,
                              float epsilon)
      • printTree

        public void printTree()
      • ClipTree

        public void ClipTree()
      • SetLaplacianWeights

        public void SetLaplacianWeights()
      • GetMCIsoTriangles

        public void GetMCIsoTriangles​(float isoValue,
                                      CoredMeshData mesh,
                                      int fullDepthIso,
                                      int nonLinearFit)
      • GetMCIsoTriangles

        public void GetMCIsoTriangles​(java.lang.Float isoValue,
                                      int subdivideDepth,
                                      CoredMeshData mesh,
                                      int fullDepthIso,
                                      int nonLinearFit)
      • getCenterValue

        public float getCenterValue​(OctNode node)
      • getCornerValue

        public float getCornerValue​(OctNode node,
                                    int corner)
      • getCornerValueAndNormal

        public void getCornerValueAndNormal​(OctNode node,
                                            int corner,
                                            float[] value,
                                            Point3D normal)
      • GetIsoValue

        public float GetIsoValue()
      • SetIsoSurfaceCorners

        public void SetIsoSurfaceCorners​(float isoValue,
                                         int subdivideDepth,
                                         int fullDepthIso)
      • Subdivide

        public void Subdivide​(OctNode node,
                              float isoValue,
                              int maxDepth)
      • InteriorFaceRootCount

        public static int InteriorFaceRootCount​(OctNode node,
                                                int faceIndex,
                                                int maxDepth)
      • EdgeRootCount

        public static int EdgeRootCount​(OctNode node,
                                        int edgeIndex,
                                        int maxDepth)
      • IsBoundaryFace

        public static int IsBoundaryFace​(OctNode node,
                                         int faceIndex,
                                         int subdivideDepth)
      • IsBoundaryEdge

        public static boolean IsBoundaryEdge​(OctNode node,
                                             int edgeIndex,
                                             int subdivideDepth)
      • IsBoundaryEdge

        public static boolean IsBoundaryEdge​(OctNode node,
                                             int dir,
                                             int x,
                                             int y,
                                             int subdivideDepth)
      • PreValidate

        public void PreValidate​(OctNode node,
                                float isoValue,
                                int maxDepth,
                                int subdivideDepth)
      • PreValidate

        public void PreValidate​(float isoValue,
                                int maxDepth,
                                int subdivideDepth)
      • Validate

        public void Validate​(OctNode node,
                             float isoValue,
                             int maxDepth,
                             int fullDepthIso)
      • Validate

        public void Validate​(OctNode node,
                             float isoValue,
                             int maxDepth,
                             int fullDepthIso,
                             int subdivideDepth)
      • GetRoot

        public int GetRoot​(RootInfo ri,
                           float isoValue,
                           Point3D position,
                           java.util.HashMap<java.lang.Long,​Pair<java.lang.Float,​Point3D>> normalHash,
                           int nonLinearFit)
      • GetRoot

        public int GetRoot​(RootInfo ri,
                           float isoValue,
                           int maxDepth,
                           Point3D position,
                           java.util.HashMap<java.lang.Long,​Pair<java.lang.Float,​Point3D>> normals,
                           Point3D normal,
                           int nonLinearFit)
      • GetRootIndex

        public static int GetRootIndex​(OctNode node,
                                       int edgeIndex,
                                       int maxDepth,
                                       int sDepth,
                                       RootInfo ri)
      • GetRootIndex

        public static boolean GetRootIndex​(OctNode node,
                                           int edgeIndex,
                                           int maxDepth,
                                           RootInfo ri)
      • GetRootPair

        public boolean GetRootPair​(RootInfo ri,
                                   int maxDepth,
                                   RootInfo pair)
      • GetRootIndex

        public static int GetRootIndex​(java.lang.Long key,
                                       java.util.HashMap<java.lang.Long,​java.lang.Integer> boundaryRoots,
                                       java.util.HashMap<java.lang.Long,​java.lang.Integer> interiorRoots,
                                       CoredPointIndex index)
      • SetMCRootPositions

        public int SetMCRootPositions​(OctNode node,
                                      int sDepth,
                                      float isoValue,
                                      java.util.HashMap<java.lang.Long,​java.lang.Integer> boundaryRoots,
                                      java.util.HashMap<java.lang.Long,​java.lang.Integer> interiorRoots,
                                      java.util.HashMap<java.lang.Long,​Pair<java.lang.Float,​Point3D>> boundaryNormalHash,
                                      java.util.HashMap<java.lang.Long,​Pair<java.lang.Float,​Point3D>> interiorNormalHash,
                                      java.util.Vector<Point3D> interiorPositions,
                                      CoredMeshData mesh,
                                      int nonLinearFit)
      • SetBoundaryMCRootPositions

        public int SetBoundaryMCRootPositions​(int sDepth,
                                              float isoValue,
                                              java.util.HashMap<java.lang.Long,​java.lang.Integer> boundaryRoots,
                                              java.util.HashMap<java.lang.Long,​Pair<java.lang.Float,​Point3D>> boundaryNormalHash,
                                              CoredMeshData mesh,
                                              int nonLinearFit)
      • GetMCIsoEdges

        public void GetMCIsoEdges​(OctNode node,
                                  java.util.HashMap<java.lang.Long,​java.lang.Integer> boundaryRoots,
                                  java.util.HashMap<java.lang.Long,​java.lang.Integer> interiorRoots,
                                  int sDepth,
                                  java.util.Vector<Pair<java.lang.Long,​java.lang.Long>> edges)
      • GetMCIsoTriangles

        public int GetMCIsoTriangles​(OctNode node,
                                     CoredMeshData mesh,
                                     java.util.HashMap<java.lang.Long,​java.lang.Integer> boundaryRoots,
                                     java.util.HashMap<java.lang.Long,​java.lang.Integer> interiorRoots,
                                     java.util.Vector<Point3D> interiorPositions,
                                     int offSet,
                                     int sDepth)
      • GetEdgeLoops

        public static int GetEdgeLoops​(java.util.Vector<Pair<java.lang.Long,​java.lang.Long>> edges,
                                       java.util.Vector<java.util.Vector<Pair<java.lang.Long,​java.lang.Long>>> loops)