2 #include <visp/vpFeatureBuilder.h>
3 #include <visp/vpServo.h>
4 #include <visp/vpSimulatorCamera.h>
5 #include <visp/vpPlot.h>
24 for (
int i = 0 ; i < 4 ; i++) {
38 #ifdef VISP_HAVE_DISPLAY
39 vpPlot plotter(2, 250*2, 500, 100, 200,
"Real time curves plotter");
40 plotter.setTitle(0,
"Visual features error");
41 plotter.setTitle(1,
"Camera velocities");
43 plotter.initGraph(0, 8);
44 plotter.initGraph(1, 6);
46 plotter.setLegend(0, 0,
"x1");
47 plotter.setLegend(0, 1,
"y1");
48 plotter.setLegend(0, 2,
"x2");
49 plotter.setLegend(0, 3,
"y2");
50 plotter.setLegend(0, 4,
"x3");
51 plotter.setLegend(0, 5,
"y3");
52 plotter.setLegend(0, 6,
"x4");
53 plotter.setLegend(0, 7,
"y4");
55 plotter.setLegend(1, 0,
"v_x");
56 plotter.setLegend(1, 1,
"v_y");
57 plotter.setLegend(1, 2,
"v_z");
58 plotter.setLegend(1, 3,
"w_x");
59 plotter.setLegend(1, 4,
"w_y");
60 plotter.setLegend(1, 5,
"w_z");
63 for (
unsigned int iter=0; iter < 150; iter ++) {
66 for (
int i = 0 ; i < 4 ; i++) {
73 #ifdef VISP_HAVE_DISPLAY
74 plotter.plot(0, iter, task.
getError());
75 plotter.plot(1, iter, v);
81 #ifdef VISP_HAVE_DISPLAY
82 plotter.saveData(0,
"error.dat");
83 plotter.saveData(1,
"vc.dat");