37 #ifndef AGXGL_CAMERA_H
38 #define AGXGL_CAMERA_H
56 virtual void configure(agx::TiXmlElement *eCamera)
override;
58 static Camera *getActiveCamera();
69 void setViewPort(
unsigned width,
unsigned height);
76 void setProjectionMatrixAsOrtho(
double left,
double right,
77 double bottom,
double top,
78 double zNear,
double zFar);
81 void setProjectionMatrixAsFrustum(
double left,
double right,
82 double bottom,
double top,
83 double zNear,
double zFar);
88 void setProjectionMatrixAsPerspective(
double fovy,
double aspectRatio,
89 double zNear,
double zFar);
96 bool getProjectionMatrixAsOrtho(
double& left,
double& right,
97 double& bottom,
double& top,
98 double& zNear,
double& zFar)
const;
102 bool getProjectionMatrixAsFrustum(
double& left,
double& right,
103 double& bottom,
double& top,
104 double& zNear,
double& zFar)
const;
111 bool getProjectionMatrixAsPerspective(
double& fovy,
double& aspectRatio,
112 double& zNear,
double& zFar)
const;
148 static Camera *mainCamera();
149 static void setMainCamera(
Camera *camera);
agxData::Value::Event::CallbackType m_projectionCallback
agxData::ValueRefT< agx::Matrix4x4 > m_viewMatrix
agxData::ValueRefT< agx::Real > m_fovX
A component is an object containing other objects, enabling hierarchical structuring.
A model is an abstract representation of the class of an agx::Object.
Abstract representation of a value.
Matrix class for affine transformations.
#define AGXPHYSICS_EXPORT
#define AGX_DECLARE_POINTER_TYPES(type)
Representation of a name string.
agxData::ValueRefT< agx::Matrix4x4 > m_projectionMatrix
agxData::ValueRefT< agx::Matrix4x4 > m_modelViewProjectionMatrix
agxData::Value::Event::CallbackType m_transformCallback
Templated callback with one argument.
agxData::ValueRefT< agx::AffineMatrix4x4 > m_transform
agxData::ValueRefT< agx::Real > m_fovY
const agx::Matrix4x4 & getViewMatrix() const
Get the view matrix.
agxData::ValueRefT< agx::UInt > m_windowWidth
An agx::Device is an abstract representation of a device on which data can be stored and processed...
agxData::ValueRefT< agx::UInt > m_windowHeight
const agx::Matrix4x4 & getProjectionMatrix() const
Get the projection matrix.
agx::TaskRef m_renderTask