Loading...
Searching...
No Matches
Alembic::AbcGeom::ALEMBIC_VERSION_NS::XformOp Class Reference

Xform Operation This class holds the data about a particular transform operation, but does not hold the actual data to calculate a 4x4 matrix. It holds the type of operation (Translate, Rotate, Scale, Matrix), a hint about the type which can be interpreted by packages like Maya, and what particular parts of the operations can change over time. More...

`#include <XformOp.h>`

## Public Member Functions

| XformOp (const XformOperationType iType, const Alembic::Util::uint8_t iHint=0)
| XformOp (const Alembic::Util::uint8_t iEncodedOp)
XformOperationType | getType () const
| Get the type of transform operation. (Translate, Rotate, Scale, Matrix)
void | setType (const XformOperationType iType)
Alembic::Util::uint8_t | getHint () const
void | setHint (const Alembic::Util::uint8_t iHint)
bool | isXAnimated () const
bool | isYAnimated () const
bool | isZAnimated () const
bool | isAngleAnimated () const
bool | isChannelAnimated (std::size_t iIndex) const
std::size_t | getNumChannels () const
double | getDefaultChannelValue (std::size_t iIndex) const
double | getChannelValue (std::size_t iIndex) const
void | setChannelValue (std::size_t iIndex, double iVal)
void | setVector (const Abc::V3d &iVec)
void | setTranslate (const Abc::V3d &iTrans)
void | setScale (const Abc::V3d &iScale)
void | setAxis (const Abc::V3d &iAxis)
void | setAngle (const double iAngle)
void | setMatrix (const Abc::M44d &iMatrix)
void | setXRotation (const double iAngle)
void | setYRotation (const double iAngle)
void | setZRotation (const double iAngle)
Abc::V3d | getVector () const
Abc::V3d | getTranslate () const
Abc::V3d | getScale () const
Abc::V3d | getAxis () const
double | getAngle () const
Abc::M44d | getMatrix () const
double | getXRotation () const
double | getYRotation () const
double | getZRotation () const
bool | isTranslateOp () const
bool | isScaleOp () const
bool | isRotateOp () const
bool | isMatrixOp () const
bool | isRotateXOp () const
bool | isRotateYOp () const
bool | isRotateZOp () const
Alembic::Util::uint8_t | getOpEncoding () const

## Friends

class | IXformSchema

## Detailed Description

Xform Operation This class holds the data about a particular transform operation, but does not hold the actual data to calculate a 4x4 matrix. It holds the type of operation (Translate, Rotate, Scale, Matrix), a hint about the type which can be interpreted by packages like Maya, and what particular parts of the operations can change over time.

## Member Function Documentation

## getDefaultChannelValue()

double Alembic::AbcGeom::ALEMBIC_VERSION_NS::XformOp::getDefaultChannelValue | ( | std::size_t | iIndex | ) | const

For every channel, there's a default value. Typically, for each op type, it's the same across channels. But matrix ops have different defaults to allow the identity matrix to be defaulted (most channels there are 0.0, the determinant channels are 1.0).

## getHint()

uint8_t Alembic::AbcGeom::ALEMBIC_VERSION_NS::XformOp::getHint | ( |  | ) | const

Get the MatrixHint, RotateHint, TranslateHint, or ScaleHint to help disambiguate certain options that may have the same type.

## getNumChannels()

std::size_t Alembic::AbcGeom::ALEMBIC_VERSION_NS::XformOp::getNumChannels | ( |  | ) | const

Get the number of components that this operation has based on the type. Translate and Scale have 3, Rotate has 4 and Matrix has 16, and single-axis rotate ops (rotateX, rotateY, rotateZ) have 1.

## getOpEncoding()

Alembic::Util::uint8_t Alembic::AbcGeom::ALEMBIC_VERSION_NS::XformOp::getOpEncoding | ( |  | ) | const

Function for returning the combined encoded type and hint. The type is in the first four bits, the hint in the second.

This is not really intended for use by human clients of this class.

## isAngleAnimated()

bool Alembic::AbcGeom::ALEMBIC_VERSION_NS::XformOp::isAngleAnimated | ( |  | ) | const

Returns whether the angle component (index 3) is animated. Since Scale and Translate do not have an angle component, false is returned for those types. Only meaningful on read.

## isChannelAnimated()

bool Alembic::AbcGeom::ALEMBIC_VERSION_NS::XformOp::isChannelAnimated | ( | std::size_t | iIndex | ) | const

Returns whether a particular channel is animated. Scale and Translate only have 3 channels, Rotate has 4, and Matrix has 16. Indices greater than the number of channels will return false. Only meaningful on read.

## isXAnimated()

bool Alembic::AbcGeom::ALEMBIC_VERSION_NS::XformOp::isXAnimated | ( |  | ) | const

Returns whether the x component (index 0) is animated. Only meaningful on read.

## isYAnimated()

bool Alembic::AbcGeom::ALEMBIC_VERSION_NS::XformOp::isYAnimated | ( |  | ) | const

Returns whether the y component (index 1) is animated. Only meaningful on read.

## isZAnimated()

bool Alembic::AbcGeom::ALEMBIC_VERSION_NS::XformOp::isZAnimated | ( |  | ) | const

Returns whether the z component (index 2) is animated. Only meaningful on read.

## setChannelValue()

void Alembic::AbcGeom::ALEMBIC_VERSION_NS::XformOp::setChannelValue | ( | std::size_t | iIndex,
|  | double | iVal )

Set a single channel; will throw if iIndex is greater than numchannels - 1.

## setHint()

void Alembic::AbcGeom::ALEMBIC_VERSION_NS::XformOp::setHint | ( | const Alembic::Util::uint8_t | iHint | ) |

Set the hint, if it is an illegal value for the type, then the hint is set to the default, 0.

## setType()

void Alembic::AbcGeom::ALEMBIC_VERSION_NS::XformOp::setType | ( | const XformOperationType | iType | ) |

Set the type of transform operation. (Translate, Rotate, Scale, Matrix) Setting the type resets the hint, and sets all the channels to static.

## Friends And Related Symbol Documentation

## IXformSchema

friend class IXformSchema

friend

The IXform can tell the op if its channels are animated by directly inserting keys into the m_animChannels set.

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

- AbcGeom/XformOp.h
- AbcGeom/XformOp.cpp