DGtal 1.4.0
Loading...
Searching...
No Matches
DGtal::detail::CurvatureFromDCA< isCCW > Struct Template Reference

#include <DGtal/geometry/curves/estimation/SegmentComputerEstimators.h>

Public Types

typedef double Value
 

Public Member Functions

template<typename DCA >
Value operator() (const DCA &aDCA, const double &aH=1.0) const
 

Detailed Description

template<bool isCCW = true>
struct DGtal::detail::CurvatureFromDCA< isCCW >

Description of class 'CurvatureFromDCA'

Aim: computes the curvature from a geometricDCA at a given grid step.

Template Parameters
isCCWboolean equal to 'true' for a scanning in a counter-clockwise (CCW) orientation, 'false' otherwise. For instance, the estimated curvature of a digital circle, scanned in a CCW (resp. CW) orientation, is positive (resp. negative).

Definition at line 783 of file SegmentComputerEstimators.h.

Member Typedef Documentation

◆ Value

template<bool isCCW = true>
typedef double DGtal::detail::CurvatureFromDCA< isCCW >::Value

Definition at line 786 of file SegmentComputerEstimators.h.

Member Function Documentation

◆ operator()()

template<bool isCCW = true>
template<typename DCA >
Value DGtal::detail::CurvatureFromDCA< isCCW >::operator() ( const DCA & aDCA,
const double & aH = 1.0 ) const
inline

Operator()

Returns
curvature
Parameters
aDCAan instance of segment computer devoted to the DCA recognition.
aHgrid step
Template Parameters
DCAa model of segment computer devoted to the DCA recognition, basically geometricDCA.

Definition at line 802 of file SegmentComputerEstimators.h.

803 {
804 if ( aDCA.isStraight() )
805 return 0.0;
806 else
807 return ( aDCA.getSeparatingCircle().getCurvature() / aH );
808 }

The documentation for this struct was generated from the following file: