DGtalTools  0.9.4
curvatureMCMS

Estimates curvature using length of most centered segment computers.

Usage: curvatureMCMS [options] –input <fileName>

Allowed options are :

-h [ --help ] display this message
-i [ --input ] arg input FreemanChain file name
-s [ --GridStep ] arg (=1) Grid step

Example: We consider as input shape the freeman chain of the DGtal/examples/sample directory. The contour can be displayed with displayContours :

$ displayContours -i $DGtal/examples/samples/contourS.fc -o contourS.png --drawPointOfIndex 0

The curvature can be computed as follows:

$ curvatureMCMS -i $DGtal/examples/samples/contourS.fc > curvatureMCMS.dat
$ gnuplot
gnuplot> plot 'curvatureMCMS.dat' w lines title "curvature using length of most centered segment computers estimator"

You should obtain such a result:

contour curvature
resCurvatureBCcontour.png
resCurvatureMCMS.png
CCW oriented (index 0=blue pt)resulting curvature
See also
curvatureMCMS.cpp