DGtal 1.3.0
Loading...
Searching...
No Matches
Public Types | Public Member Functions | Private Attributes
DGtal::functors::ShapeGeometricFunctors::ShapeFirstPrincipalCurvatureFunctor< TShape > Struct Template Reference

Aim: A functor RealPoint -> Quantity that returns the first principal curvature at given point (i.e. smallest principal curvature). More...

#include <DGtal/shapes/ShapeGeometricFunctors.h>

Public Types

typedef TShape Shape
 
typedef Shape::RealPoint RealPoint
 
typedef Shape::RealVector RealVector
 
typedef RealVector::Component Scalar
 
typedef RealPoint Argument
 
typedef Scalar Quantity
 
typedef Quantity Value
 

Public Member Functions

 ShapeFirstPrincipalCurvatureFunctor (ConstAlias< Shape > aShape=0)
 
void attach (ConstAlias< Shape > aShape)
 
Quantity operator() (const RealPoint &p) const
 

Private Attributes

CountedConstPtrOrConstPtr< ShapemyShape
 The shape of interest. More...
 

Detailed Description

template<typename TShape>
struct DGtal::functors::ShapeGeometricFunctors::ShapeFirstPrincipalCurvatureFunctor< TShape >

Aim: A functor RealPoint -> Quantity that returns the first principal curvature at given point (i.e. smallest principal curvature).

Description of template class 'ShapeFirstPrincipalCurvatureFunctor'

Template Parameters
TShapethe type of the shape where geometric estimation are made. It must have method principalCurvatures.

Definition at line 273 of file ShapeGeometricFunctors.h.

Member Typedef Documentation

◆ Argument

template<typename TShape >
typedef RealPoint DGtal::functors::ShapeGeometricFunctors::ShapeFirstPrincipalCurvatureFunctor< TShape >::Argument

Definition at line 278 of file ShapeGeometricFunctors.h.

◆ Quantity

template<typename TShape >
typedef Scalar DGtal::functors::ShapeGeometricFunctors::ShapeFirstPrincipalCurvatureFunctor< TShape >::Quantity

Definition at line 279 of file ShapeGeometricFunctors.h.

◆ RealPoint

Definition at line 275 of file ShapeGeometricFunctors.h.

◆ RealVector

Definition at line 276 of file ShapeGeometricFunctors.h.

◆ Scalar

Definition at line 277 of file ShapeGeometricFunctors.h.

◆ Shape

Definition at line 274 of file ShapeGeometricFunctors.h.

◆ Value

Definition at line 280 of file ShapeGeometricFunctors.h.

Constructor & Destructor Documentation

◆ ShapeFirstPrincipalCurvatureFunctor()

template<typename TShape >
DGtal::functors::ShapeGeometricFunctors::ShapeFirstPrincipalCurvatureFunctor< TShape >::ShapeFirstPrincipalCurvatureFunctor ( ConstAlias< Shape aShape = 0)
inline

Constructor. A shape may also be attached at construction.

Parameters
aShapethe shape of interest. The alias can be secured if a some counted pointer is handed.

Definition at line 288 of file ShapeGeometricFunctors.h.

289 : myShape( aShape ) {}
CountedConstPtrOrConstPtr< Shape > myShape
The shape of interest.

Member Function Documentation

◆ attach()

template<typename TShape >
void DGtal::functors::ShapeGeometricFunctors::ShapeFirstPrincipalCurvatureFunctor< TShape >::attach ( ConstAlias< Shape aShape)
inline

Attach a shape.

Parameters
aShapethe shape of interest. The alias can be secured if a some counted pointer is handed.

Definition at line 297 of file ShapeGeometricFunctors.h.

298 {
299 myShape = aShape;
300 }

References DGtal::functors::ShapeGeometricFunctors::ShapeFirstPrincipalCurvatureFunctor< TShape >::myShape.

◆ operator()()

template<typename TShape >
Quantity DGtal::functors::ShapeGeometricFunctors::ShapeFirstPrincipalCurvatureFunctor< TShape >::operator() ( const RealPoint p) const
inline

Map operator RealPoint -> Quantity giving the first principal curvature.

Parameters
pany point on the shape.
Returns
the first principal curvature at point p (smallest curvature).

Definition at line 307 of file ShapeGeometricFunctors.h.

308 {
309 Quantity k1, k2;
310 myShape->principalCurvatures( p, k1, k2 );
311 return k1;
312 }

References DGtal::functors::ShapeGeometricFunctors::ShapeFirstPrincipalCurvatureFunctor< TShape >::myShape.

Field Documentation

◆ myShape


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