#include <Camera.h>
Inherits cinder::CameraPersp.
Public Member Functions | |
| CameraStereo () | |
| CameraStereo (int pixelWidth, int pixelHeight, float fov) | |
| CameraStereo (int pixelWidth, int pixelHeight, float fov, float nearPlane, float farPlane) | |
| float | getConvergence () const |
| Returns the current convergence, which is the distance at which there is no parallax. | |
| void | setConvergence (float distance, bool adjustEyeSeparation=false) |
| Sets the convergence of the camera, which is the distance at which there is no parallax. | |
| float | getEyeSeparation () const |
| Returns the distance between the camera's for the left and right eyes. | |
| void | setEyeSeparation (float distance) |
| Sets the distance between the camera's for the left and right eyes. This affects the parallax effect. | |
| Vec3f | getEyePointShifted () const |
| Returns the location of the currently enabled eye camera. | |
| void | enableStereoLeft () |
| Enables the left eye camera. | |
| bool | isStereoLeftEnabled () const |
| void | enableStereoRight () |
| Enables the right eye camera. | |
| bool | isStereoRightEnabled () const |
| void | disableStereo () |
| Disables stereoscopic rendering, converting the camera to a standard CameraPersp. | |
| bool | isStereoEnabled () const |
| virtual void | getNearClipCoordinates (Vec3f *topLeft, Vec3f *topRight, Vec3f *bottomLeft, Vec3f *bottomRight) const |
| virtual void | getFarClipCoordinates (Vec3f *topLeft, Vec3f *topRight, Vec3f *bottomLeft, Vec3f *bottomRight) const |
| virtual const Matrix44f & | getProjectionMatrix () const |
| virtual const Matrix44f & | getModelViewMatrix () const |
| virtual const Matrix44f & | getInverseModelViewMatrix () const |
| void | setPerspective (float horizFovDegrees, float aspectRatio, float nearPlane, float farPlane) |
| void | getLensShift (float *horizontal, float *vertical) const |
| Vec2f | getLensShift () const |
| void | setLensShift (float horizontal, float vertical) |
| void | setLensShift (const Vec2f &shift) |
| float | getLensShiftHorizontal () const |
| Returns the horizontal lens shift. A horizontal lens shift of 1 (-1) will shift the view right (left) by half the width of the viewport. | |
| void | setLensShiftHorizontal (float horizontal) |
| float | getLensShiftVertical () const |
| Returns the vertical lens shift. A vertical lens shift of 1 (-1) will shift the view up (down) by half the height of the viewport. | |
| void | setLensShiftVertical (float vertical) |
| virtual bool | isPersp () const |
| Returns whether the camera represents a perspective projection instead of an orthographic. | |
| CameraPersp | getFrameSphere (const class Sphere &worldSpaceSphere, int maxIterations=20) const |
| Vec3f | getEyePoint () const |
| void | setEyePoint (const Vec3f &aEyePoint) |
| float | getCenterOfInterest () const |
| void | setCenterOfInterest (float aCenterOfInterest) |
| Vec3f | getCenterOfInterestPoint () const |
| void | setCenterOfInterestPoint (const Vec3f ¢erOfInterestPoint) |
| Vec3f | getWorldUp () const |
| void | setWorldUp (const Vec3f &aWorldUp) |
| void | lookAt (const Vec3f &target) |
| void | lookAt (const Vec3f &aEyePoint, const Vec3f &target) |
| void | lookAt (const Vec3f &aEyePoint, const Vec3f &target, const Vec3f &aUp) |
| Vec3f | getViewDirection () const |
| void | setViewDirection (const Vec3f &aViewDirection) |
| Quatf | getOrientation () const |
| void | setOrientation (const Quatf &aOrientation) |
| float | getFov () const |
| void | setFov (float aFov) |
| float | getAspectRatio () const |
| void | setAspectRatio (float aAspectRatio) |
| float | getNearClip () const |
| void | setNearClip (float aNearClip) |
| float | getFarClip () const |
| void | setFarClip (float aFarClip) |
| void | getFrustum (float *left, float *top, float *right, float *bottom, float *near, float *far) const |
Returns the coordinates of the camera's frustum, suitable for passing to glFrustum. | |
| Ray | generateRay (float u, float v, float imagePlaneAspectRatio) const |
| void | getBillboardVectors (Vec3f *right, Vec3f *up) const |
| Vec2f | worldToScreen (const Vec3f &worldCoord, float screenWidth, float screenHeight) const |
| Converts a world-space coordinate worldCoord to screen coordinates as viewed by the camera, based ona s screen which is screenWidth x screenHeight pixels. | |
| Vec3f | worldToEye (const Vec3f &worldCoord) |
| Converts a world-space coordinate worldCoord to eye-space, also known as camera-space. -Z is along the view direction. | |
| float | worldToEyeDepth (const Vec3f &worldCoord) const |
| Converts a world-space coordinate worldCoord to the z axis of eye-space, also known as camera-space. -Z is along the view direction. Suitable for depth sorting. | |
| Vec3f | worldToNdc (const Vec3f &worldCoord) |
| Converts a world-space coordinate worldCoord to normalized device coordinates. | |
| float | getScreenRadius (const class Sphere &sphere, float screenWidth, float screenHeight) const |
Protected Member Functions | |
| virtual void | calcModelView () const |
| virtual void | calcInverseModelView () const |
| virtual void | calcProjection () const |
| void | calcMatrices () const |
Protected Attributes | |
| Matrix44f | mProjectionMatrixLeft |
| Matrix44f | mInverseProjectionMatrixLeft |
| Matrix44f | mProjectionMatrixRight |
| Matrix44f | mInverseProjectionMatrixRight |
| Matrix44f | mModelViewMatrixLeft |
| Matrix44f | mInverseModelViewMatrixLeft |
| Matrix44f | mModelViewMatrixRight |
| Matrix44f | mInverseModelViewMatrixRight |
| Vec2f | mLensShift |
| Vec3f | mEyePoint |
| Vec3f | mViewDirection |
| Quatf | mOrientation |
| float | mCenterOfInterest |
| Vec3f | mWorldUp |
| float | mFov |
| float | mAspectRatio |
| float | mNearClip |
| float | mFarClip |
| Vec3f | mU |
| Vec3f | mV |
| Vec3f | mW |
| Matrix44f | mProjectionMatrix |
| Matrix44f | mInverseProjectionMatrix |
| bool | mProjectionCached |
| Matrix44f | mModelViewMatrix |
| bool | mModelViewCached |
| Matrix44f | mInverseModelViewMatrix |
| bool | mInverseModelViewCached |
| float | mFrustumLeft |
| float | mFrustumRight |
| float | mFrustumTop |
| float | mFrustumBottom |
| cinder::CameraStereo::CameraStereo | ( | int | pixelWidth, |
| int | pixelHeight, | ||
| float | fov | ||
| ) |
| cinder::CameraStereo::CameraStereo | ( | int | pixelWidth, |
| int | pixelHeight, | ||
| float | fov, | ||
| float | nearPlane, | ||
| float | farPlane | ||
| ) |
| float cinder::CameraStereo::getConvergence | ( | ) | const |
Returns the current convergence, which is the distance at which there is no parallax.
| void cinder::CameraStereo::setConvergence | ( | float | distance, |
| bool | adjustEyeSeparation = false |
||
| ) |
Sets the convergence of the camera, which is the distance at which there is no parallax.
| float cinder::CameraStereo::getEyeSeparation | ( | ) | const |
Returns the distance between the camera's for the left and right eyes.
| void cinder::CameraStereo::setEyeSeparation | ( | float | distance | ) |
Sets the distance between the camera's for the left and right eyes. This affects the parallax effect.
Returns the location of the currently enabled eye camera.
Enables the left eye camera.
| bool cinder::CameraStereo::isStereoLeftEnabled | ( | ) | const |
Enables the right eye camera.
| bool cinder::CameraStereo::isStereoRightEnabled | ( | ) | const |
| void cinder::CameraStereo::disableStereo | ( | ) |
Disables stereoscopic rendering, converting the camera to a standard CameraPersp.
| bool cinder::CameraStereo::isStereoEnabled | ( | ) | const |
| void cinder::CameraStereo::getNearClipCoordinates | ( | Vec3f * | topLeft, |
| Vec3f * | topRight, | ||
| Vec3f * | bottomLeft, | ||
| Vec3f * | bottomRight | ||
| ) | const [virtual] |
Reimplemented from cinder::Camera.
| void cinder::CameraStereo::getFarClipCoordinates | ( | Vec3f * | topLeft, |
| Vec3f * | topRight, | ||
| Vec3f * | bottomLeft, | ||
| Vec3f * | bottomRight | ||
| ) | const [virtual] |
Reimplemented from cinder::Camera.
| const Matrix44f & cinder::CameraStereo::getProjectionMatrix | ( | ) | const [virtual] |
Reimplemented from cinder::Camera.
| const Matrix44f & cinder::CameraStereo::getModelViewMatrix | ( | ) | const [virtual] |
Reimplemented from cinder::Camera.
| const Matrix44f & cinder::CameraStereo::getInverseModelViewMatrix | ( | ) | const [virtual] |
Reimplemented from cinder::Camera.
| void cinder::CameraStereo::calcModelView | ( | ) | const [protected, virtual] |
Reimplemented from cinder::Camera.
| void cinder::CameraStereo::calcInverseModelView | ( | ) | const [protected, virtual] |
Reimplemented from cinder::Camera.
| void cinder::CameraStereo::calcProjection | ( | ) | const [protected, virtual] |
Reimplemented from cinder::CameraPersp.
| void cinder::CameraPersp::setPerspective | ( | float | horizFovDegrees, |
| float | aspectRatio, | ||
| float | nearPlane, | ||
| float | farPlane | ||
| ) | [inherited] |
| void cinder::CameraPersp::getLensShift | ( | float * | horizontal, |
| float * | vertical | ||
| ) | const [inherited] |
Returns both the horizontal and vertical lens shift. A horizontal lens shift of 1 (-1) will shift the view right (left) by half the width of the viewport. A vertical lens shift of 1 (-1) will shift the view up (down) by half the height of the viewport.
| Vec2f cinder::CameraPersp::getLensShift | ( | ) | const [inherited] |
Returns both the horizontal and vertical lens shift. A horizontal lens shift of 1 (-1) will shift the view right (left) by half the width of the viewport. A vertical lens shift of 1 (-1) will shift the view up (down) by half the height of the viewport.
| void cinder::CameraPersp::setLensShift | ( | float | horizontal, |
| float | vertical | ||
| ) | [inherited] |
Sets both the horizontal and vertical lens shift. A horizontal lens shift of 1 (-1) will shift the view right (left) by half the width of the viewport. A vertical lens shift of 1 (-1) will shift the view up (down) by half the height of the viewport.
| void cinder::CameraPersp::setLensShift | ( | const Vec2f & | shift | ) | [inherited] |
Sets both the horizontal and vertical lens shift. A horizontal lens shift of 1 (-1) will shift the view right (left) by half the width of the viewport. A vertical lens shift of 1 (-1) will shift the view up (down) by half the height of the viewport.
| float cinder::CameraPersp::getLensShiftHorizontal | ( | ) | const [inherited] |
Returns the horizontal lens shift. A horizontal lens shift of 1 (-1) will shift the view right (left) by half the width of the viewport.
| void cinder::CameraPersp::setLensShiftHorizontal | ( | float | horizontal | ) | [inherited] |
Sets the horizontal lens shift. A horizontal lens shift of 1 (-1) will shift the view right (left) by half the width of the viewport.
| float cinder::CameraPersp::getLensShiftVertical | ( | ) | const [inherited] |
Returns the vertical lens shift. A vertical lens shift of 1 (-1) will shift the view up (down) by half the height of the viewport.
| void cinder::CameraPersp::setLensShiftVertical | ( | float | vertical | ) | [inherited] |
Sets the vertical lens shift. A vertical lens shift of 1 (-1) will shift the view up (down) by half the height of the viewport.
| virtual bool cinder::CameraPersp::isPersp | ( | ) | const [virtual, inherited] |
Returns whether the camera represents a perspective projection instead of an orthographic.
Implements cinder::Camera.
| CameraPersp cinder::CameraPersp::getFrameSphere | ( | const class Sphere & | worldSpaceSphere, |
| int | maxIterations = 20 |
||
| ) | const [inherited] |
| Vec3f cinder::Camera::getEyePoint | ( | ) | const [inherited] |
| void cinder::Camera::setEyePoint | ( | const Vec3f & | aEyePoint | ) | [inherited] |
| float cinder::Camera::getCenterOfInterest | ( | ) | const [inherited] |
| void cinder::Camera::setCenterOfInterest | ( | float | aCenterOfInterest | ) | [inherited] |
| Vec3f cinder::Camera::getCenterOfInterestPoint | ( | ) | const [inherited] |
| void cinder::Camera::setCenterOfInterestPoint | ( | const Vec3f & | centerOfInterestPoint | ) | [inherited] |
| Vec3f cinder::Camera::getWorldUp | ( | ) | const [inherited] |
| void cinder::Camera::setWorldUp | ( | const Vec3f & | aWorldUp | ) | [inherited] |
| void cinder::Camera::lookAt | ( | const Vec3f & | target | ) | [inherited] |
| void cinder::Camera::lookAt | ( | const Vec3f & | aEyePoint, |
| const Vec3f & | target | ||
| ) | [inherited] |
| void cinder::Camera::lookAt | ( | const Vec3f & | aEyePoint, |
| const Vec3f & | target, | ||
| const Vec3f & | aUp | ||
| ) | [inherited] |
| Vec3f cinder::Camera::getViewDirection | ( | ) | const [inherited] |
| void cinder::Camera::setViewDirection | ( | const Vec3f & | aViewDirection | ) | [inherited] |
| Quatf cinder::Camera::getOrientation | ( | ) | const [inherited] |
| void cinder::Camera::setOrientation | ( | const Quatf & | aOrientation | ) | [inherited] |
| float cinder::Camera::getFov | ( | ) | const [inherited] |
| void cinder::Camera::setFov | ( | float | aFov | ) | [inherited] |
| float cinder::Camera::getAspectRatio | ( | ) | const [inherited] |
| void cinder::Camera::setAspectRatio | ( | float | aAspectRatio | ) | [inherited] |
| float cinder::Camera::getNearClip | ( | ) | const [inherited] |
| void cinder::Camera::setNearClip | ( | float | aNearClip | ) | [inherited] |
| float cinder::Camera::getFarClip | ( | ) | const [inherited] |
| void cinder::Camera::setFarClip | ( | float | aFarClip | ) | [inherited] |
| void cinder::Camera::getFrustum | ( | float * | left, |
| float * | top, | ||
| float * | right, | ||
| float * | bottom, | ||
| float * | near, | ||
| float * | far | ||
| ) | const [inherited] |
Returns the coordinates of the camera's frustum, suitable for passing to glFrustum.
| Ray cinder::Camera::generateRay | ( | float | u, |
| float | v, | ||
| float | imagePlaneAspectRatio | ||
| ) | const [inherited] |
| void cinder::Camera::getBillboardVectors | ( | Vec3f * | right, |
| Vec3f * | up | ||
| ) | const [inherited] |
| Vec2f cinder::Camera::worldToScreen | ( | const Vec3f & | worldCoord, |
| float | screenWidth, | ||
| float | screenHeight | ||
| ) | const [inherited] |
Converts a world-space coordinate worldCoord to screen coordinates as viewed by the camera, based ona s screen which is screenWidth x screenHeight pixels.
| Vec3f cinder::Camera::worldToEye | ( | const Vec3f & | worldCoord | ) | [inherited] |
Converts a world-space coordinate worldCoord to eye-space, also known as camera-space. -Z is along the view direction.
| float cinder::Camera::worldToEyeDepth | ( | const Vec3f & | worldCoord | ) | const [inherited] |
Converts a world-space coordinate worldCoord to the z axis of eye-space, also known as camera-space. -Z is along the view direction. Suitable for depth sorting.
| Vec3f cinder::Camera::worldToNdc | ( | const Vec3f & | worldCoord | ) | [inherited] |
Converts a world-space coordinate worldCoord to normalized device coordinates.
| float cinder::Camera::getScreenRadius | ( | const class Sphere & | sphere, |
| float | screenWidth, | ||
| float | screenHeight | ||
| ) | const [inherited] |
| void cinder::Camera::calcMatrices | ( | ) | const [protected, inherited] |
Matrix44f cinder::CameraStereo::mProjectionMatrixLeft [mutable, protected] |
Matrix44f cinder::CameraStereo::mInverseProjectionMatrixLeft [mutable, protected] |
Matrix44f cinder::CameraStereo::mProjectionMatrixRight [mutable, protected] |
Matrix44f cinder::CameraStereo::mInverseProjectionMatrixRight [mutable, protected] |
Matrix44f cinder::CameraStereo::mModelViewMatrixLeft [mutable, protected] |
Matrix44f cinder::CameraStereo::mInverseModelViewMatrixLeft [mutable, protected] |
Matrix44f cinder::CameraStereo::mModelViewMatrixRight [mutable, protected] |
Matrix44f cinder::CameraStereo::mInverseModelViewMatrixRight [mutable, protected] |
Vec2f cinder::CameraPersp::mLensShift [protected, inherited] |
Vec3f cinder::Camera::mEyePoint [protected, inherited] |
Vec3f cinder::Camera::mViewDirection [protected, inherited] |
Quatf cinder::Camera::mOrientation [protected, inherited] |
float cinder::Camera::mCenterOfInterest [protected, inherited] |
Vec3f cinder::Camera::mWorldUp [protected, inherited] |
float cinder::Camera::mFov [protected, inherited] |
float cinder::Camera::mAspectRatio [protected, inherited] |
float cinder::Camera::mNearClip [protected, inherited] |
float cinder::Camera::mFarClip [protected, inherited] |
Vec3f cinder::Camera::mU [mutable, protected, inherited] |
Vec3f cinder::Camera::mV [mutable, protected, inherited] |
Vec3f cinder::Camera::mW [mutable, protected, inherited] |
Matrix44f cinder::Camera::mProjectionMatrix [mutable, protected, inherited] |
Matrix44f cinder::Camera::mInverseProjectionMatrix [mutable, protected, inherited] |
bool cinder::Camera::mProjectionCached [mutable, protected, inherited] |
Matrix44f cinder::Camera::mModelViewMatrix [mutable, protected, inherited] |
bool cinder::Camera::mModelViewCached [mutable, protected, inherited] |
Matrix44f cinder::Camera::mInverseModelViewMatrix [mutable, protected, inherited] |
bool cinder::Camera::mInverseModelViewCached [mutable, protected, inherited] |
float cinder::Camera::mFrustumLeft [mutable, protected, inherited] |
float cinder::Camera::mFrustumRight [mutable, protected, inherited] |
float cinder::Camera::mFrustumTop [mutable, protected, inherited] |
float cinder::Camera::mFrustumBottom [mutable, protected, inherited] |