Visual Servoing Platform  version 3.3.1 under development (2020-04-08)
vpPoint Class Reference

#include <visp3/core/vpPoint.h>

+ Inheritance diagram for vpPoint:

Public Types

enum  vpForwardProjectionDeallocatorType { user, vpDisplayForwardProjection }
 

Public Member Functions

 vpPoint ()
 
 vpPoint (double oX, double oY, double oZ)
 
 vpPoint (const vpColVector &oP)
 
 vpPoint (const std::vector< double > &oP)
 
virtual ~vpPoint ()
 
void changeFrame (const vpHomogeneousMatrix &cMo, vpColVector &cP) const
 
void changeFrame (const vpHomogeneousMatrix &cMo)
 
void display (const vpImage< unsigned char > &I, const vpCameraParameters &cam, const vpColor &color=vpColor::green, unsigned int thickness=1)
 
void display (const vpImage< unsigned char > &I, const vpHomogeneousMatrix &cMo, const vpCameraParameters &cam, const vpColor &color=vpColor::green, unsigned int thickness=1)
 
void display (const vpImage< vpRGBa > &I, const vpHomogeneousMatrix &cMo, const vpCameraParameters &cam, const vpColor &color=vpColor::green, unsigned int thickness=1)
 
vpPointduplicate () const
 
double get_X () const
 
double get_Y () const
 
double get_Z () const
 
double get_W () const
 
double get_oX () const
 
double get_oY () const
 
double get_oZ () const
 
double get_oW () const
 
double get_x () const
 
double get_y () const
 
double get_w () const
 
void getWorldCoordinates (double &oX, double &oY, double &oZ)
 
void getWorldCoordinates (vpColVector &oP)
 
vpColVector getWorldCoordinates (void)
 
void getWorldCoordinates (std::vector< double > &oP)
 
vpPointoperator= (const vpPoint &vpp)=default
 
void projection (const vpColVector &_cP, vpColVector &_p) const
 
void projection ()
 
void set_X (double cX)
 
void set_Y (double cY)
 
void set_Z (double cZ)
 
void set_W (double cW)
 
void set_oX (double oX)
 
void set_oY (double oY)
 
void set_oZ (double oZ)
 
void set_oW (double oW)
 
void set_x (double x)
 
void set_y (double y)
 
void set_w (double w)
 
void setWorldCoordinates (double oX, double oY, double oZ)
 
void setWorldCoordinates (const vpColVector &oP)
 
void setWorldCoordinates (const std::vector< double > &oP)
 
Public Member Functions Inherited from vpForwardProjection
vpColVector get_oP () const
 
vpForwardProjectionDeallocatorType getDeallocate ()
 
virtual void print () const
 
void project ()
 
void project (const vpHomogeneousMatrix &cMo)
 
void setDeallocate (vpForwardProjectionDeallocatorType d)
 
void track (const vpHomogeneousMatrix &cMo)
 
Public Member Functions Inherited from vpTracker
vpColVector get_p () const
 
vpColVector get_cP () const
 

Public Attributes

Public Attributes Inherited from vpForwardProjection
vpColVector oP
 
Public Attributes Inherited from vpTracker
vpColVector p
 
vpColVector cP
 
bool cPAvailable
 

Protected Member Functions

void init ()
 

Friends

VISP_EXPORT std::ostream & operator<< (std::ostream &os, const vpPoint &vpp)
 

Detailed Description

Class that defines a 3D point in the object frame and allows forward projection of a 3D point in the camera frame and in the 2D image plane by perspective projection. All the parameters must be set in meter.

A 3D point has the followings parameters:

Examples:
AROgre.cpp, AROgreBasic.cpp, homographyHartleyDLT2DObject.cpp, homographyHLM2DObject.cpp, homographyHLM3DObject.cpp, manGeometricFeatures.cpp, manServo4PointsDisplay.cpp, manServoMomentsSimple.cpp, manSimu4Dots.cpp, manSimu4Points.cpp, mbot-apriltag-ibvs.cpp, poseVirtualVS.cpp, servoAfma62DhalfCamVelocity.cpp, servoAfma6FourPoints2DCamVelocityLs_cur.cpp, servoAfma6FourPoints2DCamVelocityLs_des.cpp, servoAfma6Points2DCamVelocityEyeToHand.cpp, servoBebop2.cpp, servoMomentPoints.cpp, servoMomentPolygon.cpp, servoPioneerPanSegment3D.cpp, servoSimu4Points.cpp, servoSimuAfma6FourPoints2DCamVelocity.cpp, servoSimuFourPoints2DCamVelocity.cpp, servoSimuFourPoints2DCamVelocityDisplay.cpp, servoSimuFourPoints2DPolarCamVelocityDisplay.cpp, servoSimuPoint2DCamVelocity1.cpp, servoSimuPoint2DCamVelocity2.cpp, servoSimuPoint2DCamVelocity3.cpp, servoSimuPoint2DhalfCamVelocity1.cpp, servoSimuPoint2DhalfCamVelocity2.cpp, servoSimuPoint2DhalfCamVelocity3.cpp, servoSimuPoint3DCamVelocity.cpp, servoSimuViper850FourPoints2DCamVelocity.cpp, servoViper850FourPoints2DArtVelocityLs_cur.cpp, servoViper850FourPoints2DCamVelocityLs_cur.cpp, servoViper850FourPointsKinect.cpp, simulateFourPoints2DCartesianCamVelocity.cpp, simulateFourPoints2DPolarCamVelocity.cpp, testAprilTag.cpp, testConvert.cpp, testFeatureSegment.cpp, testFindMatch.cpp, testKeyPoint-4.cpp, testPoseFeatures.cpp, testPoseRansac.cpp, testRobotAfma6Pose.cpp, testRobotViper850Pose.cpp, tutorial-chessboard-pose.cpp, tutorial-count-coins.cpp, tutorial-homography-from-points.cpp, tutorial-ibvs-4pts-display.cpp, tutorial-ibvs-4pts-image-tracking.cpp, tutorial-ibvs-4pts-ogre-tracking.cpp, tutorial-ibvs-4pts-ogre.cpp, tutorial-ibvs-4pts-plotter-continuous-gain-adaptive.cpp, tutorial-ibvs-4pts-plotter-gain-adaptive.cpp, tutorial-ibvs-4pts-plotter.cpp, tutorial-ibvs-4pts-wireframe-robot-afma6.cpp, tutorial-ibvs-4pts-wireframe-robot-viper.cpp, tutorial-ibvs-4pts.cpp, tutorial-pose-from-points-image.cpp, tutorial-pose-from-points-live.cpp, tutorial-pose-from-qrcode-image.cpp, tutorial-simu-pioneer-continuous-gain-adaptive.cpp, tutorial-simu-pioneer-continuous-gain-constant.cpp, tutorial-simu-pioneer-pan.cpp, and tutorial-simu-pioneer.cpp.

Definition at line 81 of file vpPoint.h.

Member Enumeration Documentation

◆ vpForwardProjectionDeallocatorType

Used for memory issue especially in the vpServo class.

Enumerator
user 
vpDisplayForwardProjection 

Definition at line 73 of file vpForwardProjection.h.

Constructor & Destructor Documentation

◆ vpPoint() [1/4]

vpPoint::vpPoint ( )

Basic constructor.

Definition at line 64 of file vpPoint.cpp.

References init().

Referenced by changeFrame().

◆ vpPoint() [2/4]

vpPoint::vpPoint ( double  oX,
double  oY,
double  oZ 
)

Construction from a 3D point with coordinates in object frame.

Parameters
oX,oY,oZCoordinates of a 3D point in object frame.

Definition at line 70 of file vpPoint.cpp.

References init(), and setWorldCoordinates().

◆ vpPoint() [3/4]

vpPoint::vpPoint ( const vpColVector oP_)
explicit

Construction from a 3D point with coordinates in object frame.

Parameters
oP_Vector containing the coordinates of the 3D point in the object frame. This vector could be of dimension 3 or 4.
  • If dimension is 3, oP corresponds to the normalized coordinates oP = (oX, oY, oZ, 1) where oP[0]=oX, oP[1]=oY, oP[2]=oZ.
  • If dimension is 4, oP corresponds to the normalized coordinates oP = (oX, oY, oZ, oW) where oP[0]=oX, oP[1]=oY, oP[2]=oZ and oP[3]=oW.

Definition at line 86 of file vpPoint.cpp.

References init(), and setWorldCoordinates().

◆ vpPoint() [4/4]

vpPoint::vpPoint ( const std::vector< double > &  oP_)
explicit

Construction from a 3D point with coordinates in object frame.

Parameters
oP_Vector containing the coordinates of the 3D point in the object frame. This vector could be of dimension 3 or 4.
  • If dimension is 3, oP corresponds to the normalized coordinates oP = (oX, oY, oZ, 1) where oP[0]=oX, oP[1]=oY, oP[2]=oZ.
  • If dimension is 4, oP corresponds to the normalized coordinates oP = (oX, oY, oZ, oW) where oP[0]=oX, oP[1]=oY, oP[2]=oZ and oP[3]=oW.

Definition at line 102 of file vpPoint.cpp.

References init(), and setWorldCoordinates().

◆ ~vpPoint()

Member Function Documentation

◆ changeFrame() [1/2]

◆ changeFrame() [2/2]

void vpPoint::changeFrame ( const vpHomogeneousMatrix cMo)
virtual

From the 3D coordinates of the point in the object frame oP that are set using for example setWorldCoordinates() or set_oX(), set_oY(), set_oZ(), compute the 3D coordinates of the point in the camera frame cP = cMo * oP.

Parameters
cMo: Transformation from camera to object frame.

Implements vpForwardProjection.

Definition at line 263 of file vpPoint.cpp.

References vpTracker::cP, duplicate(), get_W(), get_w(), get_X(), get_x(), get_Y(), get_y(), get_Z(), vpForwardProjection::oP, operator*(), set_oW(), set_oX(), set_oY(), set_oZ(), set_W(), set_w(), set_X(), set_x(), set_Y(), set_y(), set_Z(), and vpPoint().

◆ display() [1/3]

void vpPoint::display ( const vpImage< unsigned char > &  I,
const vpCameraParameters cam,
const vpColor color = vpColor::green,
unsigned int  thickness = 1 
)
virtual

Display the projection of a 3D point in image I.

Parameters
I: Image used as background.
cam: Camera parameters.
color: Color used to draw the point.
thickness: Thickness used to draw the point.

Implements vpForwardProjection.

Examples:
manGeometricFeatures.cpp, and servoAfma6Points2DCamVelocityEyeToHand.cpp.

Definition at line 430 of file vpPoint.cpp.

References vpFeatureDisplay::displayPoint(), and vpTracker::p.

◆ display() [2/3]

void vpPoint::display ( const vpImage< unsigned char > &  I,
const vpHomogeneousMatrix cMo,
const vpCameraParameters cam,
const vpColor color = vpColor::green,
unsigned int  thickness = 1 
)
virtual

Display the projection of a 3D point in image I. This method is non destructive wrt. cP and p internal 3D point parameters.

Parameters
I: Image used as background.
cMo: Homogeneous transformation from camera frame to object frame. The point is considered as viewed from this camera position.
cam: Camera parameters.
color: Color used to draw the sphere.
thickness: Thickness used to draw the sphere.

Implements vpForwardProjection.

Definition at line 370 of file vpPoint.cpp.

References changeFrame(), vpFeatureDisplay::displayPoint(), and projection().

◆ display() [3/3]

void vpPoint::display ( const vpImage< vpRGBa > &  I,
const vpHomogeneousMatrix cMo,
const vpCameraParameters cam,
const vpColor color = vpColor::green,
unsigned int  thickness = 1 
)

Display the projection of a 3D point in image I. This method is non destructive wrt. cP and p internal 3D point parameters.

Parameters
I: Image used as background.
cMo: Homogeneous transformation from camera frame to object frame. The point is considered as viewed from this camera position.
cam: Camera parameters.
color: Color used to draw the sphere.
thickness: Thickness used to draw the sphere.

Definition at line 395 of file vpPoint.cpp.

References changeFrame(), vpFeatureDisplay::displayPoint(), and projection().

◆ duplicate()

vpPoint * vpPoint::duplicate ( ) const
virtual

For memory issue (used by the vpServo class only).

Implements vpForwardProjection.

Definition at line 353 of file vpPoint.cpp.

Referenced by changeFrame().

◆ get_cP()

vpColVector vpTracker::get_cP ( ) const
inlineinherited

Return object parameters expressed in the 3D camera frame.

Definition at line 99 of file vpTracker.h.

◆ get_oP()

vpColVector vpForwardProjection::get_oP ( ) const
inlineinherited

Return object parameters expressed in the 3D object frame.

Definition at line 165 of file vpForwardProjection.h.

◆ get_oW()

double vpPoint::get_oW ( ) const

Get the point oW coordinate in the object frame.

Definition at line 453 of file vpPoint.cpp.

References vpForwardProjection::oP.

◆ get_oX()

◆ get_oY()

◆ get_oZ()

◆ get_p()

vpColVector vpTracker::get_p ( ) const
inlineinherited

Return object parameters expressed in the 2D image plane computed by perspective projection.

Definition at line 97 of file vpTracker.h.

◆ get_W()

double vpPoint::get_W ( ) const

Get the point cW coordinate in the camera frame.

Definition at line 444 of file vpPoint.cpp.

References vpTracker::cP.

Referenced by changeFrame(), vpHomogeneousMatrix::operator*(), and vpPlane::projectionPointOnPlan().

◆ get_w()

double vpPoint::get_w ( ) const

Get the point w coordinate in the image plane.

Examples:
homographyHartleyDLT2DObject.cpp, homographyHLM2DObject.cpp, and homographyHLM3DObject.cpp.

Definition at line 460 of file vpPoint.cpp.

References vpTracker::p.

Referenced by changeFrame(), and vpHomography::operator*().

◆ get_X()

◆ get_x()

◆ get_Y()

◆ get_y()

◆ get_Z()

◆ getDeallocate()

vpForwardProjectionDeallocatorType vpForwardProjection::getDeallocate ( )
inlineinherited

Definition at line 167 of file vpForwardProjection.h.

◆ getWorldCoordinates() [1/4]

void vpPoint::getWorldCoordinates ( double &  oX,
double &  oY,
double &  oZ 
)

Get the point object frame coordinates.

Definition at line 178 of file vpPoint.cpp.

References vpForwardProjection::oP.

◆ getWorldCoordinates() [2/4]

void vpPoint::getWorldCoordinates ( vpColVector oP_)

Get the point object frame normalized coordinates.

Parameters
oP_Normalized coordinates of the point in the object frame oP = (oX, oY, oZ, oW) as a 4-dim vector.

Definition at line 191 of file vpPoint.cpp.

References vpForwardProjection::oP.

◆ getWorldCoordinates() [3/4]

vpColVector vpPoint::getWorldCoordinates ( void  )

Return the point object frame normalized coordinates.

Returns
Normalized coordinates of the point in the object frame oP = (oX, oY, oZ, oW) as a 4-dim vector.

Definition at line 212 of file vpPoint.cpp.

References vpForwardProjection::oP.

◆ getWorldCoordinates() [4/4]

void vpPoint::getWorldCoordinates ( std::vector< double > &  oP_)

Get the point object frame normalized coordinates.

Parameters
oP_Normalized coordinates of the point in the object frame oP = (oX, oY, oZ, oW) as a 4-dim vector.

Definition at line 199 of file vpPoint.cpp.

References vpForwardProjection::oP, vpColVector::resize(), and vpArray2D< Type >::size().

◆ init()

void vpPoint::init ( )
protectedvirtual

Basic construction.

Implements vpForwardProjection.

Definition at line 48 of file vpPoint.cpp.

References vpTracker::cP, vpForwardProjection::oP, vpTracker::p, vpColVector::resize(), and set_Z().

Referenced by vpPoint().

◆ operator=()

vpPoint& vpPoint::operator= ( const vpPoint vpp)
default

◆ print()

void vpForwardProjection::print ( ) const
virtualinherited

Print to stdout the feature parameters in:

  • the object frame
  • the camera frame
  • the image plane.
Examples:
servoSimuCircle2DCamVelocityDisplay.cpp, servoSimuLine2DCamVelocityDisplay.cpp, and servoSimuSquareLine2DCamVelocityDisplay.cpp.

Definition at line 53 of file vpForwardProjection.cpp.

References vpTracker::cP, vpForwardProjection::oP, vpTracker::p, and vpColVector::t().

◆ project() [1/2]

◆ project() [2/2]

void vpForwardProjection::project ( const vpHomogeneousMatrix cMo)
inherited

Compute the feature parameters in the camera frame (vpTracker::cP) and than compute the projection of these parameters in the image plane (vpTracker::p).

Warning
The feature parameters in the object frame (vpForwardProjection:oP) need to be set prior the use of this method. To initialize these parameters see setWorldCoordinates().
Parameters
cMo: The homogeneous matrix corresponding to the pose between the camera frame and the object frame.

Definition at line 84 of file vpForwardProjection.cpp.

References vpForwardProjection::changeFrame(), and vpForwardProjection::projection().

◆ projection() [1/2]

void vpPoint::projection ( const vpColVector _cP,
vpColVector _p 
) const
virtual

Projection onto the image plane of a point. Input: the 3D coordinates in the camera frame _cP, output : the 2D coordinates _p.

Compute the perspective projection of a point _cP.

Parameters
_cP: 3-dim vector cP = (cX, cY, cZ) or 4-dim vector cP = (cX, cY, cZ, 1) corresponding to the normalized coordinates of the 3D point in the camera frame.
_p: Coordinates of the point in the image plane obtained by perspective projection.

Implements vpForwardProjection.

Examples:
servoAfma6FourPoints2DCamVelocityLs_cur.cpp, servoAfma6FourPoints2DCamVelocityLs_des.cpp, servoAfma6Points2DCamVelocityEyeToHand.cpp, servoViper850FourPoints2DArtVelocityLs_cur.cpp, servoViper850FourPoints2DCamVelocityLs_cur.cpp, and servoViper850FourPointsKinect.cpp.

Definition at line 222 of file vpPoint.cpp.

References vpColVector::resize().

Referenced by vpPolygon3D::changeFrame(), vpPolygon3D::computePolygonClipped(), vpMbtDistanceCylinder::getModelForDisplay(), vpMbtDistanceCylinder::initMovingEdge(), and vpMbtDistanceCylinder::updateMovingEdge().

◆ projection() [2/2]

void vpPoint::projection ( )
virtual

Perspective projection of the 3D point.

Projection onto the image plane of the point. Update the object attribute p (2D homogeneous coordinates) according to object attribute cP (current 3D coordinates in the camera frame).

Implements vpForwardProjection.

Definition at line 470 of file vpPoint.cpp.

References vpTracker::cP, and vpTracker::p.

Referenced by display().

◆ set_oW()

void vpPoint::set_oW ( double  oW)

Set the point oW coordinate in the object frame.

Definition at line 494 of file vpPoint.cpp.

References vpForwardProjection::oP.

Referenced by changeFrame(), and vpHomogeneousMatrix::operator*().

◆ set_oX()

void vpPoint::set_oX ( double  oX)

Set the point oX coordinate in the object frame.

Examples:
testConvert.cpp, and tutorial-chessboard-pose.cpp.

Definition at line 488 of file vpPoint.cpp.

References vpForwardProjection::oP.

Referenced by changeFrame(), vpKeyPoint::computePose(), vpHomogeneousMatrix::operator*(), vpPose::poseDementhonNonPlan(), and vpPose::poseDementhonPlan().

◆ set_oY()

void vpPoint::set_oY ( double  oY)

Set the point oY coordinate in the object frame.

Examples:
testConvert.cpp, and tutorial-chessboard-pose.cpp.

Definition at line 490 of file vpPoint.cpp.

References vpForwardProjection::oP.

Referenced by changeFrame(), vpKeyPoint::computePose(), vpHomogeneousMatrix::operator*(), vpPose::poseDementhonNonPlan(), and vpPose::poseDementhonPlan().

◆ set_oZ()

void vpPoint::set_oZ ( double  oZ)

Set the point oZ coordinate in the object frame.

Examples:
testConvert.cpp, and tutorial-chessboard-pose.cpp.

Definition at line 492 of file vpPoint.cpp.

References vpForwardProjection::oP.

Referenced by changeFrame(), vpKeyPoint::computePose(), vpHomogeneousMatrix::operator*(), vpPose::poseDementhonNonPlan(), and vpPose::poseDementhonPlan().

◆ set_W()

void vpPoint::set_W ( double  cW)

Set the point cW coordinate in the camera frame.

Definition at line 485 of file vpPoint.cpp.

References vpTracker::cP.

Referenced by changeFrame(), vpHomogeneousMatrix::operator*(), and vpPlane::projectionPointOnPlan().

◆ set_w()

void vpPoint::set_w ( double  w)

Set the point w coordinate in the image plane.

Definition at line 501 of file vpPoint.cpp.

References vpTracker::p.

Referenced by changeFrame(), and vpHomography::operator*().

◆ set_X()

◆ set_x()

◆ set_Y()

◆ set_y()

◆ set_Z()

◆ setDeallocate()

void vpForwardProjection::setDeallocate ( vpForwardProjectionDeallocatorType  d)
inlineinherited

Definition at line 196 of file vpForwardProjection.h.

References vpTracker::init().

◆ setWorldCoordinates() [1/3]

void vpPoint::setWorldCoordinates ( double  oX,
double  oY,
double  oZ 
)

Set the 3D point object frame coordinates oP = (oX, oY, oZ, 1).

Parameters
oX,oY,oZCoordinates of a 3D point in the object frame.
Examples:
AROgre.cpp, AROgreBasic.cpp, homographyHartleyDLT2DObject.cpp, homographyHLM2DObject.cpp, homographyHLM3DObject.cpp, manGeometricFeatures.cpp, manServo4PointsDisplay.cpp, manSimu4Dots.cpp, manSimu4Points.cpp, poseVirtualVS.cpp, servoAfma62DhalfCamVelocity.cpp, servoAfma6FourPoints2DCamVelocityLs_cur.cpp, servoAfma6FourPoints2DCamVelocityLs_des.cpp, servoAfma6Points2DCamVelocityEyeToHand.cpp, servoPioneerPanSegment3D.cpp, servoSimu4Points.cpp, servoSimuAfma6FourPoints2DCamVelocity.cpp, servoSimuFourPoints2DCamVelocity.cpp, servoSimuFourPoints2DCamVelocityDisplay.cpp, servoSimuFourPoints2DPolarCamVelocityDisplay.cpp, servoSimuViper850FourPoints2DCamVelocity.cpp, servoViper850FourPoints2DArtVelocityLs_cur.cpp, servoViper850FourPoints2DCamVelocityLs_cur.cpp, servoViper850FourPointsKinect.cpp, simulateFourPoints2DCartesianCamVelocity.cpp, simulateFourPoints2DPolarCamVelocity.cpp, testFeatureSegment.cpp, testRobotAfma6Pose.cpp, testRobotViper850Pose.cpp, tutorial-ibvs-4pts-ogre.cpp, tutorial-ibvs-4pts-plotter-continuous-gain-adaptive.cpp, tutorial-ibvs-4pts-plotter-gain-adaptive.cpp, tutorial-ibvs-4pts-plotter.cpp, and tutorial-ibvs-4pts.cpp.

Definition at line 113 of file vpPoint.cpp.

References vpForwardProjection::oP.

Referenced by vpMbTracker::addPolygon(), vpMbTracker::addProjectionErrorPolygon(), vpKeyPoint::compute3D(), vpKeyPoint::compute3DForPointsOnCylinders(), vpMbtFaceDepthNormal::computeDesiredNormalAndCentroid(), vpMbTracker::extractCylinders(), vpMbTracker::extractFaces(), vpMbTracker::extractLines(), vpMbTracker::getGravityCenter(), vpProjectionDisplay::init(), vpMbtDistanceKltCylinder::init(), vpMbTracker::initFromPoints(), vpMbTracker::loadCAOModel(), vpKeyPoint::matchPoint(), vpPose::poseFromRectangle(), vpWireFrameSimulator::projectCameraTrajectory(), and vpPoint().

◆ setWorldCoordinates() [2/3]

void vpPoint::setWorldCoordinates ( const vpColVector oP_)
virtual

Set the 3D point object frame coordinates.

Parameters
oP_Vector containing the coordinates of the 3D point in the object frame. This vector could be of dimension 3 or 4.
  • If dimension is 3, oP corresponds to the normalized coordinates oP = (oX, oY, oZ, 1) where oP[0]=oX, oP[1]=oY, oP[2]=oZ.
  • If dimension is 4, oP corresponds to the normalized coordinates oP = (oX, oY, oZ, oW) where oP[0]=oX, oP[1]=oY, oP[2]=oZ and oP[3]=oW.

Implements vpForwardProjection.

Definition at line 131 of file vpPoint.cpp.

References vpException::dimensionError, vpForwardProjection::oP, and vpArray2D< Type >::size().

◆ setWorldCoordinates() [3/3]

void vpPoint::setWorldCoordinates ( const std::vector< double > &  oP_)

Set the 3D point object frame coordinates.

Parameters
oP_Vector containing the coordinates of the 3D point in the object frame. This vector could be of dimension 3 or 4.
  • If dimension is 3, oP corresponds to the normalized coordinates oP = (oX, oY, oZ, 1) where oP[0]=oX, oP[1]=oY, oP[2]=oZ.
  • If dimension is 4, oP corresponds to the normalized coordinates oP = (oX, oY, oZ, oW) where oP[0]=oX, oP[1]=oY, oP[2]=oZ and oP[3]=oW.

Definition at line 159 of file vpPoint.cpp.

References vpException::dimensionError, and vpForwardProjection::oP.

◆ track()

void vpForwardProjection::track ( const vpHomogeneousMatrix cMo)
inherited

Track the feature parameters in the camera frame (vpTracker::cP) and than compute the projection of these parameters in the image plane (vpTracker::p).

This method is similar to project(const vpHomogeneousMatrix &).

Warning
The feature parameters in the object frame (vpForwardProjection:oP) need to be set prior the use of this method. To initialize these parameters see setWorldCoordinates().
Parameters
cMo: The homogeneous matrix corresponding to the pose between the camera frame and the object frame.
Examples:
mbot-apriltag-ibvs.cpp, servoBebop2.cpp, servoMomentPoints.cpp, servoMomentPolygon.cpp, servoSimu4Points.cpp, servoSimuAfma6FourPoints2DCamVelocity.cpp, servoSimuCircle2DCamVelocity.cpp, servoSimuCircle2DCamVelocityDisplay.cpp, servoSimuCylinder.cpp, servoSimuFourPoints2DCamVelocity.cpp, servoSimuFourPoints2DCamVelocityDisplay.cpp, servoSimuFourPoints2DPolarCamVelocityDisplay.cpp, servoSimuLine2DCamVelocityDisplay.cpp, servoSimuSphere.cpp, servoSimuSphere2DCamVelocity.cpp, servoSimuSphere2DCamVelocityDisplay.cpp, servoSimuSphere2DCamVelocityDisplaySecondaryTask.cpp, servoSimuSquareLine2DCamVelocityDisplay.cpp, servoSimuViper850FourPoints2DCamVelocity.cpp, simulateCircle2DCamVelocity.cpp, simulateFourPoints2DCartesianCamVelocity.cpp, simulateFourPoints2DPolarCamVelocity.cpp, tutorial-ibvs-4pts-ogre.cpp, tutorial-ibvs-4pts-plotter-continuous-gain-adaptive.cpp, tutorial-ibvs-4pts-plotter-gain-adaptive.cpp, tutorial-ibvs-4pts-plotter.cpp, tutorial-ibvs-4pts.cpp, tutorial-simu-pioneer-continuous-gain-adaptive.cpp, tutorial-simu-pioneer-continuous-gain-constant.cpp, tutorial-simu-pioneer-pan.cpp, and tutorial-simu-pioneer.cpp.

Definition at line 106 of file vpForwardProjection.cpp.

References vpForwardProjection::project().

Referenced by vpPoseFeatures::addFeatureSegment(), vpPose::computeResidual(), vpProjectionDisplay::displayCamera(), vpImageDraw::drawFrame(), vpPose::poseVirtualVS(), vpPose::poseVirtualVSrobust(), vpWireFrameSimulator::projectCameraTrajectory(), vpSimulatorAfma6::updateArticularPosition(), and vpSimulatorViper850::updateArticularPosition().

Friends And Related Function Documentation

◆ operator<<

VISP_EXPORT std::ostream& operator<< ( std::ostream &  os,
const vpPoint vpp 
)
friend

Definition at line 408 of file vpPoint.cpp.

Member Data Documentation

◆ cP

◆ cPAvailable

bool vpTracker::cPAvailable
inherited

Flag used to indicate if the feature parameters cP expressed in the camera frame are available.

Definition at line 83 of file vpTracker.h.

Referenced by vpTracker::init(), and vpTracker::operator=().

◆ oP

◆ p