34#include <visp3/core/vpFeatureDisplay.h>
35#include <visp3/core/vpSphere.h>
43 const unsigned int val_4 = 4;
44 const unsigned int val_5 = 5;
73 const unsigned int index_0 = 0;
74 const unsigned int index_1 = 1;
75 const unsigned int index_2 = 2;
76 const unsigned int index_3 = 3;
142 const unsigned int val_5 = 5;
146 const unsigned int index_0 = 0;
147 const unsigned int index_1 = 1;
148 const unsigned int index_2 = 2;
149 const unsigned int index_3 = 3;
150 const unsigned int index_4 = 4;
160 s = (r * r) - (y0 * y0) - (z0 * z0);
162 if ((s = ((z0 * z0) - (r * r))) < 0.0) {
166 p_[0] = (x0 * z0) / s;
167 p_[1] = (y0 * z0) / s;
169 if (fabs(x0) > 1e-6) {
171 double b = r / sqrt(s);
172 double a = ((x0 * x0) + (y0 * y0) + (z0 * z0)) - (r * r);
176 a = (r * sqrt(a)) / s;
177 if (fabs(e) <= 1.0) {
191 B = (r * sqrt(((y0 * y0) + (z0 * z0)) - (r * r))) / s;
222 const unsigned int val_4 = 4;
225 const unsigned int index_0 = 0;
226 const unsigned int index_1 = 1;
227 const unsigned int index_2 = 2;
228 const unsigned int index_3 = 3;
232 x0 = (cMo[index_0][0] *
oP[0]) + (cMo[index_0][1] *
oP[1]) + (cMo[index_0][index_2] *
oP[index_2]) + cMo[index_0][index_3];
233 y0 = (cMo[index_1][0] *
oP[0]) + (cMo[index_1][1] *
oP[1]) + (cMo[index_1][index_2] *
oP[index_2]) + cMo[index_1][index_3];
234 z0 = (cMo[index_2][0] *
oP[0]) + (cMo[index_2][1] *
oP[1]) + (cMo[index_2][index_2] *
oP[index_2]) + cMo[index_2][index_3];
236 cP_[index_3] =
oP[index_3];
262 const vpColor &color,
unsigned int thickness)
267 const unsigned int index_0 = 0;
268 const unsigned int index_1 = 1;
269 const unsigned int index_2 = 2;
270 const unsigned int index_3 = 3;
271 const unsigned int index_4 = 4;
287 const vpColor &color,
unsigned int thickness)
292 const unsigned int index_0 = 0;
293 const unsigned int index_1 = 1;
294 const unsigned int index_2 = 2;
295 const unsigned int index_3 = 3;
296 const unsigned int index_4 = 4;
309 unsigned int thickness)
311 const unsigned int index_0 = 0;
312 const unsigned int index_1 = 1;
313 const unsigned int index_2 = 2;
314 const unsigned int index_3 = 3;
315 const unsigned int index_4 = 4;
328 unsigned int thickness)
330 const unsigned int index_0 = 0;
331 const unsigned int index_1 = 1;
332 const unsigned int index_2 = 2;
333 const unsigned int index_3 = 3;
334 const unsigned int index_4 = 4;
Generic class defining intrinsic camera parameters.
Implementation of column vector and the associated operations.
void resize(unsigned int i, bool flagNullify=true)
Class to define RGB colors available for display functionalities.
error that can be emitted by ViSP classes.
static void displayEllipse(double x, double y, double n20, double n11, double n02, const vpCameraParameters &cam, const vpImage< unsigned char > &I, const vpColor &color=vpColor::green, unsigned int thickness=1)
Implementation of an homogeneous matrix and operations on such kind of matrices.
Definition of the vpImage class member functions.
static double sqr(double x)
void display(const vpImage< unsigned char > &I, const vpCameraParameters &cam, const vpColor &color=vpColor::green, unsigned int thickness=1) VP_OVERRIDE
void setWorldCoordinates(const vpColVector &oP) VP_OVERRIDE
void projection() VP_OVERRIDE
void changeFrame(const vpHomogeneousMatrix &cMo, vpColVector &cP) const VP_OVERRIDE
vpSphere * duplicate() const VP_OVERRIDE
For memory issue (used by the vpServo class only).