#include <camera.h>
Public Types | |
| enum | { PERSPECTIVE = 0, ORTHO = 1, ISOMETRIC = 2, CAVALIERI = 3 } |
| typedef S | ScalarType |
Public Member Functions | |
| Camera () | |
| vcg::Point2< S > | DistortedToUndistorted (vcg::Point2< S > d) const |
| transforms a distorted 2D camera plane point in an undistorted 2D camera plane point | |
| void | GetFrustum (S &sx, S &dx, S &bt, S &tp, S &nr) |
| returns the frustum | |
| vcg::Matrix44< S > | GetMatrix (S nearVal, S farVal) |
| returns the projection matrix | |
| bool | IsOrtho () const |
| vcg::Point2< S > | LocalTo_0_1 (const vcg::Point2< S > &p) const |
| transforms local plane coords to [0 1] coords | |
| vcg::Point2< S > | LocalTo_neg1_1 (const vcg::Point2< S > &p) const |
| transforms local plane coords to [-1 1] coords | |
| vcg::Point2< S > | LocalToViewportPx (const vcg::Point2< S > &p) const |
| transforms local plane coords to vieport (pixel) coords | |
| vcg::Point2< S > | Neg1_1ToViewportPx (const vcg::Point2< S > &p) const |
| transforms [-1 1] coords to vieport (pixel) coords MICHELE IO | |
| vcg::Point2< S > | Project (const vcg::Point3< S > &p) const |
| project a point from 3d CAMERA space to the camera local plane | |
| void | SetCavalieri (S sx, S dx, S bt, S tp, S Focal, vcg::Point2< int > Viewport) |
| set the camera specifying the cavalieri view | |
| void | SetFrustum (S dx, S sx, S bt, S tp, S Focal, vcg::Point2< int > Viewport) |
| set the camera specifying the frustum view | |
| void | SetIsometric (S sx, S dx, S bt, S tp, S Focal, vcg::Point2< int > Viewport) |
| set the camera specifying the isometric view | |
| void | SetOrtho (S l, S r, S b, S t, vcg::Point2< int > viewport) |
| void | SetPerspective (S AngleDeg, S AspectRatio, S Focal, vcg::Point2< int > Viewport) |
| set the camera specifying the perspecive view | |
| vcg::Point2< S > | UndistortedToDistorted (vcg::Point2< S > u) const |
| transforms an undistorted 2D camera plane point in a distorted 2D camera plane point | |
| vcg::Point3< S > | UnProject (const vcg::Point2< S > &p, const S &d) const |
| unproject a point from the camera local plane (plus depth) to 3d CAMERA space | |
| vcg::Point2< S > | ViewportPxTo_neg1_1 (const vcg::Point2< S > &p) const |
| transforms vieport (pixel) coords to [-1 1] coords | |
| vcg::Point2< S > | ViewportPxToLocal (const vcg::Point2< S > &p) const |
| transforms vieport (pixel) coords to local plane coords | |
Static Public Member Functions | |
| template<class Q > | |
| static Camera | Construct (const Camera< Q > &t) |
| Type of camera: PERSPECTIVE,ORTHO,ISOMETRIC,CAVALIERI. | |
Public Attributes | |
| int | cameraType |
| 1st & 2nd order radial lens distortion coefficient (only the first 2 terms are used) | |
| Point2< S > | CenterPx |
| Dimension in mm of a single pixel. | |
| Point2< S > | DistorCenterPx |
| Position of the projection of the focal center on the image plane. Expressed in pixels. | |
| ScalarType | FocalMm |
| S | k [4] |
| Position of the radial distortion center on the image plane in pixels. | |
| Point2< S > | PixelSizeMm |
| Dimension of the Image Plane (in pixels) | |
| Point2< int > | ViewportPx |
| Focal Distance: the distance between focal center and image plane. Expressed in mm. | |
Definition at line 141 of file vcg/math/camera.h.
| typedef S vcg::Camera< S >::ScalarType |
Definition at line 144 of file vcg/math/camera.h.
| anonymous enum |
Definition at line 145 of file vcg/math/camera.h.
| vcg::Camera< S >::Camera | ( | ) | [inline] |
Definition at line 152 of file vcg/math/camera.h.
| static Camera vcg::Camera< S >::Construct | ( | const Camera< Q > & | t | ) | [inline, static] |
Type of camera: PERSPECTIVE,ORTHO,ISOMETRIC,CAVALIERI.
Definition at line 178 of file vcg/math/camera.h.
| vcg::Point2< S > vcg::Camera< S >::DistortedToUndistorted | ( | vcg::Point2< S > | d | ) | const |
transforms a distorted 2D camera plane point in an undistorted 2D camera plane point
Definition at line 481 of file vcg/math/camera.h.
| void vcg::Camera< S >::GetFrustum | ( | S & | sx, |
| S & | dx, | ||
| S & | bt, | ||
| S & | tp, | ||
| S & | nr | ||
| ) | [inline] |
returns the frustum
Definition at line 552 of file vcg/math/camera.h.
| vcg::Matrix44< S > vcg::Camera< S >::GetMatrix | ( | S | nearVal, |
| S | farVal | ||
| ) |
returns the projection matrix
Definition at line 295 of file vcg/math/camera.h.
| bool vcg::Camera< S >::IsOrtho | ( | ) | const [inline] |
Definition at line 208 of file vcg/math/camera.h.
| vcg::Point2< S > vcg::Camera< S >::LocalTo_0_1 | ( | const vcg::Point2< S > & | p | ) | const [inline] |
transforms local plane coords to [0 1] coords
transforms local plane coords to [0-1] coords
Definition at line 397 of file vcg/math/camera.h.
| vcg::Point2< S > vcg::Camera< S >::LocalTo_neg1_1 | ( | const vcg::Point2< S > & | p | ) | const [inline] |
transforms local plane coords to [-1 1] coords
Definition at line 407 of file vcg/math/camera.h.
| vcg::Point2< S > vcg::Camera< S >::LocalToViewportPx | ( | const vcg::Point2< S > & | p | ) | const [inline] |
transforms local plane coords to vieport (pixel) coords
Definition at line 355 of file vcg/math/camera.h.
| vcg::Point2< S > vcg::Camera< S >::Neg1_1ToViewportPx | ( | const vcg::Point2< S > & | p | ) | const [inline] |
transforms [-1 1] coords to vieport (pixel) coords MICHELE IO
Definition at line 387 of file vcg/math/camera.h.
| vcg::Point2< S > vcg::Camera< S >::Project | ( | const vcg::Point3< S > & | p | ) | const [inline] |
project a point from 3d CAMERA space to the camera local plane
project a point from 3d CAMERA space to the camera's plane]
Definition at line 272 of file vcg/math/camera.h.
| void vcg::Camera< S >::SetCavalieri | ( | S | sx, |
| S | dx, | ||
| S | bt, | ||
| S | tp, | ||
| S | Focal, | ||
| vcg::Point2< int > | Viewport | ||
| ) | [inline] |
set the camera specifying the cavalieri view
Definition at line 536 of file vcg/math/camera.h.
| void vcg::Camera< S >::SetFrustum | ( | S | dx, |
| S | sx, | ||
| S | bt, | ||
| S | tp, | ||
| S | Focal, | ||
| vcg::Point2< int > | Viewport | ||
| ) | [inline] |
set the camera specifying the frustum view
Definition at line 511 of file vcg/math/camera.h.
| void vcg::Camera< S >::SetIsometric | ( | S | sx, |
| S | dx, | ||
| S | bt, | ||
| S | tp, | ||
| S | Focal, | ||
| vcg::Point2< int > | Viewport | ||
| ) | [inline] |
set the camera specifying the isometric view
Definition at line 544 of file vcg/math/camera.h.
| void vcg::Camera< S >::SetOrtho | ( | S | l, |
| S | r, | ||
| S | b, | ||
| S | t, | ||
| vcg::Point2< int > | viewport | ||
| ) | [inline] |
Definition at line 194 of file vcg/math/camera.h.
| void vcg::Camera< S >::SetPerspective | ( | S | AngleDeg, |
| S | AspectRatio, | ||
| S | Focal, | ||
| vcg::Point2< int > | Viewport | ||
| ) | [inline] |
set the camera specifying the perspecive view
set the camera specifying the perspective view
Definition at line 498 of file vcg/math/camera.h.
| vcg::Point2< Scalar > vcg::Camera< Scalar >::UndistortedToDistorted | ( | vcg::Point2< Scalar > | u | ) | const |
transforms an undistorted 2D camera plane point in a distorted 2D camera plane point
Definition at line 417 of file vcg/math/camera.h.
| vcg::Point3< S > vcg::Camera< S >::UnProject | ( | const vcg::Point2< S > & | p, |
| const S & | d | ||
| ) | const [inline] |
unproject a point from the camera local plane (plus depth) to 3d CAMERA space
unproject a point from the camera 2d plane [-1,-1]x[1,1] (plus depth) to 3d CAMERA space
Definition at line 332 of file vcg/math/camera.h.
| vcg::Point2< S > vcg::Camera< S >::ViewportPxTo_neg1_1 | ( | const vcg::Point2< S > & | p | ) | const [inline] |
transforms vieport (pixel) coords to [-1 1] coords
Definition at line 377 of file vcg/math/camera.h.
| vcg::Point2< S > vcg::Camera< S >::ViewportPxToLocal | ( | const vcg::Point2< S > & | p | ) | const [inline] |
transforms vieport (pixel) coords to local plane coords
Definition at line 367 of file vcg/math/camera.h.
| int vcg::Camera< S >::cameraType |
1st & 2nd order radial lens distortion coefficient (only the first 2 terms are used)
Definition at line 173 of file vcg/math/camera.h.
| Point2<S> vcg::Camera< S >::CenterPx |
Dimension in mm of a single pixel.
Definition at line 167 of file vcg/math/camera.h.
| Point2<S> vcg::Camera< S >::DistorCenterPx |
Position of the projection of the focal center on the image plane. Expressed in pixels.
Definition at line 169 of file vcg/math/camera.h.
| ScalarType vcg::Camera< S >::FocalMm |
Definition at line 164 of file vcg/math/camera.h.
| S vcg::Camera< S >::k[4] |
Position of the radial distortion center on the image plane in pixels.
Definition at line 170 of file vcg/math/camera.h.
| Point2<S> vcg::Camera< S >::PixelSizeMm |
Dimension of the Image Plane (in pixels)
Definition at line 166 of file vcg/math/camera.h.
| Point2<int> vcg::Camera< S >::ViewportPx |
Focal Distance: the distance between focal center and image plane. Expressed in mm.
Definition at line 165 of file vcg/math/camera.h.