7#ifndef EXT_RMANPKG_PLUGIN_RENDERMAN_PLUGIN_HD_PRMAN_CAMERA_H
8#define EXT_RMANPKG_PLUGIN_RENDERMAN_PLUGIN_HD_PRMAN_CAMERA_H
11#include "hdPrman/api.h"
12#include "hdPrman/renderParam.h"
13#include "pxr/imaging/hd/camera.h"
14#include "pxr/imaging/hd/timeSampleArray.h"
22PXR_NAMESPACE_OPEN_SCOPE
42 std::optional<float> shutterOpenTime;
43 std::optional<float> shutterCloseTime;
44 std::optional<std::array<float, 8>> shutteropening;
57 HdDirtyBits *dirtyBits)
override;
67 GetProjectionNode()
const {
68 return _projectionNode;
71#if HD_API_VERSION < 52
72 float GetLensDistortionK1()
const {
73 return _lensDistortionK1;
76 float GetLensDistortionK2()
const {
77 return _lensDistortionK2;
80 const GfVec2f &GetLensDistortionCenter()
const {
81 return _lensDistortionCenter;
84 float GetLensDistortionAnaSq()
const {
85 return _lensDistortionAnaSq;
88 const GfVec2f &GetLensDistortionAsym()
const {
89 return _lensDistortionAsym;
92 float GetLensDistortionScale()
const {
93 return _lensDistortionScale;
131 return _shutterCurve;
138 RtParamList& camParamsOverride,
139 RtParamList& projParams)
const;
141 float GetDofAspect()
const {
145 float GetApertureAngle()
const {
146 return _apertureAngle;
149 float GetApertureDensity()
const {
150 return _apertureDensity;
153 float GetApertureNSides()
const {
154 return _apertureNSides;
157 float GetApertureRoundness()
const {
158 return _apertureRoundness;
161 float GetDofMult()
const {
167 void setFov(RtParamList& projParams)
const;
169 void setScreenWindow(RtParamList& camParams,
bool isPerspective)
const;
173#if HD_API_VERSION < 52
174 float _lensDistortionK1;
175 float _lensDistortionK2;
177 float _lensDistortionAnaSq;
179 float _lensDistortionScale;
192 ShutterCurve _shutterCurve;
195 float _apertureAngle;
196 float _apertureDensity;
198 float _apertureRoundness;
203 riley::ShadingNode _projectionNode;
207PXR_NAMESPACE_CLOSE_SCOPE
Basic type for a vector of 2 float components.
Hydra schema for a camera that pulls the params (see above) during Sync.
A representation for cameras that pulls on camera parameters used by Riley cameras.
HDPRMAN_API void SetRileyCameraParams(RtParamList &camParams, RtParamList &camParamsOverride, RtParamList &projParams) const
Sets the camera and projection shader parameters as expected by Riley from the USD physical camera pa...
HDPRMAN_API void Sync(HdSceneDelegate *sceneDelegate, HdRenderParam *renderParam, HdDirtyBits *dirtyBits) override
Synchronizes state from the delegate to this object.
HDPRMAN_API HdTimeSampleArray< GfMatrix4d, HDPRMAN_MAX_TIME_SAMPLES > const & GetTimeSampleXforms() const
Returns the time sampled xforms that were queried during Sync.
const ShutterCurve & GetShutterCurve() const
Get the shutter curve of the camera.
See GetShutterCurve() below for a description of what these values represent.
The HdRenderParam is an opaque (to core Hydra) handle, to an object that is obtained from the render ...
Adapter class providing data exchange with the client scene graph.
A path value used to locate objects in layers or scenegraphs.
A map with string keys and VtValue values.
An array of a value sampled over time, in struct-of-arrays layout.