HDK
|
#include <GEO_PrimVolume.h>
Public Types | |
enum | SamplingType { NON_SQUARE = 0, X_AXIS, Y_AXIS, Z_AXIS, MAX_AXIS, BY_SIZE } |
Public Member Functions | |
UT_Vector3 | toVoxelSpace (UT_Vector3 pos) const |
UT_Vector3 | fromVoxelSpace (UT_Vector3 pos) const |
UT_Matrix3 | toVoxelSpaceJacobian (UT_Vector3 pos) const |
UT_Matrix3 | fromVoxelSpaceJacobian (UT_Vector3 pos) const |
void | transform (const UT_Matrix4 &xform) |
void | transform (const UT_Matrix4D &xform) |
void | toVoxelSpace (UT_BoundingBox &box) const |
void | fromVoxelSpace (UT_BoundingBox &box) const |
bool | isTapered () const |
Returns if the transform is flagged as having a taper. More... | |
UT_Vector3R | computeSize () const |
Compute the size for this transform (relative to myCenter) More... | |
void | init () |
bool | operator== (const GEO_PrimVolumeXform &x) const |
void | getTransform4 (UT_Matrix4F &matx) const |
void | getTransform4 (UT_Matrix4D &matx) const |
void | save (std::ostream &os, bool binary=false) const |
bool | load (UT_IStream &is) |
Static Public Member Functions | |
static SamplingType | samplingType (int i) |
Convert the "uniformsamples" parm menu item index to a sampling type. More... | |
static UT_Vector3R | computeResolution (SamplingType sampling_type, const UT_Vector3R &non_uniform_divs, fpreal uniform_divs, fpreal div_size, fpreal z_div_scale, UT_Vector3R &size_inout, int twod_axis=-1) |
static GEO_PrimVolumeXform | frustumSpaceTransform (const UT_Vector3R &size, const UT_Vector3R ¢er, fpreal taper_x, fpreal taper_y) |
Compute a space transform from center, size, and taper. More... | |
static GEO_PrimVolumeXform | cameraFrustum (fpreal focal, fpreal aperture, const UT_Vector2R &image_res, fpreal pixel_aspect, bool is_ortho, fpreal ortho_zoom, fpreal clip_near, fpreal clip_far, bool use_cam_window, const UT_BoundingRectR &cam_window, const UT_BoundingRectR &cam_crop, const UT_BoundingRectR &window, const UT_Matrix4R &post_xform, const GEO_Detail *match_src) |
Public Attributes | |
UT_Matrix3 | myXform |
UT_Matrix3 | myInverseXform |
UT_Vector3 | myCenter |
bool | myHasTaper |
float | myTaperX |
float | myTaperY |
Stores the transform associated with a volume, allowing the to/from code to be inlined outside of this library.
Definition at line 33 of file GEO_PrimVolume.h.
Enumerator | |
---|---|
NON_SQUARE | |
X_AXIS | |
Y_AXIS | |
Z_AXIS | |
MAX_AXIS | |
BY_SIZE |
Definition at line 237 of file GEO_PrimVolume.h.
|
static |
Compute a space transform from camera settings. The ortho_zoom parameter is only used when is_ortho = true.
|
static |
Compute the resolution (and size) from a common set of parameters. If twod_axis is one of [0,1,2], then that axis clamped to a divisions of 1 and a size of 0. The number of divisions is returned with size set to div_size multiplied by divisions before the z_div_scale.
UT_Vector3R GEO_PrimVolumeXform::computeSize | ( | ) | const |
Compute the size for this transform (relative to myCenter)
|
inline |
Definition at line 70 of file GEO_PrimVolume.h.
|
inline |
Definition at line 203 of file GEO_PrimVolume.h.
|
inline |
Definition at line 137 of file GEO_PrimVolume.h.
|
static |
Compute a space transform from center, size, and taper.
void GEO_PrimVolumeXform::getTransform4 | ( | UT_Matrix4F & | matx | ) | const |
Returns the un-tapered matrix4 corresponding to fromVoxelSpace().
void GEO_PrimVolumeXform::getTransform4 | ( | UT_Matrix4D & | matx | ) | const |
Returns the un-tapered matrix4 corresponding to fromVoxelSpace().
|
inline |
Definition at line 294 of file GEO_PrimVolume.h.
|
inline |
Returns if the transform is flagged as having a taper.
Definition at line 231 of file GEO_PrimVolume.h.
bool GEO_PrimVolumeXform::load | ( | UT_IStream & | is | ) |
|
inline |
Definition at line 304 of file GEO_PrimVolume.h.
|
inlinestatic |
Convert the "uniformsamples" parm menu item index to a sampling type.
Definition at line 248 of file GEO_PrimVolume.h.
void GEO_PrimVolumeXform::save | ( | std::ostream & | os, |
bool | binary = false |
||
) | const |
|
inline |
Definition at line 37 of file GEO_PrimVolume.h.
|
inline |
Definition at line 182 of file GEO_PrimVolume.h.
|
inline |
Definition at line 103 of file GEO_PrimVolume.h.
|
inline |
Definition at line 166 of file GEO_PrimVolume.h.
|
inline |
Definition at line 174 of file GEO_PrimVolume.h.
UT_Vector3 GEO_PrimVolumeXform::myCenter |
Definition at line 315 of file GEO_PrimVolume.h.
bool GEO_PrimVolumeXform::myHasTaper |
Definition at line 316 of file GEO_PrimVolume.h.
UT_Matrix3 GEO_PrimVolumeXform::myInverseXform |
Definition at line 314 of file GEO_PrimVolume.h.
float GEO_PrimVolumeXform::myTaperX |
Definition at line 317 of file GEO_PrimVolume.h.
float GEO_PrimVolumeXform::myTaperY |
Definition at line 317 of file GEO_PrimVolume.h.
UT_Matrix3 GEO_PrimVolumeXform::myXform |
Definition at line 314 of file GEO_PrimVolume.h.