Visual Servoing Platform  version 3.3.0 under development (2020-02-17)
mbtEdgeTracking.cpp
1 /****************************************************************************
2  *
3  * ViSP, open source Visual Servoing Platform software.
4  * Copyright (C) 2005 - 2019 by Inria. All rights reserved.
5  *
6  * This software is free software; you can redistribute it and/or modify
7  * it under the terms of the GNU General Public License as published by
8  * the Free Software Foundation; either version 2 of the License, or
9  * (at your option) any later version.
10  * See the file LICENSE.txt at the root directory of this source
11  * distribution for additional information about the GNU GPL.
12  *
13  * For using ViSP with software that can not be combined with the GNU
14  * GPL, please contact Inria about acquiring a ViSP Professional
15  * Edition License.
16  *
17  * See http://visp.inria.fr for more information.
18  *
19  * This software was developed at:
20  * Inria Rennes - Bretagne Atlantique
21  * Campus Universitaire de Beaulieu
22  * 35042 Rennes Cedex
23  * France
24  *
25  * If you have questions regarding the use of this file, please contact
26  * Inria at visp@inria.fr
27  *
28  * This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE
29  * WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
30  *
31  * Description:
32  * Example of model based tracking.
33  *
34  * Authors:
35  * Nicolas Melchior
36  * Romain Tallonneau
37  * Aurelien Yol
38  *
39  *****************************************************************************/
40 
48 #include <iostream>
49 #include <visp3/core/vpConfig.h>
50 
51 #if defined(VISP_HAVE_MODULE_MBT) && defined(VISP_HAVE_DISPLAY)
52 
53 #include <visp3/core/vpDebug.h>
54 #include <visp3/core/vpHomogeneousMatrix.h>
55 #include <visp3/core/vpIoTools.h>
56 #include <visp3/core/vpMath.h>
57 #include <visp3/gui/vpDisplayD3D.h>
58 #include <visp3/gui/vpDisplayGDI.h>
59 #include <visp3/gui/vpDisplayGTK.h>
60 #include <visp3/gui/vpDisplayOpenCV.h>
61 #include <visp3/gui/vpDisplayX.h>
62 #include <visp3/io/vpImageIo.h>
63 #include <visp3/io/vpParseArgv.h>
64 #include <visp3/io/vpVideoReader.h>
65 #include <visp3/mbt/vpMbEdgeTracker.h>
66 
67 #define GETOPTARGS "x:m:i:n:de:chtfColwvp"
68 
69 void usage(const char *name, const char *badparam)
70 {
71  fprintf(stdout, "\n\
72 Example of tracking based on the 3D model.\n\
73 \n\
74 SYNOPSIS\n\
75  %s [-i <test image path>] [-x <config file>]\n\
76  [-m <model name>] [-n <initialisation file base name>] [-e <last frame index>]\n\
77  [-t] [-c] [-d] [-h] [-f] [-C] [-o] [-w] [-l] [-v] [-p]\n", name);
78 
79  fprintf(stdout, "\n\
80 OPTIONS: \n\
81  -i <input image path> \n\
82  Set image input path.\n\
83  From this path read images \n\
84  \"mbt/cube/image%%04d.ppm\". These \n\
85  images come from ViSP-images-x.y.z.tar.gz available \n\
86  on the ViSP website.\n\
87  Setting the VISP_INPUT_IMAGE_PATH environment\n\
88  variable produces the same behaviour than using\n\
89  this option.\n\
90 \n\
91  -x <config file> \n\
92  Set the config file (the xml file) to use.\n\
93  The config file is used to specify the parameters of the tracker.\n\
94 \n\
95  -m <model name> \n\
96  Specify the name of the file of the model\n\
97  The model can either be a vrml model (.wrl) or a .cao file.\n\
98 \n\
99  -e <last frame index> \n\
100  Specify the index of the last frame. Once reached, the tracking is stopped\n\
101 \n\
102  -f \n\
103  Do not use the vrml model, use the .cao one. These two models are \n\
104  equivalent and comes from ViSP-images-x.y.z.tar.gz available on the ViSP\n\
105  website. However, the .cao model allows to use the 3d model based tracker \n\
106  without Coin.\n\
107 \n\
108  -C \n\
109  Track only the cube (not the cylinder). In this case the models files are\n\
110  cube.cao or cube.wrl instead of cube_and_cylinder.cao and \n\
111  cube_and_cylinder.wrl.\n\
112 \n\
113  -n <initialisation file base name> \n\
114  Base name of the initialisation file. The file will be 'base_name'.init .\n\
115  This base name is also used for the optionnal picture specifying where to \n\
116  click (a .ppm picture).\n\
117 \n\
118  -t \n\
119  Turn off the display of the the moving edges. \n\
120 \n\
121  -d \n\
122  Turn off the display.\n\
123 \n\
124  -c\n\
125  Disable the mouse click. Useful to automaze the \n\
126  execution of this program without humain intervention.\n\
127 \n\
128  -o\n\
129  Use Ogre3D for visibility tests.\n\
130 \n\
131  -w\n\
132  When Ogre3D is enable [-o] show Ogre3D configuration dialog thatallows to set the renderer.\n\
133 \n\
134  -l\n\
135  Use the scanline for visibility tests.\n\
136 \n\
137  -v\n\
138  Compute covariance matrix.\n\
139 \n\
140  -p\n\
141  Compute gradient projection error.\n\
142 \n\
143  -h \n\
144  Print the help.\n\n");
145 
146  if (badparam)
147  fprintf(stdout, "\nERROR: Bad parameter [%s]\n", badparam);
148 }
149 
150 bool getOptions(int argc, const char **argv, std::string &ipath, std::string &configFile, std::string &modelFile,
151  std::string &initFile, long &lastFrame, bool &displayFeatures, bool &click_allowed, bool &display,
152  bool &cao3DModel, bool &trackCylinder, bool &useOgre, bool &showOgreConfigDialog, bool &useScanline,
153  bool &computeCovariance, bool &projectionError)
154 {
155  const char *optarg_;
156  int c;
157  while ((c = vpParseArgv::parse(argc, argv, GETOPTARGS, &optarg_)) > 1) {
158 
159  switch (c) {
160  case 'e':
161  lastFrame = atol(optarg_);
162  break;
163  case 'i':
164  ipath = optarg_;
165  break;
166  case 'x':
167  configFile = optarg_;
168  break;
169  case 'm':
170  modelFile = optarg_;
171  break;
172  case 'n':
173  initFile = optarg_;
174  break;
175  case 't':
176  displayFeatures = false;
177  break;
178  case 'f':
179  cao3DModel = true;
180  break;
181  case 'c':
182  click_allowed = false;
183  break;
184  case 'd':
185  display = false;
186  break;
187  case 'C':
188  trackCylinder = false;
189  break;
190  case 'o':
191  useOgre = true;
192  break;
193  case 'l':
194  useScanline = true;
195  break;
196  case 'w':
197  showOgreConfigDialog = true;
198  break;
199  case 'v':
200  computeCovariance = true;
201  break;
202  case 'p':
203  projectionError = true;
204  break;
205  case 'h':
206  usage(argv[0], NULL);
207  return false;
208  break;
209 
210  default:
211  usage(argv[0], optarg_);
212  return false;
213  break;
214  }
215  }
216 
217  if ((c == 1) || (c == -1)) {
218  // standalone param or error
219  usage(argv[0], NULL);
220  std::cerr << "ERROR: " << std::endl;
221  std::cerr << " Bad argument " << optarg_ << std::endl << std::endl;
222  return false;
223  }
224 
225  return true;
226 }
227 
228 int main(int argc, const char **argv)
229 {
230  try {
231  std::string env_ipath;
232  std::string opt_ipath;
233  std::string ipath;
234  std::string opt_configFile;
235  std::string configFile;
236  std::string opt_modelFile;
237  std::string modelFile;
238  std::string opt_initFile;
239  std::string initFile;
240  long opt_lastFrame = -1;
241  bool displayFeatures = true;
242  bool opt_click_allowed = true;
243  bool opt_display = true;
244  bool cao3DModel = false;
245  bool trackCylinder = true;
246  bool useOgre = false;
247  bool showOgreConfigDialog = false;
248  bool useScanline = false;
249  bool computeCovariance = false;
250  bool projectionError = false;
251  bool quit = false;
252 
253  // Get the visp-images-data package path or VISP_INPUT_IMAGE_PATH
254  // environment variable value
255  env_ipath = vpIoTools::getViSPImagesDataPath();
256 
257  // Set the default input path
258  if (!env_ipath.empty())
259  ipath = env_ipath;
260 
261  // Read the command line options
262  if (!getOptions(argc, argv, opt_ipath, opt_configFile, opt_modelFile, opt_initFile, opt_lastFrame, displayFeatures,
263  opt_click_allowed, opt_display, cao3DModel, trackCylinder, useOgre, showOgreConfigDialog,
264  useScanline, computeCovariance, projectionError)) {
265  return (-1);
266  }
267 
268  // Test if an input path is set
269  if (opt_ipath.empty() && env_ipath.empty()) {
270  usage(argv[0], NULL);
271  std::cerr << std::endl << "ERROR:" << std::endl;
272  std::cerr << " Use -i <visp image path> option or set VISP_INPUT_IMAGE_PATH " << std::endl
273  << " environment variable to specify the location of the " << std::endl
274  << " image path where test images are located." << std::endl
275  << std::endl;
276 
277  return (-1);
278  }
279 
280  // Get the option values
281  if (!opt_ipath.empty())
282  ipath = vpIoTools::createFilePath(opt_ipath, "mbt/cube/image%04d.pgm");
283  else
284  ipath = vpIoTools::createFilePath(env_ipath, "mbt/cube/image%04d.pgm");
285 
286  if (!opt_configFile.empty())
287  configFile = opt_configFile;
288  else if (!opt_ipath.empty())
289  configFile = vpIoTools::createFilePath(opt_ipath, "mbt/cube.xml");
290  else
291  configFile = vpIoTools::createFilePath(env_ipath, "mbt/cube.xml");
292 
293  if (!opt_modelFile.empty()) {
294  modelFile = opt_modelFile;
295  } else {
296  std::string modelFileCao;
297  std::string modelFileWrl;
298  if (trackCylinder) {
299  modelFileCao = "mbt/cube_and_cylinder.cao";
300  modelFileWrl = "mbt/cube_and_cylinder.wrl";
301  } else {
302  modelFileCao = "mbt/cube.cao";
303  modelFileWrl = "mbt/cube.wrl";
304  }
305 
306  if (!opt_ipath.empty()) {
307  if (cao3DModel) {
308  modelFile = vpIoTools::createFilePath(opt_ipath, modelFileCao);
309  } else {
310 #ifdef VISP_HAVE_COIN3D
311  modelFile = vpIoTools::createFilePath(opt_ipath, modelFileWrl);
312 #else
313  std::cerr << "Coin is not detected in ViSP. Use the .cao model instead." << std::endl;
314  modelFile = vpIoTools::createFilePath(opt_ipath, modelFileCao);
315 #endif
316  }
317  } else {
318  if (cao3DModel) {
319  modelFile = vpIoTools::createFilePath(env_ipath, modelFileCao);
320  } else {
321 #ifdef VISP_HAVE_COIN3D
322  modelFile = vpIoTools::createFilePath(env_ipath, modelFileWrl);
323 #else
324  std::cerr << "Coin is not detected in ViSP. Use the .cao model instead." << std::endl;
325  modelFile = vpIoTools::createFilePath(env_ipath, modelFileCao);
326 #endif
327  }
328  }
329  }
330 
331  if (!opt_initFile.empty())
332  initFile = opt_initFile;
333  else if (!opt_ipath.empty())
334  initFile = vpIoTools::createFilePath(opt_ipath, "mbt/cube");
335  else
336  initFile = vpIoTools::createFilePath(env_ipath, "mbt/cube");
337 
339  vpVideoReader reader;
340 
341  reader.setFileName(ipath);
342  try {
343  reader.open(I);
344  } catch (...) {
345  std::cout << "Cannot open sequence: " << ipath << std::endl;
346  return -1;
347  }
348 
349  if (opt_lastFrame > 1 && opt_lastFrame < reader.getLastFrameIndex())
350  reader.setLastFrameIndex(opt_lastFrame);
351 
352  reader.acquire(I);
353 
354 // initialise a display
355 #if defined VISP_HAVE_X11
356  vpDisplayX display;
357 #elif defined VISP_HAVE_GDI
358  vpDisplayGDI display;
359 #elif defined VISP_HAVE_OPENCV
360  vpDisplayOpenCV display;
361 #elif defined VISP_HAVE_D3D9
362  vpDisplayD3D display;
363 #elif defined VISP_HAVE_GTK
364  vpDisplayGTK display;
365 #else
366  opt_display = false;
367 #endif
368  if (opt_display) {
369 #if defined(VISP_HAVE_DISPLAY)
370  display.init(I, 100, 100, "Test tracking");
371 #endif
373  vpDisplay::flush(I);
374  }
375 
376  vpMbEdgeTracker tracker;
378 
379  // Initialise the tracker: camera parameters, moving edge and KLT settings
380  vpCameraParameters cam;
381 #if defined(VISP_HAVE_PUGIXML)
382  // From the xml file
383  tracker.loadConfigFile(configFile);
384 #else
385  // By setting the parameters:
386  cam.initPersProjWithoutDistortion(547, 542, 338, 234);
387 
388  vpMe me;
389  me.setMaskSize(5);
390  me.setMaskNumber(180);
391  me.setRange(7);
392  me.setThreshold(5000);
393  me.setMu1(0.5);
394  me.setMu2(0.5);
395  me.setSampleStep(4);
396 
397  tracker.setCameraParameters(cam);
398  tracker.setMovingEdge(me);
399 
400  // Specify the clipping to use
401  tracker.setNearClippingDistance(0.01);
402  tracker.setFarClippingDistance(0.90);
404 // tracker.setClipping(tracker.getClipping() | vpMbtPolygon::LEFT_CLIPPING |
405 // vpMbtPolygon::RIGHT_CLIPPING | vpMbtPolygon::UP_CLIPPING |
406 // vpMbtPolygon::DOWN_CLIPPING); // Equivalent to FOV_CLIPPING
407 #endif
408 
409  // Display the moving edges, see documentation for the signification of
410  // the colours
411  tracker.setDisplayFeatures(displayFeatures);
412 
413  // Tells if the tracker has to use Ogre3D for visibility tests
414  tracker.setOgreVisibilityTest(useOgre);
415  if (useOgre)
416  tracker.setOgreShowConfigDialog(showOgreConfigDialog);
417 
418  // Tells if the tracker has to use the scanline visibility tests
419  tracker.setScanLineVisibilityTest(useScanline);
420 
421  // Tells if the tracker has to compute the covariance matrix
422  tracker.setCovarianceComputation(computeCovariance);
423 
424  // Tells if the tracker has to compute the projection error
425  tracker.setProjectionErrorComputation(projectionError);
426 
427  // Retrieve the camera parameters from the tracker
428  tracker.getCameraParameters(cam);
429 
430  // Loop to position the cube
431  if (opt_display && opt_click_allowed) {
432  while (!vpDisplay::getClick(I, false)) {
434  vpDisplay::displayText(I, 15, 10, "click after positioning the object", vpColor::red);
435  vpDisplay::flush(I);
436  }
437  }
438 
439  // Load the 3D model (either a vrml file or a .cao file)
440  tracker.loadModel(modelFile);
441 
442  // Initialise the tracker by clicking on the image
443  // This function looks for
444  // - a ./cube/cube.init file that defines the 3d coordinates (in meter,
445  // in the object basis) of the points used for the initialisation
446  // - a ./cube/cube.ppm file to display where the user have to click
447  // (optionnal, set by the third parameter)
448  if (opt_display && opt_click_allowed) {
449  tracker.initClick(I, initFile, true);
450  tracker.getPose(cMo);
451  // display the 3D model at the given pose
452  tracker.display(I, cMo, cam, vpColor::red);
453  } else {
454  vpHomogeneousMatrix cMoi(0.02044769891, 0.1101505452, 0.5078963719, 2.063603907, 1.110231561, -0.4392789872);
455  tracker.initFromPose(I, cMoi);
456  }
457 
458  // track the model
459  tracker.track(I);
460  tracker.getPose(cMo);
461 
462  if (opt_display)
463  vpDisplay::flush(I);
464 
465  while (!reader.end()) {
466  // acquire a new image
467  reader.acquire(I);
468  // display the image
469  if (opt_display)
471 
472  // Test to reset the tracker
473  if (reader.getFrameIndex() == reader.getFirstFrameIndex() + 10) {
474  vpTRACE("Test reset tracker");
475  if (opt_display)
477  tracker.resetTracker();
478 #if defined(VISP_HAVE_PUGIXML)
479  tracker.loadConfigFile(configFile);
480 #else
481  // By setting the parameters:
482  cam.initPersProjWithoutDistortion(547, 542, 338, 234);
483 
484  vpMe me;
485  me.setMaskSize(5);
486  me.setMaskNumber(180);
487  me.setRange(7);
488  me.setThreshold(5000);
489  me.setMu1(0.5);
490  me.setMu2(0.5);
491  me.setSampleStep(4);
492 
493  tracker.setCameraParameters(cam);
494  tracker.setMovingEdge(me);
495 
496  // Specify the clipping to use
497  tracker.setNearClippingDistance(0.01);
498  tracker.setFarClippingDistance(0.90);
500 // tracker.setClipping(tracker.getClipping() | vpMbtPolygon::LEFT_CLIPPING |
501 // vpMbtPolygon::RIGHT_CLIPPING | vpMbtPolygon::UP_CLIPPING |
502 // vpMbtPolygon::DOWN_CLIPPING); // Equivalent to FOV_CLIPPING
503 #endif
504  tracker.loadModel(modelFile);
505  tracker.setCameraParameters(cam);
506  tracker.setOgreVisibilityTest(useOgre);
507  tracker.setScanLineVisibilityTest(useScanline);
508  tracker.setCovarianceComputation(computeCovariance);
509  tracker.setProjectionErrorComputation(projectionError);
510  tracker.initFromPose(I, cMo);
511  }
512 
513  // Test to set an initial pose
514  if (reader.getFrameIndex() == reader.getFirstFrameIndex() + 50) {
515  cMo.buildFrom(0.0439540832, 0.0845870108, 0.5477322481, 2.179498458, 0.8611798108, -0.3491961946);
516  vpTRACE("Test set pose");
517  tracker.setPose(I, cMo);
518  // if (opt_display) {
519  // // display the 3D model
520  // tracker.display(I, cMo, cam, vpColor::darkRed);
521  // // display the frame
522  // vpDisplay::displayFrame (I, cMo, cam, 0.05);
527  // }
528  }
529 
530  // track the object: stop tracking from frame 40 to 50
531  if (reader.getFrameIndex() - reader.getFirstFrameIndex() < 40 ||
532  reader.getFrameIndex() - reader.getFirstFrameIndex() >= 50) {
533  tracker.track(I);
534  tracker.getPose(cMo);
535  if (opt_display) {
536  // display the 3D model
537  tracker.display(I, cMo, cam, vpColor::darkRed);
538  // display the frame
539  vpDisplay::displayFrame(I, cMo, cam, 0.05);
540  }
541  }
542 
543  if (opt_click_allowed) {
544  vpDisplay::displayText(I, 10, 10, "Click to quit", vpColor::red);
545  if (vpDisplay::getClick(I, false)) {
546  quit = true;
547  break;
548  }
549  }
550 
551  if (computeCovariance) {
552  std::cout << "Covariance matrix: \n" << tracker.getCovarianceMatrix() << std::endl << std::endl;
553  }
554 
555  if (projectionError) {
556  std::cout << "Projection error: " << tracker.getProjectionError() << std::endl << std::endl;
557  }
558 
559  if (opt_display)
560  vpDisplay::flush(I);
561  }
562 
563  std::cout << "Reached last frame: " << reader.getFrameIndex() << std::endl;
564 
565  if (opt_click_allowed && !quit) {
567  }
568  reader.close();
569 
570 #if defined(VISP_HAVE_COIN3D) && (COIN_MAJOR_VERSION >= 2)
571  // Cleanup memory allocated by Coin library used to load a vrml model in
572  // vpMbEdgeTracker::loadModel() We clean only if Coin was used.
573  if (!cao3DModel)
574  SoDB::finish();
575 #endif
576 
577  return EXIT_SUCCESS;
578  } catch (const vpException &e) {
579  std::cout << "Catch an exception: " << e << std::endl;
580  return EXIT_FAILURE;
581  }
582 }
583 
584 #else
585 
586 int main()
587 {
588  std::cout << "visp_mbt module is required to run this example." << std::endl;
589  return EXIT_SUCCESS;
590 }
591 
592 #endif
virtual unsigned int getClipping() const
Definition: vpMbTracker.h:252
virtual void setCovarianceComputation(const bool &flag)
Definition: vpMbTracker.h:495
void setMovingEdge(const vpMe &me)
static bool getClick(const vpImage< unsigned char > &I, bool blocking=true)
static std::string getViSPImagesDataPath()
Definition: vpIoTools.cpp:1292
virtual void loadModel(const std::string &modelFile, bool verbose=false, const vpHomogeneousMatrix &T=vpHomogeneousMatrix())
Implementation of an homogeneous matrix and operations on such kind of matrices.
virtual void track(const vpImage< unsigned char > &I)
void setMaskNumber(const unsigned int &a)
Definition: vpMe.cpp:454
static const vpColor darkRed
Definition: vpColor.h:180
Display for windows using GDI (available on any windows 32 platform).
Definition: vpDisplayGDI.h:128
void setSampleStep(const double &s)
Definition: vpMe.h:278
static void displayText(const vpImage< unsigned char > &I, const vpImagePoint &ip, const std::string &s, const vpColor &color)
virtual void initClick(const vpImage< unsigned char > &I, const std::string &initFile, bool displayHelp=false, const vpHomogeneousMatrix &T=vpHomogeneousMatrix())
Use the X11 console to display images on unix-like OS. Thus to enable this class X11 should be instal...
Definition: vpDisplayX.h:150
Class that enables to manipulate easily a video file or a sequence of images. As it inherits from the...
virtual void setOgreShowConfigDialog(bool showConfigDialog)
Definition: vpMbTracker.h:639
virtual double getProjectionError() const
Definition: vpMbTracker.h:306
error that can be emited by ViSP classes.
Definition: vpException.h:71
Definition: vpMe.h:60
Make the complete tracking of an object by using its CAD model.
virtual void setPose(const vpImage< unsigned char > &I, const vpHomogeneousMatrix &cdMo)
virtual void initFromPose(const vpImage< unsigned char > &I, const std::string &initFile)
void loadConfigFile(const std::string &configFile)
static void flush(const vpImage< unsigned char > &I)
long getFirstFrameIndex()
void setMu1(const double &mu_1)
Definition: vpMe.h:241
static bool parse(int *argcPtr, const char **argv, vpArgvInfo *argTable, int flags)
Definition: vpParseArgv.cpp:69
static const vpColor red
Definition: vpColor.h:179
virtual void setNearClippingDistance(const double &dist)
virtual void setOgreVisibilityTest(const bool &v)
void open(vpImage< vpRGBa > &I)
long getLastFrameIndex()
Display for windows using Direct3D 3rd party. Thus to enable this class Direct3D should be installed...
Definition: vpDisplayD3D.h:106
virtual void getPose(vpHomogeneousMatrix &cMo) const
Definition: vpMbTracker.h:410
static std::string createFilePath(const std::string &parent, const std::string &child)
Definition: vpIoTools.cpp:1537
virtual void setScanLineVisibilityTest(const bool &v)
void setMaskSize(const unsigned int &a)
Definition: vpMe.cpp:461
#define vpTRACE
Definition: vpDebug.h:416
static void display(const vpImage< unsigned char > &I)
The vpDisplayOpenCV allows to display image using the OpenCV library. Thus to enable this class OpenC...
Generic class defining intrinsic camera parameters.
The vpDisplayGTK allows to display image using the GTK 3rd party library. Thus to enable this class G...
Definition: vpDisplayGTK.h:137
void acquire(vpImage< vpRGBa > &I)
virtual void setFarClippingDistance(const double &dist)
void buildFrom(const vpTranslationVector &t, const vpRotationMatrix &R)
void initPersProjWithoutDistortion(double px, double py, double u0, double v0)
void init(vpImage< unsigned char > &I, int winx=-1, int winy=-1, const std::string &title="")
void setMu2(const double &mu_2)
Definition: vpMe.h:248
long getFrameIndex() const
void setLastFrameIndex(const long last_frame)
static void displayFrame(const vpImage< unsigned char > &I, const vpHomogeneousMatrix &cMo, const vpCameraParameters &cam, double size, const vpColor &color=vpColor::none, unsigned int thickness=1, const vpImagePoint &offset=vpImagePoint(0, 0))
virtual vpMatrix getCovarianceMatrix() const
Definition: vpMbTracker.h:261
virtual void display(const vpImage< unsigned char > &I, const vpHomogeneousMatrix &cMo, const vpCameraParameters &cam, const vpColor &col, unsigned int thickness=1, bool displayFullModel=false)
void setThreshold(const double &t)
Definition: vpMe.h:300
void setFileName(const std::string &filename)
virtual void setCameraParameters(const vpCameraParameters &cam)
void setRange(const unsigned int &r)
Definition: vpMe.h:271
virtual void setClipping(const unsigned int &flags)
virtual void setDisplayFeatures(bool displayF)
Definition: vpMbTracker.h:513
virtual void getCameraParameters(vpCameraParameters &cam) const
Definition: vpMbTracker.h:244
virtual void setProjectionErrorComputation(const bool &flag)
Definition: vpMbTracker.h:580