|
| | View (void) |
| | Default constructor with common perspective defaults.
|
| |
| | View (Pose< ViewComponentType > pose, utility::graphic::FieldOfView< ViewComponentType > fov, math::Vector< ViewComponentType, 2 > viewportSize, ViewComponentType nearPlane, ViewComponentType farPlane) |
| | Construct view from explicit quaternion orientation.
|
| |
| | View (const View &other)=default |
| | Copy constructor.
|
| |
| | View (View &&other) noexcept=default |
| | Move constructor.
|
| |
| View & | operator= (const View &other)=default |
| | Copy assignment operator.
|
| |
| View & | operator= (View &&other) noexcept=default |
| | Move assignment operator.
|
| |
|
| ~View (void)=default |
| | Destructor.
|
| |
| void | setPose (const Pose< ViewComponentType > &pose) |
| | Set view world-space pose.
|
| |
| Pose< ViewComponentType > | getPose (void) const |
| | Get view world-space pose.
|
| |
| math::Vector< ViewComponentType, 3 > | getForward (void) const |
| | Get normalized forward direction.
|
| |
| math::Vector< ViewComponentType, 3 > | getUp (void) const |
| | Get normalized up direction.
|
| |
| void | setPerspective (ViewComponentType verticalFovRadians, ViewComponentType aspectRatio) |
| | Set perspective projection parameters.
|
| |
| ViewComponentType | getAspectRatio () const |
| | Get aspect ratio (width/height).
|
| |
| void | setFieldOfView (const FieldOfView< ViewComponentType > &fieldOfView) |
| | Set per-direction field-of-view values.
|
| |
| FieldOfView< ViewComponentType > | getFieldOfView (void) const |
| | Get field-of-view values.
|
| |
| math::Vector< ViewComponentType, 3 > | getRight (void) const |
| | Compute view right direction from orientation basis.
|
| |
| void | setClippingPlanes (ViewComponentType nearDistance, ViewComponentType farDistance) |
| | Set near and far clipping plane distances.
|
| |
| ViewComponentType | getNearPlane () const noexcept |
| | Get near clipping plane distance.
|
| |
| ViewComponentType | getFarPlane () const noexcept |
| | Get far clipping plane distance.
|
| |
| void | move (const math::Vector< ViewComponentType, 3 > &offset) |
| | Translate view position by an offset.
|
| |
| View | moved (const math::Vector< ViewComponentType, 3 > &offset) const |
| | Return translated view copy.
|
| |
| Ray< ViewComponentType > | viewRay (ViewComponentType ndcX, ViewComponentType ndcY) const |
| | Create a world-space ray from normalized device coordinates.
|
| |
| Ray< ViewComponentType > | viewPointToRay (const math::Vector< ViewComponentType, 2 > &point) const |
| | Create a world-space ray from viewport pixel coordinates.
|
| |
| ViewComponentType | getVerticalFovRadians () const noexcept |
| | Get total vertical field-of-view in radians.
|
| |
| ViewComponentType | getHorizontalFovRadians () const noexcept |
| | Get total horizontal field-of-view in radians.
|
| |
| bool | isFieldOfViewSymmetric (ViewComponentType epsilon=ViewComponentType { 1e-6 }) const noexcept |
| | Check whether current field-of-view is symmetric.
|
| |
| Ray< ViewComponentType > | centerRay (void) const |
| | Create a ray going through the center of the viewport.
|
| |
| bool | operator== (const View &other) const noexcept |
| | Equality comparison.
|
| |
| bool | operator!= (const View &other) const noexcept |
| | Inequality comparison.
|
| |
| void | setViewportSize (const math::Vector< ViewComponentType, 2 > &viewportSize) |
| | Set viewport size in pixels.
|
| |
| math::Vector< ViewComponentType, 2 > | getViewportSize (void) const |
| | Get viewport size in pixels.
|
| |
| utility::math::Matrix< ViewComponentType, 4, 4 > | toViewMatrix (void) const |
| | Convert view to a GLM-compatible 4x4 view matrix.
|
| |
| utility::math::Matrix< ViewComponentType, 4, 4 > | getProjectionMatrix () const |
| | Build a perspective projection matrix from per-side field of view angles.
|
| |
| void | setFlipY (bool flip) noexcept |
| | Set whether the projection matrix inverts the Y axis.
|
| |
| bool | isFlipY (void) const noexcept |
| | Get whether the projection matrix inverts the Y axis.
|
| |
template<CanBeViewComponent ViewComponentType>
class utility::graphic::View< ViewComponentType >
3D perspective view with floating-point components.
- Template Parameters
-
| ViewComponentType | Floating-point type for view parameters and vectors. |
Definition at line 54 of file view.hpp.