Visual Servoing Platform
version 3.0.0
|
#include <visp3/visual_features/vpFeatureEllipse.h>
Public Types | |
enum | { FEATURE_ALL = 0xffff } |
enum | vpBasicFeatureDeallocatorType { user, vpServo } |
Public Member Functions | |
void | init () |
vpFeatureEllipse () | |
virtual | ~vpFeatureEllipse () |
vpFeatureEllipse (const double x, const double y, const double mu20, const double mu11, const double mu02) | |
void | buildFrom (const double x, const double y, const double mu20, const double mu11, const double mu02) |
void | buildFrom (const double x, const double y, const double mu20, const double mu11, const double mu02, const double A, const double B, const double C) |
void | set_x (const double x) |
void | set_y (const double y) |
void | set_xy (const double x, const double y) |
void | setABC (const double A, const double B, const double C) |
void | setMu (const double mu20, const double mu11, const double mu02) |
double | get_x () const |
double | get_y () const |
double | getMu20 () const |
double | getMu11 () const |
double | getMu02 () const |
vpMatrix | interaction (const unsigned int select=FEATURE_ALL) |
vpColVector | error (const vpBasicFeature &s_star, const unsigned int select=FEATURE_ALL) |
vpColVector | error (const unsigned int select=FEATURE_ALL) |
void | print (const unsigned int select=FEATURE_ALL) const |
vpFeatureEllipse * | duplicate () const |
void | display (const vpCameraParameters &cam, const vpImage< unsigned char > &I, const vpColor &color=vpColor::green, unsigned int thickness=1) const |
void | display (const vpCameraParameters &cam, const vpImage< vpRGBa > &I, const vpColor &color=vpColor::green, unsigned int thickness=1) const |
unsigned int | dimension_s () |
virtual double | operator[] (const unsigned int i) const |
vpColVector | get_s (unsigned int select=FEATURE_ALL) const |
unsigned int | getDimension (const unsigned int select=FEATURE_ALL) const |
void | setFlags () |
void | setDeallocate (vpBasicFeatureDeallocatorType d) |
vpBasicFeatureDeallocatorType | getDeallocate () |
Static Public Member Functions | |
static unsigned int | selectX () |
static unsigned int | selectY () |
static unsigned int | selectMu20 () |
static unsigned int | selectMu11 () |
static unsigned int | selectMu02 () |
static unsigned int | selectAll () |
Static Public Attributes | |
static const unsigned int | FEATURE_LINE [32] |
Protected Member Functions | |
void | resetFlags () |
Protected Attributes | |
vpColVector | s |
unsigned int | dim_s |
bool * | flags |
unsigned int | nbParameters |
vpBasicFeatureDeallocatorType | deallocate |
Class that defines 2D ellipse visual feature.
Definition at line 60 of file vpFeatureEllipse.h.
|
inherited |
Enumerator | |
---|---|
FEATURE_ALL |
Definition at line 84 of file vpBasicFeature.h.
|
inherited |
Indicates who should deallocate the feature.
Enumerator | |
---|---|
user | |
vpServo |
Definition at line 153 of file vpBasicFeature.h.
vpFeatureEllipse::vpFeatureEllipse | ( | ) |
Default constructor.
Definition at line 95 of file vpFeatureEllipse.cpp.
References init().
Referenced by duplicate().
|
inlinevirtual |
Destructor.
Definition at line 78 of file vpFeatureEllipse.h.
vpFeatureEllipse::vpFeatureEllipse | ( | const double | x, |
const double | y, | ||
const double | mu20, | ||
const double | mu11, | ||
const double | mu02 | ||
) |
void vpFeatureEllipse::buildFrom | ( | const double | x, |
const double | y, | ||
const double | mu20, | ||
const double | mu11, | ||
const double | mu02 | ||
) |
Definition at line 312 of file vpFeatureEllipse.cpp.
References vpBasicFeature::flags, and vpBasicFeature::s.
Referenced by vpFeatureBuilder::create().
void vpFeatureEllipse::buildFrom | ( | const double | x, |
const double | y, | ||
const double | mu20, | ||
const double | mu11, | ||
const double | mu02, | ||
const double | A, | ||
const double | B, | ||
const double | C | ||
) |
Definition at line 328 of file vpFeatureEllipse.cpp.
References vpBasicFeature::flags, vpBasicFeature::nbParameters, and vpBasicFeature::s.
|
inlineinherited |
Return the dimension of the feature vector .
Definition at line 101 of file vpBasicFeature.h.
|
virtual |
Display ellipse feature.
cam | : Camera parameters. |
I | : Image on which features have to be displayed. |
color | : Color used to display the feature. |
thickness | : Thickness of the feature representation. |
Implements vpBasicFeature.
Definition at line 403 of file vpFeatureEllipse.cpp.
References vpFeatureDisplay::displayEllipse(), vpBasicFeature::s, and vpERROR_TRACE.
|
virtual |
Display ellipse feature.
cam | : Camera parameters. |
I | : Color image on which features have to be displayed. |
color | : Color used to display the feature. |
thickness | : Thickness of the feature representation. |
Implements vpBasicFeature.
Definition at line 437 of file vpFeatureEllipse.cpp.
References vpFeatureDisplay::displayEllipse(), vpBasicFeature::s, and vpERROR_TRACE.
|
virtual |
feature duplication
for memory issue (used by the vpServo class only)
Implements vpBasicFeature.
Definition at line 463 of file vpFeatureEllipse.cpp.
References vpFeatureEllipse().
|
virtual |
compute the error between two visual features from a subset a the possible features
Reimplemented from vpBasicFeature.
Definition at line 239 of file vpFeatureEllipse.cpp.
References vpBasicFeature::s, selectMu02(), selectMu11(), selectMu20(), selectX(), selectY(), and vpColVector::stack().
vpColVector vpFeatureEllipse::error | ( | const unsigned int | select = FEATURE_ALL | ) |
compute the error between a visual features and zero
|
inherited |
Get the feature vector .
Definition at line 130 of file vpBasicFeature.cpp.
References vpBasicFeature::dim_s, vpBasicFeature::FEATURE_LINE, vpBasicFeature::s, and vpColVector::stack().
Referenced by vpServo::computeError(), vpBasicFeature::error(), vpGenericFeature::error(), vpFeatureDepth::error(), vpFeatureThetaU::error(), and vpFeatureTranslation::error().
|
inline |
Definition at line 100 of file vpFeatureEllipse.h.
|
inline |
Definition at line 101 of file vpFeatureEllipse.h.
|
inlineinherited |
Definition at line 163 of file vpBasicFeature.h.
|
inherited |
Get the feature vector dimension.
Definition at line 115 of file vpBasicFeature.cpp.
References vpBasicFeature::dim_s, vpBasicFeature::FEATURE_LINE, vpArray2D< Type >::getRows(), and vpBasicFeature::s.
|
inline |
Definition at line 104 of file vpFeatureEllipse.h.
|
inline |
Definition at line 103 of file vpFeatureEllipse.h.
|
inline |
Definition at line 102 of file vpFeatureEllipse.h.
|
virtual |
Default initialization.
Implements vpBasicFeature.
Definition at line 77 of file vpFeatureEllipse.cpp.
References vpBasicFeature::dim_s, vpBasicFeature::flags, vpBasicFeature::nbParameters, vpColVector::resize(), and vpBasicFeature::s.
Referenced by vpFeatureEllipse().
|
virtual |
compute the interaction matrix from a subset a the possible features
Implements vpBasicFeature.
Definition at line 104 of file vpFeatureEllipse.cpp.
References vpBasicFeature::deallocate, vpBasicFeature::flags, vpBasicFeature::nbParameters, vpBasicFeature::resetFlags(), vpArray2D< Type >::resize(), vpBasicFeature::s, selectMu02(), selectMu11(), selectMu20(), selectX(), selectY(), vpMath::sqr(), vpMatrix::stack(), vpBasicFeature::user, and vpTRACE.
Referenced by vpMbtDistanceCircle::computeInteractionMatrixError().
|
inlinevirtualinherited |
Return element i in the state vector (usage : x = s[i] )
Definition at line 112 of file vpBasicFeature.h.
|
virtual |
print the name of the feature
Implements vpBasicFeature.
Definition at line 293 of file vpFeatureEllipse.cpp.
References vpBasicFeature::s, selectMu02(), selectMu11(), selectMu20(), selectX(), and selectY().
|
protectedinherited |
Definition at line 148 of file vpBasicFeature.cpp.
References vpBasicFeature::flags, and vpBasicFeature::nbParameters.
Referenced by interaction(), vpFeatureVanishingPoint::interaction(), vpFeatureDepth::interaction(), vpFeaturePoint::interaction(), vpFeatureLine::interaction(), vpFeaturePoint3D::interaction(), vpFeatureThetaU::interaction(), vpFeaturePointPolar::interaction(), and vpFeatureTranslation::interaction().
|
inlinestaticinherited |
Select all the features.
Definition at line 115 of file vpBasicFeature.h.
|
static |
Definition at line 473 of file vpFeatureEllipse.cpp.
References vpBasicFeature::FEATURE_LINE.
Referenced by error(), interaction(), and print().
|
static |
Definition at line 472 of file vpFeatureEllipse.cpp.
References vpBasicFeature::FEATURE_LINE.
Referenced by error(), interaction(), and print().
|
static |
Definition at line 471 of file vpFeatureEllipse.cpp.
References vpBasicFeature::FEATURE_LINE.
Referenced by error(), interaction(), and print().
|
static |
vpBasicFeature method instantiation
Definition at line 469 of file vpFeatureEllipse.cpp.
References vpBasicFeature::FEATURE_LINE.
Referenced by error(), interaction(), and print().
|
static |
Definition at line 470 of file vpFeatureEllipse.cpp.
References vpBasicFeature::FEATURE_LINE.
Referenced by error(), interaction(), and print().
void vpFeatureEllipse::set_x | ( | const double | x | ) |
Definition at line 348 of file vpFeatureEllipse.cpp.
References vpBasicFeature::flags, and vpBasicFeature::s.
void vpFeatureEllipse::set_xy | ( | const double | x, |
const double | y | ||
) |
Definition at line 362 of file vpFeatureEllipse.cpp.
References vpBasicFeature::flags, and vpBasicFeature::s.
void vpFeatureEllipse::set_y | ( | const double | y | ) |
Definition at line 355 of file vpFeatureEllipse.cpp.
References vpBasicFeature::flags, and vpBasicFeature::s.
void vpFeatureEllipse::setABC | ( | const double | A, |
const double | B, | ||
const double | C | ||
) |
Definition at line 370 of file vpFeatureEllipse.cpp.
References vpBasicFeature::flags, and vpBasicFeature::nbParameters.
Referenced by vpFeatureBuilder::create().
|
inlineinherited |
Definition at line 162 of file vpBasicFeature.h.
Referenced by vpServo::addFeature().
|
inherited |
Set feature flags to true to prevent warning when re-computing the interaction matrix without having updated the feature.
Definition at line 158 of file vpBasicFeature.cpp.
References vpBasicFeature::flags, and vpBasicFeature::nbParameters.
void vpFeatureEllipse::setMu | ( | const double | mu20, |
const double | mu11, | ||
const double | mu02 | ||
) |
Definition at line 380 of file vpFeatureEllipse.cpp.
References vpBasicFeature::flags, and vpBasicFeature::s.
|
protectedinherited |
Definition at line 160 of file vpBasicFeature.h.
Referenced by interaction(), vpFeatureVanishingPoint::interaction(), vpFeatureSegment::interaction(), vpFeatureDepth::interaction(), vpFeaturePoint::interaction(), vpFeatureLine::interaction(), vpFeaturePoint3D::interaction(), vpFeatureThetaU::interaction(), vpFeaturePointPolar::interaction(), vpFeatureTranslation::interaction(), and vpBasicFeature::operator=().
|
protectedinherited |
Dimension of the visual feature.
Definition at line 92 of file vpBasicFeature.h.
Referenced by vpFeatureMoment::duplicate(), vpGenericFeature::duplicate(), vpBasicFeature::error(), vpFeatureLuminance::error(), vpGenericFeature::error(), vpBasicFeature::get_s(), vpGenericFeature::get_s(), vpBasicFeature::getDimension(), vpFeatureMoment::getDimension(), init(), vpFeatureVanishingPoint::init(), vpFeatureLuminance::init(), vpFeatureSegment::init(), vpFeatureDepth::init(), vpFeaturePoint::init(), vpFeatureMoment::init(), vpFeatureLine::init(), vpFeaturePoint3D::init(), vpFeatureThetaU::init(), vpFeaturePointPolar::init(), vpFeatureTranslation::init(), vpFeatureLuminance::interaction(), vpGenericFeature::interaction(), vpFeatureMoment::interaction(), vpBasicFeature::operator=(), vpFeatureLuminance::operator=(), vpGenericFeature::print(), vpFeatureMoment::print(), vpGenericFeature::set_s(), vpGenericFeature::setError(), vpGenericFeature::setInteractionMatrix(), vpFeatureMoment::update(), vpFeatureLuminance::vpFeatureLuminance(), and vpGenericFeature::vpGenericFeature().
|
staticinherited |
Definition at line 82 of file vpBasicFeature.h.
Referenced by vpBasicFeature::error(), vpGenericFeature::error(), vpBasicFeature::get_s(), vpBasicFeature::getDimension(), vpFeatureMoment::getDimension(), vpGenericFeature::interaction(), vpFeatureMoment::interaction(), vpGenericFeature::print(), vpFeatureMoment::print(), vpFeatureSegment::selectAlpha(), vpFeatureSegment::selectL(), selectMu02(), selectMu11(), selectMu20(), vpFeatureLine::selectRho(), vpFeaturePointPolar::selectRho(), vpFeatureLine::selectTheta(), vpFeaturePointPolar::selectTheta(), vpFeatureThetaU::selectTUx(), vpFeatureThetaU::selectTUy(), vpFeatureThetaU::selectTUz(), vpFeatureTranslation::selectTx(), vpFeatureTranslation::selectTy(), vpFeatureTranslation::selectTz(), selectX(), vpFeatureVanishingPoint::selectX(), vpFeaturePoint::selectX(), vpFeaturePoint3D::selectX(), vpFeatureSegment::selectXc(), selectY(), vpFeatureVanishingPoint::selectY(), vpFeaturePoint::selectY(), vpFeaturePoint3D::selectY(), vpFeatureSegment::selectYc(), and vpFeaturePoint3D::selectZ().
|
protectedinherited |
Ensure that all the parameters needed to compute the iteraction matrix are set.
Definition at line 95 of file vpBasicFeature.h.
Referenced by buildFrom(), vpFeatureVanishingPoint::buildFrom(), vpFeatureDepth::buildFrom(), vpFeaturePoint::buildFrom(), vpFeatureLine::buildFrom(), vpFeaturePoint3D::buildFrom(), vpFeatureThetaU::buildFrom(), vpFeaturePointPolar::buildFrom(), vpFeatureTranslation::buildFrom(), vpFeatureMoment::duplicate(), init(), vpFeatureVanishingPoint::init(), vpFeatureLuminance::init(), vpFeatureSegment::init(), vpFeatureDepth::init(), vpFeaturePoint::init(), vpFeatureMoment::init(), vpFeatureLine::init(), vpFeaturePoint3D::init(), vpFeatureThetaU::init(), vpFeaturePointPolar::init(), vpFeatureTranslation::init(), interaction(), vpFeatureVanishingPoint::interaction(), vpFeatureSegment::interaction(), vpFeatureDepth::interaction(), vpFeaturePoint::interaction(), vpFeatureLine::interaction(), vpFeaturePoint3D::interaction(), vpFeatureThetaU::interaction(), vpFeaturePointPolar::interaction(), vpFeatureTranslation::interaction(), vpBasicFeature::operator=(), vpBasicFeature::resetFlags(), vpFeaturePointPolar::set_rho(), vpFeaturePointPolar::set_rhoThetaZ(), vpFeaturePointPolar::set_theta(), vpFeatureThetaU::set_TUx(), vpFeatureThetaU::set_TUy(), vpFeatureThetaU::set_TUz(), set_x(), vpFeatureVanishingPoint::set_x(), vpFeatureDepth::set_x(), vpFeaturePoint::set_x(), vpFeaturePoint3D::set_X(), set_xy(), vpFeaturePoint::set_xyZ(), vpFeaturePoint3D::set_XYZ(), vpFeatureDepth::set_xyZLogZoverZstar(), set_y(), vpFeatureVanishingPoint::set_y(), vpFeatureDepth::set_y(), vpFeaturePoint::set_y(), vpFeaturePoint3D::set_Y(), vpFeatureLuminance::set_Z(), vpFeatureDepth::set_Z(), vpFeaturePoint::set_Z(), vpFeaturePoint3D::set_Z(), vpFeaturePointPolar::set_Z(), setABC(), vpFeatureLine::setABCD(), vpBasicFeature::setFlags(), setMu(), vpFeatureLine::setRhoTheta(), vpFeatureMoment::update(), vpFeatureLuminance::vpFeatureLuminance(), and vpBasicFeature::~vpBasicFeature().
|
protectedinherited |
Number of parameters needed to compute the interaction matrix.
Definition at line 97 of file vpBasicFeature.h.
Referenced by buildFrom(), vpFeatureVanishingPoint::buildFrom(), vpFeatureDepth::buildFrom(), vpFeaturePoint::buildFrom(), vpFeatureLine::buildFrom(), vpFeaturePoint3D::buildFrom(), vpFeatureThetaU::buildFrom(), vpFeaturePointPolar::buildFrom(), vpFeatureMoment::duplicate(), init(), vpFeatureVanishingPoint::init(), vpFeatureLuminance::init(), vpFeatureSegment::init(), vpFeatureDepth::init(), vpFeaturePoint::init(), vpFeatureMoment::init(), vpFeatureLine::init(), vpFeaturePoint3D::init(), vpFeatureThetaU::init(), vpFeaturePointPolar::init(), vpFeatureTranslation::init(), interaction(), vpFeatureVanishingPoint::interaction(), vpFeatureSegment::interaction(), vpFeatureDepth::interaction(), vpFeaturePoint::interaction(), vpFeatureLine::interaction(), vpFeaturePoint3D::interaction(), vpFeatureThetaU::interaction(), vpFeaturePointPolar::interaction(), vpFeatureTranslation::interaction(), vpBasicFeature::operator=(), vpBasicFeature::resetFlags(), vpFeaturePointPolar::set_rhoThetaZ(), vpFeaturePoint::set_xyZ(), vpFeaturePoint3D::set_XYZ(), vpFeatureDepth::set_xyZLogZoverZstar(), setABC(), vpFeatureLine::setABCD(), vpBasicFeature::setFlags(), vpFeatureMoment::update(), and vpFeatureLuminance::vpFeatureLuminance().
|
protectedinherited |
State of the visual feature.
Definition at line 90 of file vpBasicFeature.h.
Referenced by buildFrom(), vpFeatureLuminance::buildFrom(), vpFeatureVanishingPoint::buildFrom(), vpFeatureDepth::buildFrom(), vpFeaturePoint::buildFrom(), vpFeatureLine::buildFrom(), vpFeaturePoint3D::buildFrom(), vpFeatureThetaU::buildFrom(), vpFeaturePointPolar::buildFrom(), vpFeatureTranslation::buildFrom(), display(), vpFeatureMoment::duplicate(), error(), vpFeatureVanishingPoint::error(), vpBasicFeature::error(), vpFeatureLuminance::error(), vpFeatureMomentAlpha::error(), vpGenericFeature::error(), vpFeatureDepth::error(), vpFeaturePoint::error(), vpFeatureLine::error(), vpFeaturePoint3D::error(), vpFeatureThetaU::error(), vpFeaturePointPolar::error(), vpFeatureTranslation::error(), vpFeatureDepth::get_LogZoverZstar(), vpFeaturePointPolar::get_rho(), vpBasicFeature::get_s(), vpGenericFeature::get_s(), vpFeaturePointPolar::get_theta(), vpFeatureThetaU::get_TUx(), vpFeatureThetaU::get_TUy(), vpFeatureThetaU::get_TUz(), vpFeatureTranslation::get_Tx(), vpFeatureTranslation::get_Ty(), vpFeatureTranslation::get_Tz(), vpFeatureVanishingPoint::get_x(), vpFeaturePoint::get_x(), vpFeaturePoint3D::get_X(), vpFeatureVanishingPoint::get_y(), vpFeaturePoint::get_y(), vpFeaturePoint3D::get_Y(), vpFeaturePoint3D::get_Z(), vpBasicFeature::getDimension(), init(), vpFeatureVanishingPoint::init(), vpFeatureLuminance::init(), vpFeatureSegment::init(), vpFeatureDepth::init(), vpGenericFeature::init(), vpFeaturePoint::init(), vpFeatureMoment::init(), vpFeatureLine::init(), vpFeaturePoint3D::init(), vpFeatureThetaU::init(), vpFeaturePointPolar::init(), vpFeatureTranslation::init(), interaction(), vpFeatureLine::interaction(), vpFeatureThetaU::interaction(), vpFeatureTranslation::interaction(), vpBasicFeature::operator=(), print(), vpFeatureSegment::print(), vpGenericFeature::print(), vpFeatureMoment::print(), vpFeatureLine::print(), vpFeatureThetaU::print(), vpFeatureTranslation::print(), vpFeatureDepth::set_LogZoverZstar(), vpFeaturePointPolar::set_rho(), vpGenericFeature::set_s(), vpFeaturePointPolar::set_theta(), vpFeatureThetaU::set_TUx(), vpFeatureThetaU::set_TUy(), vpFeatureThetaU::set_TUz(), vpFeatureTranslation::set_Tx(), vpFeatureTranslation::set_Ty(), vpFeatureTranslation::set_Tz(), set_x(), vpFeatureVanishingPoint::set_x(), vpFeaturePoint::set_x(), vpFeaturePoint3D::set_X(), set_xy(), set_y(), vpFeatureVanishingPoint::set_y(), vpFeaturePoint::set_y(), vpFeaturePoint3D::set_Y(), vpFeaturePoint3D::set_Z(), setMu(), vpFeatureLine::setRhoTheta(), vpFeatureMoment::update(), and vpGenericFeature::vpGenericFeature().