39 #ifndef vpWireFrameSimulator_HH 40 #define vpWireFrameSimulator_HH 52 #include <visp3/core/vpConfig.h> 54 #include <visp3/core/vpConfig.h> 55 #include <visp3/core/vpDisplay.h> 56 #include <visp3/core/vpHomogeneousMatrix.h> 57 #include <visp3/core/vpImage.h> 58 #ifdef VISP_BUILD_DEPRECATED_FUNCTIONS 59 #include <visp3/core/vpList.h> 61 #include <visp3/core/vpImagePoint.h> 62 #include <visp3/robot/vpImageSimulator.h> 63 #include <visp3/robot/vpWireFrameSimulatorTypes.h> 282 std::string scene_dir;
296 cameraTrajectory.clear();
303 void displayTrajectory(
const vpImage<vpRGBa> &I,
const std::list<vpHomogeneousMatrix> &list_cMo,
317 if ((std::fabs(px_ext - 1.) >
vpMath::maximum(px_ext, 1.) * std::numeric_limits<double>::epsilon()) &&
318 (std::fabs(py_ext - 1) >
vpMath::maximum(py_ext, 1.) * std::numeric_limits<double>::epsilon()))
336 if ((std::fabs(px_ext - 1.) >
vpMath::maximum(px_ext, 1.) * std::numeric_limits<double>::epsilon()) &&
337 (std::fabs(py_ext - 1) >
vpMath::maximum(py_ext, 1.) * std::numeric_limits<double>::epsilon()))
369 if ((std::fabs(px_int - 1.) >
vpMath::maximum(px_int, 1.) * std::numeric_limits<double>::epsilon()) &&
370 (std::fabs(py_int - 1) >
vpMath::maximum(py_int, 1.) * std::numeric_limits<double>::epsilon()))
388 if ((std::fabs(px_int - 1.) >
vpMath::maximum(px_int, 1.) * std::numeric_limits<double>::epsilon()) &&
389 (std::fabs(py_int - 1) >
vpMath::maximum(py_int, 1.) * std::numeric_limits<double>::epsilon()))
416 for (std::list<vpHomogeneousMatrix>::const_iterator it = poseList.begin(); it != poseList.end(); ++it) {
417 cMo_history.push_back(rotz * (*it));
434 void get_fMo_History(std::list<vpHomogeneousMatrix> &fMo_history) { fMo_history = fMoList; }
436 void initScene(
const vpSceneObject &obj,
const vpSceneDesiredObject &desiredObject);
437 void initScene(
const char *obj,
const char *desiredObject);
438 void initScene(
const vpSceneObject &obj);
439 void initScene(
const char *obj);
441 void initScene(
const vpSceneObject &obj,
const vpSceneDesiredObject &desiredObject,
442 const std::list<vpImageSimulator> &imObj);
443 void initScene(
const char *obj,
const char *desiredObject,
const std::list<vpImageSimulator> &imObj);
444 void initScene(
const vpSceneObject &obj,
const std::list<vpImageSimulator> &imObj);
445 void initScene(
const char *obj,
const std::list<vpImageSimulator> &imObj);
460 this->cMo = rotz * cMo_;
461 fMc = fMo * this->cMo.
inverse();
472 this->fMc = fMc_ * rotz;
473 cMo = this->fMc.
inverse() * fMo;
501 this->camTrajType = camTraj_type;
550 this->camMf = rotz * cam_Mf;
553 this->camMf2.
buildFrom(0, 0, T[2], 0, 0, 0);
554 f2Mf = camMf2.
inverse() * this->camMf;
555 extCamChanged =
true;
bool displayImageSimulator
A cylinder of 80cm length and 10cm radius.
void deleteCameraPositionHistory()
A tire represented by 2 circles with radius 10cm and 15cm.
Implementation of an homogeneous matrix and operations on such kind of matrices.
vpHomogeneousMatrix get_fMo() const
void setCameraColor(const vpColor &col)
void setDesiredViewColor(const vpColor &col)
void set_fMo(const vpHomogeneousMatrix &fMo_)
Class to define colors available for display functionnalities.
void setNbPtTrajectory(const unsigned int nbPt)
void get_cMo_History(std::list< vpHomogeneousMatrix > &cMo_history)
void setCameraPositionRelWorld(const vpHomogeneousMatrix &fMc_)
vpCameraParameters getExternalCameraParameters(const vpImage< vpRGBa > &I) const
std::list< vpImageSimulator > objectImage
void setCurrentViewColor(const vpColor &col)
std::list< vpImagePoint > cameraTrajectory
vpHomogeneousMatrix inverse() const
void setExternalCameraPosition(const vpHomogeneousMatrix &cam_Mf)
void extract(vpRotationMatrix &R) const
void setDesiredCameraPosition(const vpHomogeneousMatrix &cdMo_)
void setGraphicsThickness(unsigned int thickness)
std::list< vpHomogeneousMatrix > fMoList
static Type maximum(const Type &a, const Type &b)
void setCameraTrajectoryDisplayType(const vpCameraTrajectoryDisplayType &camTraj_type)
void setCameraTrajectoryColor(const vpColor &col)
vpHomogeneousMatrix get_cMo() const
Generic class defining intrinsic camera parameters.
bool displayDesiredObject
static Type minimum(const Type &a, const Type &b)
Implementation of a wire frame simulator. Compared to the vpSimulator class, it does not require thir...
void buildFrom(const vpTranslationVector &t, const vpRotationMatrix &R)
void setExternalCameraParameters(const vpCameraParameters &cam)
vpCameraTrajectoryDisplayType camTrajType
void setCameraPositionRelObj(const vpHomogeneousMatrix &cMo_)
vpSceneDesiredObject desiredObject
bool displayCameraTrajectory
vpHomogeneousMatrix camMf
Three parallel lines representing a road.
unsigned int getHeight() const
void setInternalCameraParameters(const vpCameraParameters &cam)
vpCameraTrajectoryDisplayType
void setDisplayCameraTrajectory(const bool &do_display)
void get_fMo_History(std::list< vpHomogeneousMatrix > &fMo_history)
vpHomogeneousMatrix refMo
vpCameraParameters getExternalCameraParameters(const vpImage< unsigned char > &I) const
Class that defines a 2D point in an image. This class is useful for image processing and stores only ...
unsigned int getWidth() const
Class that consider the case of a translation vector.
void setCameraSizeFactor(const float factor)
std::list< vpHomogeneousMatrix > poseList
vpCameraParameters getInternalCameraParameters(const vpImage< vpRGBa > &I) const
vpCameraParameters getInternalCameraParameters(const vpImage< unsigned char > &I) const
vpHomogeneousMatrix camMf2
vpHomogeneousMatrix getExternalCameraPosition() const