24 #ifndef PXR_IMAGING_HD_CAMERA_H 25 #define PXR_IMAGING_HD_CAMERA_H 28 #include "pxr/imaging/hd/api.h" 29 #include "pxr/imaging/hd/version.h" 30 #include "pxr/imaging/hd/sprim.h" 32 #include "pxr/imaging/cameraUtil/conformWindow.h" 40 PXR_NAMESPACE_OPEN_SCOPE
47 #define HD_CAMERA_TOKENS \ 50 (horizontalAperture) \ 52 (horizontalApertureOffset) \ 53 (verticalApertureOffset) \ 82 using ClipPlanesVector = std::vector<GfVec4d>;
90 enum DirtyBits : HdDirtyBits
93 DirtyTransform = 1 << 0,
95 DirtyClipPlanes = 1 << 2,
96 DirtyWindowPolicy = 1 << 3,
97 AllDirty = (DirtyTransform
116 HdDirtyBits *dirtyBits)
override;
141 return _horizontalAperture;
146 return _verticalAperture;
151 return _horizontalApertureOffset;
156 return _verticalApertureOffset;
166 return _clippingRange;
181 return _focusDistance;
184 double GetShutterOpen()
const {
188 double GetShutterClose()
const {
189 return _shutterClose;
192 float GetExposure()
const {
199 return _windowPolicy;
214 Projection _projection;
215 float _horizontalAperture;
216 float _verticalAperture;
217 float _horizontalApertureOffset;
218 float _verticalApertureOffset;
221 std::vector<GfVec4d> _clipPlanes;
225 float _focusDistance;
229 double _shutterClose;
234 CameraUtilConformWindowPolicy _windowPolicy;
237 PXR_NAMESPACE_CLOSE_SCOPE
239 #endif // PXR_IMAGING_HD_CAMERA_H std::vector< GfVec4d > const & GetClipPlanes() const
Returns any additional clipping planes defined in camera space.
GfRange1f const & GetClippingRange() const
Returns near and far plane in world units.
Hydra schema for a camera that pulls the params (see above) during Sync.
The HdRenderParam is an opaque (to core Hydra) handle, to an object that is obtained from the render ...
float GetFocalLength() const
Returns focal length in world units.
float GetVerticalApertureOffset() const
Returns vertical aperture offset in world units.
HD_API void Sync(HdSceneDelegate *sceneDelegate, HdRenderParam *renderParam, HdDirtyBits *dirtyBits) override
Sprim API.
Stores a 4x4 matrix of double elements.
Adapter class providing data exchange with the client scene graph.
#define TF_DECLARE_PUBLIC_TOKENS(...)
Macro to define public tokens.
float GetVerticalAperture() const
Returns vertical aperture in world units.
Projection GetProjection() const
Returns whether camera is orthographic and perspective.
Basic type: 1-dimensional floating point range.
A path value used to locate objects in layers or scenegraphs.
CameraUtilConformWindowPolicy const & GetWindowPolicy() const
Returns the window policy of the camera.
float GetFocusDistance() const
Returns focus distance in world units.
Sprim (state prim) is a base class of managing state for non-drawable scene entity (e....
HD_API GfMatrix4d ComputeProjectionMatrix() const
Convenience API for rasterizers.
float GetHorizontalAperture() const
Returns horizontal aperture in world units.
This file defines some macros that are useful for declaring and using static TfTokens.
GfMatrix4d const & GetTransform() const
Camera parameters accessor API.
float GetFStop() const
Returns fstop of camera.
float GetHorizontalApertureOffset() const
Returns horizontal aperture offset in world units.
HD_API HdDirtyBits GetInitialDirtyBitsMask() const override
Returns the minimal set of dirty bits to place in the change tracker for use in the first sync of thi...