272 mTransInterp = nTransInterp;
326 float SegmentLength(
int nFrom,
int nTo,
float fStep,
float fStart,
float fEnd);
332 std::vector<Key<Quat>> mRotKeys;
333 std::vector<Key<Vector3>> mTransKeys;
334 std::vector<Key<Vector3>> mScaleKeys;
Stream of raw bytes, the base of the memory, file, and network streams.
Definition binstream.h:22
Text output stream.
Definition prnstream.h:16
RndAnimatable()
Construct an animatable at frame 0 without children or filters.
Definition rndanimatable.h:600
RndDrawable()
Construct a showing drawable without a highlight or children.
Definition rnddrawable.h:23
RndObject(const char *pszName)
Construct an object and register it under a name.
RndTransAnim(const char *pszName)
Construct an animation of nothing with spline translation, linear scale, and no keys.
void Save(BinStream &stream) override
Write the animation and its bases.
static RndObject * New(const char *pszName)
Create an animation.
Definition rndtransanim.h:206
RndTransformable * GetTrans() const
Definition rndtransanim.h:261
std::vector< Key< Vector3 > > & GetTransKeys()
Definition rndtransanim.h:281
void SetFramesOwner(RndTransAnim *pOwner)
Take the keys from another animation.
void Copy(const RndObject *pSource, int nFlags) override
Copy another animation and its bases.
const std::vector< Key< Quat > > & GetRotKeys() const
Definition rndtransanim.h:231
void Replace(RndObject *pFrom, RndObject *pTo) override
Replace a referenced object with another.
Interp
How the translation and scale keys interpolate.
Definition rndtransanim.h:26
@ kInterpLinear
Definition rndtransanim.h:27
@ kInterpSpline
Definition rndtransanim.h:28
RndTransAnim * GetFramesOwner() const
Definition rndtransanim.h:226
void ListAnimObjects(std::list< RndObject * > &objects) override
Add the target to a list, then the objects of the children.
static const char * sClassName
The class name a .rnd file writes, TransAnim.
Definition rndtransanim.h:216
float SegmentLength(int nFrom, int nTo, float fStep, float fStart, float fEnd)
Measure the translation path between two keys, from one position to another.
void SetTransInterp(int nTransInterp)
Definition rndtransanim.h:271
std::vector< Key< Vector3 > > & GetScaleKeys()
Definition rndtransanim.h:251
~RndTransAnim() override
Drop the references on the target and the frames owner.
void MakeTransform(float fFrame, Transform &xfm, int bWhole)
Build the transform at a frame.
const std::vector< Key< Vector3 > > & GetScaleKeys() const
Definition rndtransanim.h:246
void Load(BinStream &stream) override
Read what Save() wrote, or an earlier version of it.
void ReleaseRefs()
Drop the references on the target and the frames owner.
void SetTrans(RndTransformable *pTrans)
Set the transformable the animation drives.
static int sRev
The format version Save() writes and Load() accepts.
Definition rndtransanim.h:223
float EndFrame() override
Report the last frame of any key.
const std::vector< Key< Vector3 > > & GetTransKeys() const
Definition rndtransanim.h:276
void SetTransKeys(const std::vector< Key< Vector3 > > &keys)
Definition rndtransanim.h:286
void SetRotKeys(const std::vector< Key< Quat > > &keys)
Definition rndtransanim.h:241
void AcquireRefs()
Take references on the target and the frames owner.
static constexpr int kCopyShareKeys
The bit of the Copy() flags that shares the source's keys rather than copying them.
Definition rndtransanim.h:23
int GetTransInterp() const
Definition rndtransanim.h:266
float PathLength(float fStart, float fEnd)
Measure the length of the translation path between two frames.
int SetFrameSelf(float fFrame) override
Apply a frame to the target's local transform.
void SetScaleKeys(const std::vector< Key< Vector3 > > &keys)
Definition rndtransanim.h:256
const char * ClassName() const override
Report the class name.
Definition rndtransanim.h:126
void DumpText(PrnStream &stream) override
Write a description of the animation and its bases.
virtual float StartFrame()
Report the first frame of any key.
std::vector< Key< Quat > > & GetRotKeys()
Definition rndtransanim.h:236
void InterpVector(const std::vector< Key< Vector3 > > &keys, int nInterp, Vector3 &out, Vector3 *pTangent, float fFrame)
Interpolate vector keys at a frame.
PrnStream & operator<<(PrnStream &stream, RndTransAnim::Interp eInterp)
Write the name of an interpolation.
One keyframe of an animation channel, a value at a frame.
Definition key.h:21
Three-component vector, padded to a PlayStation 2 quadword.
Definition vector3.h:14