DGtal  0.6.devel
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Groups Pages
Public Types | Public Member Functions
DGtal::detail::CurvatureFromDCA< isCCW > Struct Template Reference

#include <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 790 of file SegmentComputerEstimators.h.


Member Typedef Documentation

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

Definition at line 793 of file SegmentComputerEstimators.h.


Member Function Documentation

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 809 of file SegmentComputerEstimators.h.

{
if ( aDCA.isStraight() )
return 0.0;
else
return ( aDCA.getSeparatingCircle().getCurvature() / aH );
}

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