24 #ifndef PXR_BASE_GF_CAMERA_H
25 #define PXR_BASE_GF_CAMERA_H
83 float horizontalApertureOffset = 0.0,
84 float verticalApertureOffset = 0.0,
85 float focalLength = 50.0,
87 const std::vector<GfVec4f> &clippingPlanes = std::vector<GfVec4f>(),
89 float focusDistance = 0.0);
158 const float focalLength = 50.0);
241 float _horizontalAperture;
242 float _verticalAperture;
243 float _horizontalApertureOffset;
244 float _verticalApertureOffset;
247 std::vector<GfVec4f> _clippingPlanes;
251 float _focusDistance;
256 #endif // PXR_BASE_GF_CAMERA_H
GF_API const std::vector< GfVec4f > & GetClippingPlanes() const
Returns additional clipping planes.
FOVDirection
Direction used for Field of View or orthographic size.
GF_API void SetVerticalAperture(const float val)
Object-based representation of a camera.
GF_API float GetHorizontalAperture() const
IMF_EXPORT IMATH_NAMESPACE::V3f direction(const IMATH_NAMESPACE::Box2i &dataWindow, const IMATH_NAMESPACE::V2f &pixelPosition)
GF_API void SetProjection(const Projection &val)
Sets the projection type.
GF_API GfFrustum GetFrustum() const
GF_API void SetHorizontalApertureOffset(const float val)
GF_API GfMatrix4d GetTransform() const
static GF_API const double DEFAULT_VERTICAL_APERTURE
GF_API void SetFocalLength(const float val)
GF_API void SetClippingRange(const GfRange1f &val)
Sets the clipping range in world units.
GF_API float GetFStop() const
Returns the lens aperture.
GF_API void SetPerspectiveFromAspectRatioAndFieldOfView(float aspectRatio, float fieldOfView, FOVDirection direction, float horizontalAperture=DEFAULT_HORIZONTAL_APERTURE)
GF_API void SetFocusDistance(const float val)
Sets the focus distance in world units.
GF_API float GetVerticalApertureOffset() const
GF_API GfCamera(const GfMatrix4d &transform=GfMatrix4d(1.0), Projection projection=Perspective, float horizontalAperture=DEFAULT_HORIZONTAL_APERTURE, float verticalAperture=DEFAULT_VERTICAL_APERTURE, float horizontalApertureOffset=0.0, float verticalApertureOffset=0.0, float focalLength=50.0, const GfRange1f &clippingRange=GfRange1f(1, 1000000), const std::vector< GfVec4f > &clippingPlanes=std::vector< GfVec4f >(), float fStop=0.0, float focusDistance=0.0)
GF_API void SetTransform(const GfMatrix4d &val)
Sets the transform of the filmback in world space to val.
GF_API void SetVerticalApertureOffset(const float val)
GF_API Projection GetProjection() const
Returns the projection type.
GF_API float GetAspectRatio() const
Returns the projector aperture aspect ratio.
GF_API float GetHorizontalApertureOffset() const
GF_API void SetFStop(const float val)
Sets the lens aperture, unitless.
static GF_API const double FOCAL_LENGTH_UNIT
The unit for focal length. Similar to APERTURE_UNIT.
GA_API const UT_StringHolder transform
static GF_API const double DEFAULT_HORIZONTAL_APERTURE
GF_API void SetClippingPlanes(const std::vector< GfVec4f > &val)
PXR_NAMESPACE_CLOSE_SCOPE PXR_NAMESPACE_OPEN_SCOPE
GF_API void SetFromViewAndProjectionMatrix(const GfMatrix4d &viewMatrix, const GfMatrix4d &projMatix, const float focalLength=50.0)
static GF_API const double APERTURE_UNIT
GF_API float GetFocusDistance() const
Returns the focus distance in world units.
#define PXR_NAMESPACE_CLOSE_SCOPE
GF_API float GetFieldOfView(FOVDirection direction) const
Returns the horizontal or vertical field of view in degrees.
GF_API bool operator!=(const GfCamera &other) const
Projection
Projection type.
GF_API void SetOrthographicFromAspectRatioAndSize(float aspectRatio, float orthographicSize, FOVDirection direction)
GF_API float GetVerticalAperture() const
GF_API GfRange1f GetClippingRange() const
Returns the clipping range in world units.
GF_API float GetFocalLength() const
GF_API bool operator==(const GfCamera &other) const
Equality operator. true iff all parts match.
GF_API void SetHorizontalAperture(const float val)