Visual Servoing Platform
version 3.7.0
Loading...
Searching...
No Matches
vpView.h
1
/*
2
* ViSP, open source Visual Servoing Platform software.
3
* Copyright (C) 2005 - 2025 by Inria. All rights reserved.
4
*
5
* This software is free software; you can redistribute it and/or modify
6
* it under the terms of the GNU General Public License as published by
7
* the Free Software Foundation; either version 2 of the License, or
8
* (at your option) any later version.
9
* See the file LICENSE.txt at the root directory of this source
10
* distribution for additional information about the GNU GPL.
11
*
12
* For using ViSP with software that can not be combined with the GNU
13
* GPL, please contact Inria about acquiring a ViSP Professional
14
* Edition License.
15
*
16
* See https://visp.inria.fr for more information.
17
*
18
* This software was developed at:
19
* Inria Rennes - Bretagne Atlantique
20
* Campus Universitaire de Beaulieu
21
* 35042 Rennes Cedex
22
* France
23
*
24
* If you have questions regarding the use of this file, please contact
25
* Inria at visp@inria.fr
26
*
27
* This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE
28
* WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
29
*
30
* Description:
31
* Le module "view.h" contient les Macros et les types
32
* des parametres de visualisation et de transformation 3D.
33
*
34
* Authors:
35
* Jean-Luc CORRE
36
*/
37
38
#ifndef vpView_H
39
#define vpView_H
40
41
#include <visp3/core/vpConfig.h>
42
43
#ifndef DOXYGEN_SHOULD_SKIP_THIS
44
45
#include "vpArit.h"
46
#include "vpMy.h"
47
48
/*
49
* Macros de numerotation des 6 plans de decoupage :
50
* - Les 6 plans de clipping definissent le volume canonique
51
* de la pyramide de vision dans lequel la scene est visible.
52
* - les 6 plans ont pour equations :
53
* Plan dessus : W = Y
54
* Plan dessous : -W = Y
55
* Plan droit : W = X
56
* Plan gauche : -W = X
57
* Plan arriere : W = Z
58
* Plan avant : W = 0
59
*/
60
#define PLANE_ABOVE 0
61
#define PLANE_BELOW 1
62
#define PLANE_RIGHT 2
63
#define PLANE_LEFT 3
64
#define PLANE_BACK 4
65
#define PLANE_FRONT 5
66
#define PLANE_NBR 6
67
68
/*
69
* Macros de positionnement des points 4D :
70
* Le positionnement d'un point 4D dans l'espace de l'observateur virtuel
71
* se fait par rapport aux 6 plans de decoupage.
72
* A chaque point 4D on associe 6 bits, un par plan de decoupage.
73
*/
74
#define IS_INSIDE 0x00
75
#define IS_ABOVE 0x01
76
#define IS_BELOW 0x02
77
#define IS_RIGHT 0x04
78
#define IS_LEFT 0x08
79
#define IS_BACK 0x10
80
#define IS_FRONT 0x20
81
82
#define vpDEFAULT_REMOVE IS_INSIDE
83
84
#define PARALLEL 0
85
#define PERSPECTIVE 1
86
87
#define vpDEFAULT_EYE \
88
{ \
89
0.0, 0.0, 1.0 \
90
}
91
#define vpDEFAULT_TARGET \
92
{ \
93
0.0, 0.0, 0.0 \
94
}
95
#define vpDEFAULT_FOCAL 1.0
96
#define vpDEFAULT_ANGLE 45.0
97
#define vpDEFAULT_TWIST 0.0
98
#define vpDEFAULT_SPEED 0.0
99
#define vpDEFAULT_CAMERA \
100
{ \
101
vpDEFAULT_EYE, vpDEFAULT_TARGET, vpDEFAULT_FOCAL, vpDEFAULT_ANGLE, vpDEFAULT_TWIST, vpDEFAULT_SPEED \
102
}
103
104
#define vpDEFAULT_COP \
105
{ \
106
0.0, 0.0, 1.0 \
107
}
108
#define vpDEFAULT_VRP \
109
{ \
110
0.0, 0.0, 0.0 \
111
}
112
#define vpDEFAULT_VPN \
113
{ \
114
0.0, 0.0, -1.0 \
115
}
116
#define vpDEFAULT_VUP \
117
{ \
118
0.0, 1.0, 0.0 \
119
}
120
#define vpDEFAULT_VWD \
121
{ \
122
-1.0, 1.0, -1.0, 1.0 \
123
}
124
#define vpDEFAULT_DEPTH \
125
{ \
126
0.0, 1.0 \
127
}
128
#define vpDEFAULT_TYPE PERSPECTIVE
129
130
#define vpDEFAULT_VIEW \
131
{ \
132
vpDEFAULT_TYPE, vpDEFAULT_COP, vpDEFAULT_VRP, vpDEFAULT_VPN, vpDEFAULT_VUP, vpDEFAULT_VWD, vpDEFAULT_DEPTH \
133
}
134
135
#define vpDEFAULT_WC \
136
{ \
137
1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0 \
138
}
139
140
BEGIN_VISP_NAMESPACE
141
/*
142
* CAMERA PARAMETERS
143
* _________________
144
*
145
* La structure "Camera_parameters" definit les parametres de la camera.
146
* eye Position de l'oeil ou de la camera.
147
* target Position de la cible ou du point visee dans la scene.
148
* focal Distance eye-target
149
* angle Angle d'ouverture en degres.
150
* twist Angle de rotation sur l'axe de visee (eye,target) en degres.
151
* speed Vitesse sur l'axe de visee (eye,target).
152
*/
153
typedef
struct
154
{
155
Point3f eye;
/* position de l'observateur */
156
Point3f target;
/* point vise */
157
float
focal;
/* focale de la camera */
158
float
angle;
/* angle d'ouverture */
159
float
twist;
/* rotation sur l'axe de visee */
160
float
speed;
/* vitesse sur l'axe de visee */
161
} Camera_parameters;
162
163
typedef
struct
164
{
165
float
umin, umax;
/* bords gauche et droit */
166
float
vmin, vmax;
/* bords inferieur et superieur */
167
} View_window;
168
169
typedef
struct
170
{
171
float
front;
/* plan avant ("hither") */
172
float
back;
/* plan arriere ("yon") */
173
} View_depth;
174
175
typedef
struct
176
{
177
Type
type
;
/* type de la projection */
178
Point3f cop;
/* centre de projection */
179
Point3f vrp;
/* point de reference de visee */
180
Vector vpn;
/* vecteur nomal au plan */
181
Vector vup;
/* vecteur indiquant le "haut" */
182
View_window vwd;
/* fenetre de projection */
183
View_depth
depth
;
/* profondeurs de decoupages */
184
} View_parameters;
185
END_VISP_NAMESPACE
186
#endif
187
#endif
BEGIN_VISP_NAMESPACE
Definition
vpMbtDistanceCircle.cpp:55
ibvs-four-points.type
type
Definition
ibvs-four-points.py:151
realsense-rbt.depth
depth
Definition
realsense-rbt.py:215
modules
robot
src
wireframe-simulator
vpView.h
Generated by
1.15.0