io.loader.load3D
Class NeighborSkeletonNodes3D

java.lang.Object
  extended by io.loader.load3D.NeighborSkeletonNodes3D

public class NeighborSkeletonNodes3D
extends java.lang.Object

Additional functionalities to check the neighborhood of skeleton nodes.


Constructor Summary
NeighborSkeletonNodes3D()
           
 
Method Summary
static java.util.List<SkeletonNode> getNeighborSkeletonNodes(SkeletonNode sn, int[][][] thinningcube, double widthDim, double heightDim, double depthDim)
          Get a list of all skeleton neighbor nodes for the specified node by checking the 3x3x3 neighborhood of this voxel and creating a new skeleton node for each skeleton voxel found.
static boolean isEdgeNeighbor(SkeletonNode n1, SkeletonNode n2)
          Check if two skeleton nodes are edge-connected.
static boolean isSurfaceNeighbor(SkeletonNode n1, SkeletonNode n2)
          Check if two skeleton nodes are surface connected.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

NeighborSkeletonNodes3D

public NeighborSkeletonNodes3D()
Method Detail

isEdgeNeighbor

public static boolean isEdgeNeighbor(SkeletonNode n1,
                                     SkeletonNode n2)
Check if two skeleton nodes are edge-connected.

Parameters:
n1 - the first skeleton node
n2 - the second skeleton node
Returns:
true if the two specified skeleton nodes are edge neighbors, false if not

isSurfaceNeighbor

public static boolean isSurfaceNeighbor(SkeletonNode n1,
                                        SkeletonNode n2)
Check if two skeleton nodes are surface connected.

Parameters:
n1 - the first skeleton node
n2 - the second skeleton node
Returns:
true if the two specified skeleton nodes are surface neighbors, false if not.

getNeighborSkeletonNodes

public static java.util.List<SkeletonNode> getNeighborSkeletonNodes(SkeletonNode sn,
                                                                    int[][][] thinningcube,
                                                                    double widthDim,
                                                                    double heightDim,
                                                                    double depthDim)
Get a list of all skeleton neighbor nodes for the specified node by checking the 3x3x3 neighborhood of this voxel and creating a new skeleton node for each skeleton voxel found.

Parameters:
sn - the skeleton node for which we want to find the skeleton neighbor nodes for
thinningcube - the 3D volume where to search the nodes
widthDim - the x dimension for the voxel in the 3D volume. This is needed to compute the real coordinates in case the voxels are not cubic.
heightDim - the y dimension for the voxel in the 3D volume. This is needed to compute the real coordinates in case the voxels are not cubic.
depthDim - the z dimension for the voxel in the 3D volume. This is needed to compute the real coordinates in case the voxels are not cubic.
Returns:
a list of skeleton nodes, containing all skeleton nodes directly connected to the specified skeleton node.