edu.jhu.cs.cisst.algorithms.segmentation.gac
Class DistanceField2D

java.lang.Object
  extended by edu.jhu.ece.iacl.jist.pipeline.AbstractCalculation
      extended by edu.jhu.cs.cisst.algorithms.segmentation.gac.DistanceField2D

public class DistanceField2D
extends AbstractCalculation

Calculate 2D distance field using the Fast-marching method.

Author:
Blake Lucas

Field Summary
 
Fields inherited from class edu.jhu.ece.iacl.jist.pipeline.AbstractCalculation
monitor
 
Constructor Summary
DistanceField2D()
          Instantiates a new distance field2 d.
DistanceField2D(AbstractCalculation parent)
          Instantiates a new distance field2 d.
 
Method Summary
static ImageDataFloat doSolve(ImageDataFloat vol, double thresh)
          Do solve.
static java.lang.String getVersion()
          Gets the version.
protected  double march(double Nv, double Sv, double Ev, double Wv, double Fv, double Bv, int Nl, int Sl, int Fl, int Bl)
          March.
static float maxSignedDistance(float[][] vol)
          Max signed distance.
 ImageDataFloat solve(ImageDataFloat vol, double maxDistance)
          Solve.
 
Methods inherited from class edu.jhu.ece.iacl.jist.pipeline.AbstractCalculation
add, addTotalUnits, decrementCompletedUnits, decrementCompletedUnits, getCompletedUnits, getCurrentLabel, getCurrentProgress, getLabel, getPerformance, getProgress, getTotalUnits, incrementCompletedUnits, incrementCompletedUnits, isCompleted, markCompleted, reset, setCompletedUnits, setCompletedUnits, setLabel, setMonitor, setTotalUnits
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

DistanceField2D

public DistanceField2D()
Instantiates a new distance field2 d.


DistanceField2D

public DistanceField2D(AbstractCalculation parent)
Instantiates a new distance field2 d.

Parameters:
parent - the parent
Method Detail

getVersion

public static java.lang.String getVersion()
Gets the version.

Returns:
the version

doSolve

public static ImageDataFloat doSolve(ImageDataFloat vol,
                                     double thresh)
Do solve.

Parameters:
vol - the vol
thresh - the thresh
Returns:
the image data float

maxSignedDistance

public static float maxSignedDistance(float[][] vol)
Max signed distance.

Parameters:
vol - the vol
Returns:
the float

solve

public ImageDataFloat solve(ImageDataFloat vol,
                            double maxDistance)
Solve.

Parameters:
vol - the vol
maxDistance - the max distance
Returns:
the image data float

march

protected double march(double Nv,
                       double Sv,
                       double Ev,
                       double Wv,
                       double Fv,
                       double Bv,
                       int Nl,
                       int Sl,
                       int Fl,
                       int Bl)
March.

Parameters:
Nv - the nv
Sv - the sv
Ev - the ev
Wv - the wv
Fv - the fv
Bv - the bv
Nl - the nl
Sl - the sl
Fl - the fl
Bl - the bl
Returns:
the double