HDK
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
HdCamera Class Reference

#include <camera.h>

+ Inheritance diagram for HdCamera:

Public Types

enum  DirtyBits : HdDirtyBits {
  Clean = 0, DirtyViewMatrix = 1 << 0, DirtyProjMatrix = 1 << 1, DirtyWindowPolicy = 1 << 2,
  DirtyClipPlanes = 1 << 3, DirtyParams = 1 << 4, AllDirty
}
 
typedef std::vector< GfVec4dClipPlanesVector
 

Public Member Functions

HD_API HdCamera (SdfPath const &id)
 
virtual HD_API ~HdCamera ()
 
virtual HD_API void Sync (HdSceneDelegate *sceneDelegate, HdRenderParam *renderParam, HdDirtyBits *dirtyBits) override
 Sprim API. More...
 
virtual HD_API HdDirtyBits GetInitialDirtyBitsMask () const override
 
HD_API GfMatrix4d constGetViewMatrix () const
 Camera parameters accessor API. More...
 
HD_API GfMatrix4d constGetViewInverseMatrix () const
 Returns the matrix transformation from camera to world space. More...
 
HD_API GfMatrix4d constGetProjectionMatrix () const
 Returns the projection matrix for the camera. More...
 
HD_API std::vector< GfVec4d >
const
GetClipPlanes () const
 Returns any additional clipping planes defined in camera space. More...
 
HD_API
CameraUtilConformWindowPolicy
const
GetWindowPolicy () const
 
- Public Member Functions inherited from HdSprim
HD_API HdSprim (SdfPath const &id)
 
virtual HD_API ~HdSprim ()
 
SdfPath constGetId () const
 
virtual HD_API void Finalize (HdRenderParam *renderParam)
 

Protected Attributes

GfMatrix4d _worldToViewMatrix
 
GfMatrix4d _worldToViewInverseMatrix
 
GfMatrix4d _projectionMatrix
 
CameraUtilConformWindowPolicy _windowPolicy
 
std::vector< GfVec4d_clipPlanes
 

Detailed Description

Hydra schema for a camera that pulls the basic params (see above) during Sync. Backends that use additional camera parameters can inherit from HdCamera and pull on them.

Definition at line 78 of file camera.h.

Member Typedef Documentation

typedef std::vector<GfVec4d> HdCamera::ClipPlanesVector

Definition at line 80 of file camera.h.

Member Enumeration Documentation

Enumerator
Clean 
DirtyViewMatrix 
DirtyProjMatrix 
DirtyWindowPolicy 
DirtyClipPlanes 
DirtyParams 
AllDirty 

Definition at line 88 of file camera.h.

Constructor & Destructor Documentation

HD_API HdCamera::HdCamera ( SdfPath const id)
virtual HD_API HdCamera::~HdCamera ( )
virtual

Member Function Documentation

HD_API std::vector<GfVec4d> const& HdCamera::GetClipPlanes ( ) const
inline

Returns any additional clipping planes defined in camera space.

Definition at line 143 of file camera.h.

virtual HD_API HdDirtyBits HdCamera::GetInitialDirtyBitsMask ( ) const
overridevirtual

Returns the minimal set of dirty bits to place in the change tracker for use in the first sync of this prim. Typically this would be all dirty bits.

Implements HdSprim.

HD_API GfMatrix4d const& HdCamera::GetProjectionMatrix ( ) const
inline

Returns the projection matrix for the camera.

Definition at line 137 of file camera.h.

HD_API GfMatrix4d const& HdCamera::GetViewInverseMatrix ( ) const
inline

Returns the matrix transformation from camera to world space.

Definition at line 131 of file camera.h.

HD_API GfMatrix4d const& HdCamera::GetViewMatrix ( ) const
inline

Camera parameters accessor API.

Returns the matrix transformation from world to camera space.

Definition at line 125 of file camera.h.

HD_API CameraUtilConformWindowPolicy const& HdCamera::GetWindowPolicy ( ) const
inline

Returns the window policy of the camera. If no opinion is authored, we default to "CameraUtilFit"

Definition at line 150 of file camera.h.

virtual HD_API void HdCamera::Sync ( HdSceneDelegate sceneDelegate,
HdRenderParam renderParam,
HdDirtyBits dirtyBits 
)
overridevirtual

Sprim API.

Synchronizes state from the delegate to this object.

Implements HdSprim.

Member Data Documentation

std::vector<GfVec4d> HdCamera::_clipPlanes
protected

Definition at line 159 of file camera.h.

GfMatrix4d HdCamera::_projectionMatrix
protected

Definition at line 157 of file camera.h.

CameraUtilConformWindowPolicy HdCamera::_windowPolicy
protected

Definition at line 158 of file camera.h.

GfMatrix4d HdCamera::_worldToViewInverseMatrix
protected

Definition at line 156 of file camera.h.

GfMatrix4d HdCamera::_worldToViewMatrix
protected

Definition at line 155 of file camera.h.


The documentation for this class was generated from the following file: