All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups
hpp::affordance::LeanOperation Class Reference

Class that contains the information needed to create affordance objects of type Lean. More...

#include <hpp/affordance/operations.hh>

Inheritance diagram for hpp::affordance::LeanOperation:
[legend]
Collaboration diagram for hpp::affordance::LeanOperation:
[legend]

Public Member Functions

 LeanOperation (const double margin=0.3, const double nbTriMargin=0.3, const double minArea=0.05, const char *affordanceName="Lean")
 Constructor that takes in user-defined parameters. More...
 
bool requirement (const fcl::Vec3f &normal)
 The implementation of the requirement function for Lean affordances overrides the virtual function in class OperationBase. More...
 
- Public Member Functions inherited from hpp::affordance::OperationBase
 OperationBase ()
 If an OperationBase object is created without parameters, an affordance type called "noAffordance" is created as default, with certain default values for its member variables. More...
 
 OperationBase (const double margin=0.3, const double nbTriMargin=0.3, const double minArea=0.05, const char *affordanceName="noAffordance")
 Constructor that allows for user-defined parameters. More...
 

Additional Inherited Members

- Public Attributes inherited from hpp::affordance::OperationBase
const fcl::Vec3f zWorld_
 The orientation of the world z axis. Needed to find potential affordance objects. More...
 
const double margin_
 The error margin within which the requirement function must be fullfilled. More...
 
const double neighbouringTriangleMargin_
 The margin for the deviation of the normal of neighbouring triangles. More...
 
const double minArea_
 The minimum area required for an affordance object. More...
 
const char * affordance_
 Name of the affordance type for which te requirement exists. More...
 

Detailed Description

Class that contains the information needed to create affordance objects of type Lean.

Inherits the OperationBase class.

Constructor & Destructor Documentation

hpp::affordance::LeanOperation::LeanOperation ( const double  margin = 0.3,
const double  nbTriMargin = 0.3,
const double  minArea = 0.05,
const char *  affordanceName = "Lean" 
)
inlineexplicit

Constructor that takes in user-defined parameters.

Parameters
marginMargin needed for the evaluation of the requirement function
nbTriMarginMargin between two triangles tested for a single affordance surface. If the angle between two triangles is greater than the provided margin, the triangles cannot be part of the same affordance surface.
minAreaMinimum area needed for the formation of an affordance object
affordanceNameThe name of the affordance type

Member Function Documentation

bool hpp::affordance::LeanOperation::requirement ( const fcl::Vec3f normal)
inlinevirtual

The implementation of the requirement function for Lean affordances overrides the virtual function in class OperationBase.

Parameters
nromalNormal vector of the tested triangle.

Implements hpp::affordance::OperationBase.

References hpp::affordance::OperationBase::margin_, and hpp::affordance::OperationBase::zWorld_.