24 #ifndef PXR_USD_SDF_LAYER_OFFSET_H 25 #define PXR_USD_SDF_LAYER_OFFSET_H 30 #include "pxr/usd/sdf/api.h" 32 #include <boost/operators.hpp> 36 PXR_NAMESPACE_OPEN_SCOPE
83 void SetOffset(
double newOffset) { _offset = newOffset; }
86 void SetScale(
double newScale) { _scale = newScale; }
155 typedef std::vector<SdfLayerOffset> SdfLayerOffsetVector;
163 PXR_NAMESPACE_CLOSE_SCOPE
165 #endif // PXR_USD_SDF_LAYER_OFFSET_H void SetOffset(double newOffset)
Sets the time offset.
SDF_API bool IsValid() const
Returns true if this offset is valid, i.e.
SDF_API SdfLayerOffset operator *(const SdfLayerOffset &rhs) const
Composes this with the offset rhs, such that the resulting offset is equivalent to first applying rhs...
SDF_API bool IsIdentity() const
Returns true if this is an identity transformation, with an offset of 0.0 and a scale of 1....
SDF_API bool operator==(const SdfLayerOffset &rhs) const
Returns whether the offsets are equal.
SDF_API size_t GetHash() const
Returns hash for this offset.
Value type that represents a time code.
SDF_API bool operator<(const SdfLayerOffset &rhs) const
Returns whether this offset is less than another.
Hash functor for hash maps and sets.
SDF_API std::ostream & operator<<(std::ostream &out, const SdfLayerOffset &layerOffset)
Writes the string representation of SdfLayerOffset to out.
double GetScale() const
Returns the time scale factor.
void SetScale(double newScale)
Sets the time scale factor.
SDF_API SdfLayerOffset GetInverse() const
Gets the inverse offset, which performs the opposite transformation.
SDF_API SdfLayerOffset(double offset=0.0, double scale=1.0)
Constructs a new SdfLayerOffset instance.
double GetOffset() const
Returns the time offset.
Represents a time offset and scale between layers.