Classes | Public Member Functions | Static Public Member Functions | Protected Attributes | Friends

Animatable Class Reference

This reference page is linked to from the following overview topics: Lesson 3: the reference system, Lesson 4: Animation Controllers, Interface Querying, Incremental Improvements, Plug-in Upgrade Guide, What's New: 3ds Max 9 SDK, SuperClassID Cleanup, Overview: Class Hierarchy, Overview: Animatable Hierarchy, Reference System Best Practices, AddAppDataChunk and MAX_malloc(), RTTI and GetInterface(), Handling Requests for Interfaces, Working with Plug-ins, Plug-in Architecture, Plug-in Base Classes, Interface Querying, Accessing and Exposing Parameter Blocks, Enumerating and Exposing Assets, Custom Scene Data, Application Data, Reference Object Lifetime Management, The Undo Mechanism and Transform Controllers, Animatables and Sub-Animatables, Animatable Handles, Track View, Track View Key Operations, Building Action Tables, Parameter Editing on the Command Panel, Schematic View API, Schematic View Events, Schematic View Relationships, Mixin Interfaces, Publishing Mixin Interface on Arbitrary Classes, Extending Animatable::GetInterface(), Wrapping 3ds Max Objects, Main Physique Export API Elements, Accessing Physique Vertex Assignments, Adding the Roll-up to the Command Panel, Removing the Roll-up from the Command Panel, Inverse Kinematics, IIKChainControl, Generating Class IDs, Plug-in Identification, Creating and Destroying Plug-in Instances, Exposing Parameter Blocks to 3ds Max, Command Panel Input, Enumerating and Identifying Sub-Animatables, Sub-Object Selection, Implementing Sub-Object Selection, Writing Animation Controller Plug-ins, Making Controllers Lockable, The Enhanced 3ds Max .NET SDK, Responding to Parameter Edits.


Search for all occurrences

Detailed Description

See also:
Class Interface, Class INode, Animatable Flags, Class IGraphObjectManager, Class IGraphNode, Class Object

Description:
This is the base class for all animatable scene entity types, and for most plugin types. Methods are available for getting the ClassID and SuperClassID of the plug-in, deleting this instance of the plug-in class, and parameter editing in the command panel. There are also methods that deal with the sub-animatables of the plug-in. Most of the track view related methods are here as well.
Method Groups:
See Method Groups for Class Animatable.
Data Members:
protected:

unsigned long aflag;

The flags. These may be manipulated using the methods SetAFlag(), ClearAFlag(), and TestAFlag(). See List of Animatable Flags.

AnimPropertyList aprops;

This is a table of properties that a plug-in may use for its own storage needs. This table is also used by the system (for example Note Tracks and APP_DATA). A plug-in may use this, for example, when a class has some data that is used while its user interface is up. It can store the UI data on the property list temporarily and not have to carry around the data when it is not needed. See the methods of Template Class Tab for how to add and delete items from the list. Also see the methods GetProperty() and SetProperty() and Class AnimPropertyList. Note that it's not safe to copy Animatable objects because the properties held in AnimPropertyList do not have a well-defined copy semantics

#include <Animatable.h>

Inheritance diagram for Animatable:
Inheritance graph
[legend]

List of all members.

Classes

class   EnumAnimList
  A callback class for enumerating animatables. More...

Public Member Functions

void  SetAFlag (DWORD mask)
  Sets one or more bits in the Animatable flags.
void  ClearAFlag (DWORD mask)
  Clears one or more bits in the Animatable flags.
BOOL  TestAFlag (DWORD mask)
  Tests one or more bits in the Animatable flags.
void  SetAFlagEx (DWORD mask)
  Sets one or more bits in the Animatable extended flags.
void  ClearAFlagEx (DWORD mask)
  Clears one or more bits in the Animatable extended flags.
BOOL  TestAFlagEx (DWORD mask)
  Tests one or more bits in the Animatable extended flags.
CoreExport bool  TestFlagBit (int index)
  Tests the specified flag bit.
CoreExport void  SetFlagBit (int index, bool newValue=true)
  Sets the specified flag bit.
CoreExport void  ClearFlagBit (int index)
  Clears the specified flag bit.
virtual void  FreeCaches ()
virtual void  BeginEditParams (IObjParam *ip, ULONG flags, Animatable *prev=NULL)
virtual void  EndEditParams (IObjParam *ip, ULONG flags, Animatable *next=NULL)
virtual CoreExport void *  GetInterface (ULONG id)
virtual CoreExport void  ReleaseInterface (ULONG id, void *i)
virtual CoreExport BaseInterface GetInterface (Interface_ID id)
virtual CoreExport int  SetProperty (ULONG id, void *data)
virtual CoreExport void *  GetProperty (ULONG id)
virtual int  NumSubs ()
virtual Animatable SubAnim (int i)
virtual CoreExport MSTR  SubAnimName (int i)
virtual BOOL  BypassTreeView ()
virtual BOOL  BypassTrackBar ()
virtual BOOL  BypassPropertyLevel ()
virtual BOOL  InvisibleProperty ()
virtual BOOL  AssignController (Animatable *control, int subAnim)
virtual BOOL  CanAssignController (int subAnim)
  Return true if we can reassign the subanim specified.
virtual BOOL  CanDeleteSubAnim (int i)
virtual void  DeleteSubAnim (int i)
virtual DWORD  GetSubAnimCurveColor (int subNum)
virtual int  SubNumToRefNum (int subNum)
virtual BOOL  CanCopyAnim ()
virtual BOOL  CanMakeUnique ()
virtual int  NumChildren ()
virtual Animatable ChildAnim (int i)
virtual CoreExport MSTR  NodeName ()
CoreExport int  EnumAnimTree (AnimEnum *animEnum, Animatable *client, int subNum)
CoreExport int  HasSubElements (int type=0)
virtual int  RenderBegin (TimeValue t, ULONG flags=0)
virtual int  RenderEnd (TimeValue t)
virtual void  EditTrack ()
virtual int  NumKeys ()
virtual TimeValue  GetKeyTime (int index)
virtual int  GetKeyIndex (TimeValue t)
virtual BOOL  GetNextKeyTime (TimeValue t, DWORD flags, TimeValue &nt)
virtual void  CopyKeysFromTime (TimeValue src, TimeValue dst, DWORD flags)
virtual void  DeleteKeyAtTime (TimeValue t)
virtual BOOL  IsKeyAtTime (TimeValue t, DWORD flags)
virtual int  GetKeyTimes (Tab< TimeValue > &times, Interval range, DWORD flags)
virtual int  GetKeySelState (BitArray &sel, Interval range, DWORD flags)
CoreExport void  OpenTreeEntry (int type, DWORD tv)
CoreExport void  CloseTreeEntry (int type, DWORD tv)
CoreExport int  IsTreeEntryOpen (int type, DWORD tv)
CoreExport BOOL  GetSelInTrackView (DWORD tv)
CoreExport void  SetSelInTrackView (DWORD tv, BOOL sel)
CoreExport BOOL  InTrackViewSelSet (int which)
CoreExport void  SetTrackViewSelSet (int which, BOOL inOut)
virtual CoreExport Interval  GetTimeRange (DWORD flags)
virtual void  EditTimeRange (Interval range, DWORD flags)
virtual void  DeleteTime (Interval iv, DWORD flags)
virtual void  ReverseTime (Interval iv, DWORD flags)
virtual void  ScaleTime (Interval iv, float s)
virtual void  InsertTime (TimeValue ins, TimeValue amount)
virtual BOOL  SupportTimeOperations ()
virtual CoreExport void  MapKeys (TimeMap *map, DWORD flags)
virtual void  DeleteKeys (DWORD flags)
virtual void  DeleteKeyByIndex (int index)
virtual void  SelectKeys (TrackHitTab &sel, DWORD flags)
virtual void  SelectSubKeys (int subNum, TrackHitTab &sel, DWORD flags)
virtual void  SelectSubCurve (int subNum, BOOL sel)
virtual void  SelectKeyByIndex (int i, BOOL sel)
virtual BOOL  IsKeySelected (int i)
virtual void  FlagKey (TrackHitRecord hit)
virtual int  GetFlagKeyIndex ()
virtual int  NumSelKeys ()
virtual void  CloneSelectedKeys (BOOL offset=FALSE)
virtual void  AddNewKey (TimeValue t, DWORD flags)
virtual void  MoveKeys (ParamDimensionBase *dim, float delta, DWORD flags)
virtual void  ScaleKeyValues (ParamDimensionBase *dim, float origin, float scale, DWORD flags)
virtual void  SelectCurve (BOOL sel)
virtual BOOL  IsCurveSelected ()
  Returns TRUE if the function curve is selected; otherwise returns FALSE.
virtual BOOL  IsSubCurveSelected (int subNum)
  Returns the selected state of the sub-curve whose index is passed.
virtual int  GetSelKeyCoords (TimeValue &t, float &val, DWORD flags)
virtual void  SetSelKeyCoords (TimeValue t, float val, DWORD flags)
virtual int  SetSelKeyCoordsExpr (ParamDimension *dim, MCHAR *timeExpr, MCHAR *valExpr, DWORD flags)
virtual void  AdjustTangents (TrackHitRecord hit, ParamDimensionBase *dim, Rect &rcGraph, float tzoom, int tscroll, float vzoom, int vscroll, int dx, int dy, DWORD flags)
virtual CoreExport BOOL  SubAnimSetKeyBufferPresent (int subNum)
  returns true if the sub-anim has a "Set Key" buffer present
virtual BOOL  SetKeyBufferPresent ()
  returns true if there is a "Set Key" buffer present
virtual CoreExport void  SubAnimCommitSetKeyBuffer (TimeValue t, int subNum)
  Commit any "Set Key" buffers on the given sub-anim.
virtual void  CommitSetKeyBuffer (TimeValue t)
  Commit any "Set Key" buffers.
virtual CoreExport void  SubAnimRevertSetKeyBuffer (int subNum)
  Revert any "Set Key" buffers on the given sub-anim.
virtual void  RevertSetKeyBuffer ()
  Revert any "Set Key" buffers.
virtual CoreExport BOOL  IsAnimated ()
virtual BOOL  CanCopyTrack (Interval iv, DWORD flags)
virtual BOOL  CanPasteTrack (TrackClipObject *cobj, Interval iv, DWORD flags)
virtual TrackClipObject CopyTrack (Interval iv, DWORD flags)
virtual void  PasteTrack (TrackClipObject *cobj, Interval iv, DWORD flags)
virtual BOOL  CanCopySubTrack (int subNum, Interval iv, DWORD flags)
virtual BOOL  CanPasteSubTrack (int subNum, TrackClipObject *cobj, Interval iv, DWORD flags)
virtual TrackClipObject CopySubTrack (int subNum, Interval iv, DWORD flags)
virtual void  PasteSubTrack (int subNum, TrackClipObject *cobj, Interval iv, DWORD flags)
virtual int  GetTrackVSpace (int lineHeight)
virtual int  HitTestTrack (TrackHitTab &hits, Rect &rcHit, Rect &rcTrack, float zoom, int scroll, DWORD flags)
virtual int  PaintTrack (ParamDimensionBase *dim, HDC hdc, Rect &rcTrack, Rect &rcPaint, float zoom, int scroll, DWORD flags)
virtual int  PaintSubTrack (int subNum, ParamDimensionBase *dim, HDC hdc, Rect &rcTrack, Rect &rcPaint, float zoom, int scroll, DWORD flags)
virtual int  PaintFCurves (ParamDimensionBase *dim, HDC hdc, Rect &rcGraph, Rect &rcPaint, float tzoom, int tscroll, float vzoom, int vscroll, DWORD flags)
virtual int  HitTestFCurves (ParamDimensionBase *dim, TrackHitTab &hits, Rect &rcHit, Rect &rcGraph, float tzoom, int tscroll, float vzoom, int vscroll, DWORD flags)
virtual int  PaintSubFCurves (int subNum, ParamDimensionBase *dim, HDC hdc, Rect &rcGraph, Rect &rcPaint, float tzoom, int tscroll, float vzoom, int vscroll, DWORD flags)
virtual int  HitTestSubFCurves (int subNum, ParamDimensionBase *dim, TrackHitTab &hits, Rect &rcHit, Rect &rcGraph, float tzoom, int tscroll, float vzoom, int vscroll, DWORD flags)
virtual void  EditTrackParams (TimeValue t, ParamDimensionBase *dim, MCHAR *pname, HWND hParent, IObjParam *ip, DWORD flags)
virtual int  TrackParamsType ()
virtual int  GetFCurveExtents (ParamDimensionBase *dim, float &min, float &max, DWORD flags)
  This method is called to calculate the largest and smallest values of the anim.
virtual int  GetSubFCurveExtents (int subNum, ParamDimensionBase *dim, float &min, float &max, DWORD flags)
  This method is called to calculate the largest and smallest values of the specified subanim.
virtual ParamDimension GetParamDimension (int i)
virtual LRESULT CALLBACK  TrackViewWinProc (HWND hwnd, UINT message, WPARAM wParam, LPARAM lParam)
  This function is obsolete.
virtual BOOL  SelectSubAnim (int subNum)
CoreExport void  AddNoteTrack (NoteTrack *note)
CoreExport void  DeleteNoteTrack (NoteTrack *note, BOOL delNote=TRUE)
CoreExport BOOL  HasNoteTracks ()
CoreExport int  NumNoteTracks ()
CoreExport NoteTrack GetNoteTrack (int i)
virtual CoreExport void  EnumAuxFiles (AssetEnumCallback &assetEnum, DWORD flags=FILE_ENUM_ALL)
virtual void  FreeAllBitmaps ()
virtual void  GetSystemNodes (INodeTab &nodes, SysNodeContext Context)
virtual BOOL  IsSubClassOf (Class_ID classID)
  returns true if the animatable has sub-classed off the given class
virtual BOOL  IsRefMaker ()
  Tells whether it is a ReferenceMaker.
CoreExport void  AddAppDataChunk (Class_ID cid, SClass_ID sid, DWORD sbid, DWORD len, void *data)
  Adds application/plugin specific (custom) data to an Animatable.
CoreExport AppDataChunk GetAppDataChunk (Class_ID cid, SClass_ID sid, DWORD sbid)
  Retrieves the application/plugin specific (custom) data stored with an Animatable.
CoreExport BOOL  RemoveAppDataChunk (Class_ID cid, SClass_ID sid, DWORD sbid)
  Deletes the application/plugin specific (custom) data stored with an Animatable.
CoreExport void  ClearAllAppData ()
  Deletes all application/plugin specific (custom) data stored with an Animatable.
virtual CoreExport void  MouseCycleCompleted (TimeValue t)
virtual CoreExport void  MouseCycleStarted (TimeValue t)
virtual int  NumParamBlocks ()
virtual IParamBlock2 GetParamBlock (int i)
virtual IParamBlock2 GetParamBlockByID (short id)
CoreExport bool  SvSaveData (ISave *isave, USHORT id)
CoreExport bool  SvLoadData (ILoad *iLoad)
CoreExport DWORD  SvGetRefIndex ()
CoreExport void  SvSetRefIndex (DWORD i)
CoreExport bool  SvDeleteRefIndex ()
virtual CoreExport
SvGraphNodeReference 
SvTraverseAnimGraph (IGraphObjectManager *gom, Animatable *owner, int id, DWORD flags)
CoreExport SvGraphNodeReference  SvStdTraverseAnimGraph (IGraphObjectManager *gom, Animatable *owner, int id, DWORD flags)
virtual CoreExport bool  SvCanInitiateLink (IGraphObjectManager *gom, IGraphNode *gNode)
virtual CoreExport bool  SvCanConcludeLink (IGraphObjectManager *gom, IGraphNode *gNode, IGraphNode *gNodeChild)
virtual CoreExport MSTR  SvGetName (IGraphObjectManager *gom, IGraphNode *gNode, bool isBeingEdited)
virtual CoreExport bool  SvCanSetName (IGraphObjectManager *gom, IGraphNode *gNode)
virtual CoreExport bool  SvSetName (IGraphObjectManager *gom, IGraphNode *gNode, MSTR &name)
virtual CoreExport bool  SvCanRemoveThis (IGraphObjectManager *gom, IGraphNode *gNode)
virtual CoreExport bool  SvRemoveThis (IGraphObjectManager *gom, IGraphNode *gNode)
  Called when the user deletes this object in the schematic view...
virtual CoreExport bool  SvIsSelected (IGraphObjectManager *gom, IGraphNode *gNode)
  Returns true if the object is selected in its schematic view.
virtual CoreExport bool  SvIsHighlighted (IGraphObjectManager *gom, IGraphNode *gNode)
virtual CoreExport COLORREF  SvHighlightColor (IGraphObjectManager *gom, IGraphNode *gNode)
virtual CoreExport COLORREF  SvGetSwatchColor (IGraphObjectManager *gom, IGraphNode *gNode)
virtual CoreExport bool  SvIsInactive (IGraphObjectManager *gom, IGraphNode *gNode)
virtual CoreExport bool  SvLinkChild (IGraphObjectManager *gom, IGraphNode *gNodeThis, IGraphNode *gNodeChild)
virtual CoreExport bool  SvHandleDoubleClick (IGraphObjectManager *gom, IGraphNode *gNode)
virtual CoreExport
MultiSelectCallback
SvGetMultiSelectCallback (IGraphObjectManager *gom, IGraphNode *gNode)
virtual CoreExport bool  SvCanSelect (IGraphObjectManager *gom, IGraphNode *gNode)
virtual CoreExport bool  SvEditProperties (IGraphObjectManager *gom, IGraphNode *gNode)
virtual CoreExport MSTR  SvGetTip (IGraphObjectManager *gom, IGraphNode *gNode)
virtual CoreExport MSTR  SvGetRefTip (IGraphObjectManager *gom, IGraphNode *gNode, IGraphNode *gNodeMaker)
virtual CoreExport bool  SvCanDetach (IGraphObjectManager *gom, IGraphNode *gNode)
virtual CoreExport bool  SvDetach (IGraphObjectManager *gom, IGraphNode *gNode)
virtual CoreExport MSTR  SvGetRelTip (IGraphObjectManager *gom, IGraphNode *gNodeTarget, int id, IGraphNode *gNodeMaker)
  Returns a string to be displayed in the tip window in the schematic view for a relationship from "gNodeMaker" to "gNodeTarget"...
virtual CoreExport bool  SvCanDetachRel (IGraphObjectManager *gom, IGraphNode *gNodeTarget, int id, IGraphNode *gNodeMaker)
  Returns true if this object can respond to the SvDetachRel(...) method...
virtual CoreExport bool  SvDetachRel (IGraphObjectManager *gom, IGraphNode *gNodeTarget, int id, IGraphNode *gNodeMaker)
  Detach this relationship.
virtual CoreExport bool  SvHandleRelDoubleClick (IGraphObjectManager *gom, IGraphNode *gNodeTarget, int id, IGraphNode *gNodeMaker)
  Called when this relationship is double-clicked in the schematic view...
CoreExport ICustAttribContainer GetCustAttribContainer ()
  This method returns a pointer to the custom attributes container interface class.
CoreExport void  AllocCustAttribContainer ()
  This method allocates space for a custom attributes container.
CoreExport void  DeleteCustAttribContainer ()
  This method deletes space used by a custom attributes container.
virtual bool  IsParamBlockDesc2Used (ParamBlockDesc2 *desc)
  Returns true if the passed description is being used.
Class identification
virtual void  GetClassName (MSTR &s)
  Retrieves the name of the plugin class.
virtual CoreExport SClass_ID  SuperClassID ()=0
  Retrieves a constant representing the type of the plugin.
virtual CoreExport Class_ID  ClassID ()
  Retrieves a constant that uniquely identifies the plugin class.

Static Public Member Functions

static CoreExport AnimHandle  GetHandleByAnim (Animatable *anim)
  Get the unique handle for an Animatable object.
static CoreExport Animatable GetAnimByHandle (AnimHandle handle)
  Get an Animatable object from its unique handle.
static CoreExport int  RequestFlagBit ()
  Requests an unique flag bit index.
static CoreExport void  ReleaseFlagBit (int index)
  Releases the flag bit index.
static CoreExport void  ClearFlagBitInAllAnimatables (int index)
  Clears the specified flag bit in all Animatables.
static CoreExport void  EnumerateAllAnimatables (EnumAnimList &enumProcObject)
  Enumerator to enumerate across all animatables.

Protected Attributes

DWORD  aflag
AnimPropertyList  aprops

Friends

class  ISaveImp
class  ILoadImp

Construction, destruction of instances

virtual CoreExport  ~Animatable ()=0
  Destructor.
CoreExport  Animatable ()
  Constructor.
virtual CoreExport void  DeleteThis ()
  Deletes an instance of this class.

Constructor & Destructor Documentation

virtual CoreExport ~Animatable ( ) [protected, pure virtual]

Destructor.

Instances of class Animatable and classes directly derived from it should be deleted by calling Animatable::DeleteThis() on them, rather then calling the delete operator.

CoreExport Animatable ( )

Constructor.


Member Function Documentation

virtual CoreExport void DeleteThis ( ) [virtual]

Deletes an instance of this class.

3ds Max calls this method when it needs to delete a plugin object (an instance of a class derived from Animatable). Similarly, plugins that need to delete instances of an Animatable or a class directly derived from it via an Animatable pointer, should call this method instead of calling directly operator delete. Following these rules will ensure that the same memory manager is used to allocate and deallocate the object. The default implementation of this method deletes the object. Plugin instances that never need to be deleted from the heap can overwrite this method to do nothing.

Note:
See the method ClassDesc::Create() for details on how Max allocates plugin objects.
See ReferenceMaker::DeleteMe() and ReferenceTarget::MaybeAutoDelete() for information on how plugin instances are deleted by the system.
Remarks:
See Memory Allocation.

See also:
Plugin DLL Functions, Class ClassDesc.

Reimplemented in EaseCurveList, MultCurveList, DummyObject, SphereGizmoObject, CylGizmoObject, BoxGizmoObject, CollisionPlane, CollisionSphere, CollisionMesh, ICustAttribContainer, MtlLib, MtlBaseLib, DADBitmapCarrier, RefTargMonitorRefMaker, GizmoClass, IStdDualVS, LinearShape, Manipulator, MCDeviceBinding, DefNoteTrack, PatchObject, PolyObject, SingleRefMaker, RefMgr< T >, SimpleOSMToWSMMod, SimpleOSMToWSMMod2, SimpleShape, SimpleSpline, SingleWeakRefMaker, SplineShape, TriObject, Wrangler, MSCustAttrib, MSPluginSimpleObject, MSSimpleObjectXtnd, MSPluginSimpleManipulator, MSPluginModifier, MSModifierXtnd, MSPluginSimpleMod, MSSimpleModXtnd, MSPluginTexmap, MSTexmapXtnd, MSPluginMtl, MSMtlXtnd, MSPluginTrackViewUtility, MSPluginObject< ShapeObject >, MSPluginObject< HelperObject >, MSPluginObject< GeomObject >, MSPluginObject< GenCamera >, MSPluginObject< GenLight >, MSObjectXtnd< GenCamera, MSPluginCamera >, MSObjectXtnd< HelperObject, MSPluginHelper >, MSObjectXtnd< GeomObject, MSPluginGeomObject >, MSObjectXtnd< ShapeObject, MSPluginShape >, MSObjectXtnd< GenLight, MSPluginLight >, MSPluginSpecialFX< Effect8 >, MSPluginSpecialFX< Atmospheric >, MSSpecialFXXtnd< Effect, MSPluginEffect >, and MSSpecialFXXtnd< Atmospheric, MSPluginAtmos >.

virtual void GetClassName ( MSTR s ) [inline, virtual]

Retrieves the name of the plugin class.

This name is usually used internally for debugging purposes. For Material plug-ins this method is used to put up the material "type" name in the Material Editor.

Parameters:
s Reference to a string filled in with the name of the plugin class

Reimplemented in EaseCurveList, MultCurveList, DummyObject, SphereGizmoObject, CylGizmoObject, BoxGizmoObject, Texmap, Mtl, MtlLib, MtlBaseLib, LinearShape, SimpleManipulator, PatchObject, PolyObject, ReferenceMaker, ReferenceTarget, SimpleOSMToWSMMod, SimpleOSMToWSMMod2, SimpleObject, SimpleWSMObject, SimpleParticle, SimpleShape, SimpleSpline, SplineShape, TriObject, MSCustAttrib, MSPluginSimpleObject, MSSimpleObjectXtnd, MSPluginSimpleManipulator, MSSimpleManipulatorXtnd, MSPluginModifier, MSModifierXtnd, MSPluginSimpleMod, MSSimpleModXtnd, MSPluginTexmap, MSTexmapXtnd, MSPluginMtl, MSMtlXtnd, MSPluginTrackViewUtility, PFSimpleAction, MSPluginObject< ShapeObject >, MSPluginObject< HelperObject >, MSPluginObject< GeomObject >, MSPluginObject< GenCamera >, MSPluginObject< GenLight >, MSObjectXtnd< GenCamera, MSPluginCamera >, MSObjectXtnd< HelperObject, MSPluginHelper >, MSObjectXtnd< GeomObject, MSPluginGeomObject >, MSObjectXtnd< ShapeObject, MSPluginShape >, MSObjectXtnd< GenLight, MSPluginLight >, MSPluginSpecialFX< Effect8 >, MSPluginSpecialFX< Atmospheric >, MSSpecialFXXtnd< Effect, MSPluginEffect >, and MSSpecialFXXtnd< Atmospheric, MSPluginAtmos >.

{ s = _M("Animatable"); }  
virtual CoreExport SClass_ID SuperClassID ( ) [pure virtual]
virtual CoreExport Class_ID ClassID ( ) [virtual]

Retrieves a constant that uniquely identifies the plugin class.

This method must return the unique ID for the plugin class. If two ClassIDs conflict, the system will only load the first conflicting one it finds. A program (gencid.exe) is provided to generate unique class id values.

Returns:
A class id that uniquely identifies a plugin class
See also:
Class ClassID, List of Class IDs.

Reimplemented in EaseCurveList, MultCurveList, DummyObject, SphereGizmoObject, CylGizmoObject, BoxGizmoObject, CollisionPlane, CollisionSphere, CollisionMesh, IIndirectRefTargContainer, IKMasterControl, IKSlaveControl, MtlBase, MtlLib, MtlBaseLib, DADBitmapCarrier, RefTargMonitorRefMaker, IStdDualVS, LinearShape, DefNoteTrack, PatchObject, PolyObject, RefMgrAddDeleteRestore< T >, RefMgr< T >, SimpleOSMToWSMMod, SimpleOSMToWSMMod2, SimpleShape, SimpleSpline, SplineShape, TriObject, MSCustAttrib, MSPluginSimpleObject, MSSimpleObjectXtnd, MSPluginSimpleManipulator, MSSimpleManipulatorXtnd, MSPluginModifier, MSModifierXtnd, MSPluginSimpleMod, MSSimpleModXtnd, MSPluginTexmap, MSTexmapXtnd, MSPluginMtl, MSMtlXtnd, MSPluginTrackViewUtility, PFSimpleAction, IXRefAtmospheric, IXRefObject, MSPluginObject< ShapeObject >, MSPluginObject< HelperObject >, MSPluginObject< GeomObject >, MSPluginObject< GenCamera >, MSPluginObject< GenLight >, MSObjectXtnd< GenCamera, MSPluginCamera >, MSObjectXtnd< HelperObject, MSPluginHelper >, MSObjectXtnd< GeomObject, MSPluginGeomObject >, MSObjectXtnd< ShapeObject, MSPluginShape >, MSObjectXtnd< GenLight, MSPluginLight >, MSPluginSpecialFX< Effect8 >, MSPluginSpecialFX< Atmospheric >, MSSpecialFXXtnd< Effect, MSPluginEffect >, and MSSpecialFXXtnd< Atmospheric, MSPluginAtmos >.

static CoreExport AnimHandle GetHandleByAnim ( Animatable anim ) [static]

Get the unique handle for an Animatable object.

Every Animatable is given a handle value when allocated. The values are unique within a scene, but are not saved with the scene, and no guarantees are provided about handle values from one load to another. Handles are intended for use as sort/hash keys, when load and save are not required. They are safer than pointers, since the Animatable may be deleted, in which case the handle value is never reused for another Animatable within the current session, and searching for the Animatable via GetAnimByHandle() simply yields NULL.

Parameters:
anim The Animatable object
Returns:
The unique handle value for the Animatable
static CoreExport Animatable* GetAnimByHandle ( AnimHandle  handle ) [static]

Get an Animatable object from its unique handle.

Every Animatable is given a handle value when allocated. The values are unique within a scene, but are not saved with the scene, and no guarantees are provided about handle values from one load to another. Handles are intended for use as sort/hash keys, when load and save are not required. They are safer than pointers, since the Animatable may be deleted, in which case the handle value is never reused for another Animatable within the current session, and searching for the Animatable via GetAnimByHandle() simply yields NULL.

Parameters:
handle The unique handle value for the Animatable
Returns:
The Animatable object, or NULL if the Animatable has been deleted, or if the handle is invalid
void SetAFlag ( DWORD  mask ) [inline]

Sets one or more bits in the Animatable flags.

Parameters:
mask The bits to turn on in the Animatable flags
                                  { 
            aflag |= mask; 
        }
void ClearAFlag ( DWORD  mask ) [inline]

Clears one or more bits in the Animatable flags.

Parameters:
mask The bits to turn off in the Animatable flags
                                    { 
            aflag &= ~mask; 
        }
BOOL TestAFlag ( DWORD  mask ) [inline]

Tests one or more bits in the Animatable flags.

Parameters:
mask The bits to test in the Animatable flags
Returns:
TRUE if one or more bit specified in the mask are also set in the Animatable flags, otherwise, false.
                                   { 
            return (aflag & mask ? TRUE : FALSE); 
        }
void SetAFlagEx ( DWORD  mask ) [inline]

Sets one or more bits in the Animatable extended flags.

Parameters:
mask The bits to turn on in the Animatable extended flags
                                    { 
            aflag_ex |= mask; 
        }
void ClearAFlagEx ( DWORD  mask ) [inline]

Clears one or more bits in the Animatable extended flags.

Parameters:
mask The bits to turn off in the Animatable extended flags
                                      { 
            aflag_ex &= ~mask; 
        }
BOOL TestAFlagEx ( DWORD  mask ) [inline]

Tests one or more bits in the Animatable extended flags.

Parameters:
mask The bits to test in the Animatable extended flags
Returns:
TRUE if one or more bit specified in the mask are also set in the Animatable extended flags
                                     { 
            return (aflag_ex & mask ? TRUE : FALSE); 
        }
static CoreExport int RequestFlagBit ( ) [static]

Requests an unique flag bit index.

The flag bit index is used with the Animatable::TestFlagBit(), Animatable::SetFlagBit(), Animatable::ClearFlagBit(), and Animatable::ClearFlagBitInAllAnimatables() methods. The flag bit index must be released using the Animatable::ReleaseFlagBit() method. The intended usage of the flag bit index is in enumerations where you want to visit each Animatable only once, and the usage of the flag bit is of a temporary, short term usage. The flag bits are not saved with the Animatable, nor copied via the assign operator. The flag bits referred to for these methods are not associated with the aflag or aflag_ex data members.

Returns:
The unique flag bit index
static CoreExport void ReleaseFlagBit ( int  index ) [static]

Releases the flag bit index.

Parameters:
index The flag bit index to release
CoreExport bool TestFlagBit ( int  index )

Tests the specified flag bit.

Parameters:
index The flag bit index to test
Returns:
TRUE if the flag bit is set
CoreExport void SetFlagBit ( int  index,
bool  newValue = true 
)

Sets the specified flag bit.

Parameters:
index The flag bit index to set /*!
newValue The value to set the flag bit index to
CoreExport void ClearFlagBit ( int  index )

Clears the specified flag bit.

Parameters:
index The flag bit index to clear
static CoreExport void ClearFlagBitInAllAnimatables ( int  index ) [static]

Clears the specified flag bit in all Animatables.

Parameters:
index The flag bit index to clear
static CoreExport void EnumerateAllAnimatables ( EnumAnimList enumProcObject ) [static]

Enumerator to enumerate across all animatables.

Implemented by the System. The Animatables are enumerated in order of creation. Use Animatable::EnumAnimTree when the enumerating the Animatables based on their hierarchy is required. EnumerateAllAnimatables is designed to be safe with recursive calls to EnumerateAllAnimatables, and is designed to be safe when Animatables are added/deleted during an enumeration.

Parameters:
enumProcObject - The callback object called for each animatable.
virtual void FreeCaches ( ) [inline, virtual]
Remarks:
This is called to delete any item that can be rebuilt. For example, the procedural sphere object has a mesh that it caches. It could call Mesh::FreeAll() on the mesh from this method. This will free the vertex/face/uv arrays. If the sphere is ever evaluated again it can just rebuild the mesh. If an object (like a sphere) has modifiers applied to it, and those modifiers are not animated, then the result of the pipeline is cached in the node. So there is no reason for the sphere to also have a cache of its representation. Therefore when this method is called, the sphere can free the data of the mesh.
Default Implementation:
{}

Reimplemented in LinearShape, PatchObject, PolyObject, SimpleObject, SimpleWSMObject, SimpleShape, SimpleSpline, SplineShape, TriObject, MSCustAttrib, MSSimpleObjectXtnd, MSSimpleManipulatorXtnd, MSPluginModifier, MSModifierXtnd, MSPluginSimpleMod, MSSimpleModXtnd, MSPluginTexmap, MSTexmapXtnd, MSPluginMtl, MSMtlXtnd, MSPluginTrackViewUtility, MSPluginObject< ShapeObject >, MSPluginObject< HelperObject >, MSPluginObject< GeomObject >, MSPluginObject< GenCamera >, MSPluginObject< GenLight >, MSObjectXtnd< GenCamera, MSPluginCamera >, MSObjectXtnd< HelperObject, MSPluginHelper >, MSObjectXtnd< GeomObject, MSPluginGeomObject >, MSObjectXtnd< ShapeObject, MSPluginShape >, MSObjectXtnd< GenLight, MSPluginLight >, MSPluginSpecialFX< Effect8 >, MSPluginSpecialFX< Atmospheric >, MSSpecialFXXtnd< Effect, MSPluginEffect >, and MSSpecialFXXtnd< Atmospheric, MSPluginAtmos >.

{}
virtual void BeginEditParams ( IObjParam ip,
ULONG  flags,
Animatable prev = NULL 
) [inline, virtual]
Remarks:
This method is called by the system when the user may edit the item's (object, modifier, controller, etc.) parameters.
Parameters:
ip Interface pointer. The developer can use it to call methods such as AddRollupPage(). Note that this pointer is only valid between BeginEditParams() and EndEditParams(). It should not be used outside this interval.
flags Describe which branch of the command panel or dialog the item is being edited in. The following are possible values:

BEGIN_EDIT_CREATE
Indicates an item is being edited in the create branch.

BEGIN_EDIT_MOTION
Indicates a controller is being edited in the motion branch.

BEGIN_EDIT_HIERARCHY
Indicates a controller is being edited in the Pivot subtask of the hierarchy branch.

BEGIN_EDIT_IK
Indicates a controller is being edited in the IK subtask of the hierarchy branch.

BEGIN_EDIT_LINKINFO
Indicates a controller is being edited in the Link Info subtask of the hierarchy branch.

prev Pointer to an Animatable object. This parameter may be used in the motion and hierarchy branches of the command panel. This pointer allows a plug-in to look at the ClassID of the previous item that was being edited, and if it is the same as this item, to not replace the entire UI in the command panel, but simply update the values displayed in the UI fields. This prevents the UI from 'flickering' when the current item begins its edit. For example, if you are in the motion branch and are looking at an item's PRS controller values, and then select another item that is displayed with a PRS controller, the UI will not change - only the values displayed in the fields will change. If however you selected a target camera that has a lookat controller (not a PRS controller) the UI will change because a different set of parameters need to be displayed. Note that for items that are edited in the modifier branch this field can be ignored.

Reimplemented in SphereGizmoObject, CylGizmoObject, BoxGizmoObject, IProjectionModType, GizmoClass, SimpleManipulator, IMultiPassCameraEffect, ShapeObject, PatchObject, SimpleMod, SimpleWSMMod, SimpleObject, SimpleWSMObject, SimpleOSMToWSMObject, SimpleParticle, SimpleShape, SimpleSpline, SplineShape, MSCustAttrib, MSPluginSimpleObject, MSSimpleObjectXtnd, MSPluginSimpleManipulator, MSSimpleManipulatorXtnd, MSPluginModifier, MSModifierXtnd, MSPluginSimpleMod, MSSimpleModXtnd, PFSimpleAction, MSPluginObject< ShapeObject >, MSPluginObject< HelperObject >, MSPluginObject< GeomObject >, MSPluginObject< GenCamera >, MSPluginObject< GenLight >, MSObjectXtnd< GenCamera, MSPluginCamera >, MSObjectXtnd< HelperObject, MSPluginHelper >, MSObjectXtnd< GeomObject, MSPluginGeomObject >, MSObjectXtnd< ShapeObject, MSPluginShape >, and MSObjectXtnd< GenLight, MSPluginLight >.

{} 
virtual void EndEditParams ( IObjParam ip,
ULONG  flags,
Animatable next = NULL 
) [inline, virtual]
Remarks:
This method is called when the user is finished editing an objects parameters. The system passes a flag into the EndEditParams() method to indicate if the rollup page should be removed. If this flag is TRUE, the plug-in must un-register the rollup page, and delete it from the panel.
Parameters:
ip An interface pointer. The developer may use the interface pointer to call methods such as DeleteRollupPage().

flags The following flag may be set:

END_EDIT_REMOVEUI
If TRUE, the item's user interface should be removed.

next Animatable pointer. Can be used in the motion and hierarchy branches of the command panel. It allows a plug-in to look at the ClassID of the next item that was being edited, and if it is the same as this item, to not replace the entire UI in the command panel. Note that for items that are edited in the modifier branch this field can be ignored.

Reimplemented in SphereGizmoObject, CylGizmoObject, BoxGizmoObject, IProjectionModType, GizmoClass, SimpleManipulator, IMultiPassCameraEffect, ShapeObject, PatchObject, SimpleMod, SimpleWSMMod, SimpleObject, SimpleWSMObject, SimpleOSMToWSMObject, SimpleParticle, SimpleShape, SimpleSpline, SplineShape, MSCustAttrib, MSPluginSimpleObject, MSSimpleObjectXtnd, MSPluginSimpleManipulator, MSSimpleManipulatorXtnd, MSPluginModifier, MSModifierXtnd, MSPluginSimpleMod, MSSimpleModXtnd, PFSimpleAction, MSPluginObject< ShapeObject >, MSPluginObject< HelperObject >, MSPluginObject< GeomObject >, MSPluginObject< GenCamera >, MSPluginObject< GenLight >, MSObjectXtnd< GenCamera, MSPluginCamera >, MSObjectXtnd< HelperObject, MSPluginHelper >, MSObjectXtnd< GeomObject, MSPluginGeomObject >, MSObjectXtnd< ShapeObject, MSPluginShape >, and MSObjectXtnd< GenLight, MSPluginLight >.

{} 
virtual CoreExport void* GetInterface ( ULONG  id ) [virtual]
Remarks:
This method provides a mechanism for extending the class in the future. In 3ds Max 4.0 there are new interfaces that are accessed by passing an id to this method and it will respond by returning the corresponding interface pointer.

This method has been used however for a different purpose. It currently is used to determine if an object is of a particular class. With controllers for example, there is one base class Control, however there are many super classes (CTRL_FLOAT_CLASS_ID, CTRL_SCALE_CLASS_ID, etc.). If you wanted to find out if a given Animatable was a controller you would need to compare its SuperClassID to all the known types and only if it wasn't one of the known types could you be sure it wasn't a controller. Having to do this is inconvenient for a developer.

Instead the Control class implements this method. It looks at the id, and if it matches a predefined constant I_CONTROL, it returns its this pointer. In this way, given any Animatable, it is easy to find out if it is a controller by simply asking for the control interface. There is a macro that does this:

#define GetControlInterface(anim)

((Control*)anim->GetInterface(I_CONTROL))

A plug-in developer may use this macro as follows:

Control *c = GetControlInterface(anim);

This will either be NULL or a pointer to a valid controller.

Note: Plug-in defined interfaces should be greater than the following value:

#define I_USERINTERFACE 0x0000ffff

If a plug-in implements this method for its own purposes, it would, in general, switch on the id and if it is not aware of the id it would call this method on the base class. Otherwise it could respond to the id as it needed. See the sample code below for the how the Control class implements this method.
Parameters:
id The id of the interface.
Default Implementation:
{ return NULL; }
Sample Code:
The following is the Control class implementation of this method. It looks at the id passed, and if it matches I_CONTROL it returns its this pointer. Otherwise it calls the base class method.

        void* Control::GetInterface(ULONG id)
        {
            if (id==I_CONTROL) {
                return this;
            }
            else {
                return Animatable::GetInterface(id);
            }
        }

Reimplemented in EaseCurveList, MultCurveList, Control, LockableStdControl, LockableControl, MtlBase, IDerivedObject, BaseObject, Object, LightObject, ShapeObject, WSMObject, PatchObject, PodObj, ReferenceMaker, ReferenceTarget, IRenderElement, MaxRenderElement, MaxBakeElement, MaxBakeElement8, MaxBakeElement10, Effect8, Shader, SimpleObject, SimpleParticle, SplineShape, TriObject, MSCustAttrib, MSPluginSimpleObject, MSSimpleObjectXtnd, MSPluginSimpleManipulator, MSSimpleManipulatorXtnd, MSPluginModifier, MSModifierXtnd, MSPluginSimpleMod, MSSimpleModXtnd, MSPluginTexmap, MSTexmapXtnd, MSPluginMtl, MSMtlXtnd, MSPluginTrackViewUtility, MSPluginObject< ShapeObject >, MSPluginObject< HelperObject >, MSPluginObject< GeomObject >, MSPluginObject< GenCamera >, MSPluginObject< GenLight >, MSObjectXtnd< GenCamera, MSPluginCamera >, MSObjectXtnd< HelperObject, MSPluginHelper >, MSObjectXtnd< GeomObject, MSPluginGeomObject >, MSObjectXtnd< ShapeObject, MSPluginShape >, MSObjectXtnd< GenLight, MSPluginLight >, MSPluginSpecialFX< Effect8 >, MSPluginSpecialFX< Atmospheric >, MSSpecialFXXtnd< Effect, MSPluginEffect >, and MSSpecialFXXtnd< Atmospheric, MSPluginAtmos >.

virtual CoreExport void ReleaseInterface ( ULONG  id,
void *  i 
) [virtual]
Remarks:
This method is not currently used. It is reserved for future use. Its purpose is for releasing an interface created with GetInterface().

Reimplemented in IRenderElement, MaxRenderElement, MaxBakeElement, and TriObject.

virtual CoreExport BaseInterface* GetInterface ( Interface_ID  id ) [virtual]
Remarks:
Returns a pointer to the Base Interface for the interface ID passed. The default implementation of this method retrieves this information from the ClassDesc for the plug-in.

Any future object-based interfaces should be allocated unique Interface_IDs (you can use Gencid.exe for this) and made available through this call.

The default implementation of GetInterface(Interface_ID) looks up a standalone interface of the given ID on the object's ClassDesc. This gives access to standalone interfaces via any of a plug-in's objects, without having to dig around for the ClassDesc, so you should fall back to calling the default implementation if you don't recognize an ID in your implementation of GetInterface(Interface_ID).
Parameters:
id The unique ID of the interface to get. See Class Interface_ID.

Reimplemented from InterfaceServer.

Reimplemented in MtlBase, INode, SimpleManipulator, BaseObject, Object, LightObject, ShapeObject, ReferenceMaker, ReferenceTarget, Effect8, Shader, SimpleObject, TriObject, MSMtlXtnd, MSPluginObject< ShapeObject >, MSPluginObject< HelperObject >, MSPluginObject< GeomObject >, MSPluginObject< GenCamera >, MSPluginObject< GenLight >, MSObjectXtnd< GenCamera, MSPluginCamera >, MSObjectXtnd< HelperObject, MSPluginHelper >, MSObjectXtnd< GeomObject, MSPluginGeomObject >, MSObjectXtnd< ShapeObject, MSPluginShape >, MSObjectXtnd< GenLight, MSPluginLight >, MSPluginSpecialFX< Effect8 >, MSPluginSpecialFX< Atmospheric >, MSSpecialFXXtnd< Effect, MSPluginEffect >, and MSSpecialFXXtnd< Atmospheric, MSPluginAtmos >.

virtual CoreExport int SetProperty ( ULONG  id,
void *  data 
) [virtual]
Remarks:
This is a general method for adding properties, when defining a new Interface would be too cumbersome. This method provides another way to extend the class without actually adding any methods. Sample code that implements this method to add properties to the property list is in /MAXSDK/SAMPLES/CONTROLLERS/PATHCTRL.CPP. See below.
Parameters:
id The id for the property.
data A pointer to the data to store.
Returns:
Nonzero if the property was set; otherwise zero.
Default Implementation:
{ return 0; }
Sample Code:
This code is from /MAXSDK/SAMPLES/CONTROLLERS/PATHCTRL.CPP. It is used to save the inverse kinematics user interface parameters of the path controller. It saves the property data on the aprops property list. See the Data Members at the beginning of Animatable for details on aprops.

        int PathPosition::SetProperty(ULONG id, void *data)
        {
            if (id==PROPID_JOINTPARAMS) {
                if (!data) {
                    int index = aprops.FindProperty(id);
                    if (index>=0) {
                        aprops.Delete(index,1);
                    }
                }
                else {
                    JointParamsPath *jp = (JointParamsPath*)GetProperty(id);
                    if (jp) {
                        *jp = *((JointParamsPath*)data);
                        delete (JointParamsPath*)data;
                    }
                    else {
                        aprops.Append(1,(AnimProperty**)&data);
                    }
                }
                return 1;
            } else
            if (id==PROPID_INTERPUI) {
                if (!data) {
                    int index = aprops.FindProperty(id);
                    if (index>=0) {
                        aprops.Delete(index,1);
                    }
                }
                else {
                    InterpCtrlUI *ui = (InterpCtrlUI*)GetProperty(id);
                    if (ui) {
                        *ui = *((InterpCtrlUI*)data);
                    }
                    else {
                        aprops.Append(1,(AnimProperty**)&data);
                    }
                }
                return 1;
            }
            else {
                return Animatable::SetProperty(id,data);
            }
        }

Reimplemented in MtlBase, ShapeObject, and MSMtlXtnd.

virtual CoreExport void* GetProperty ( ULONG  id ) [virtual]
Remarks:
This method is used to retrieve a property specified by the id passed (as stored by SetProperty()).

Note for 3ds Max version 1.1:

Two new property IDs have been added:

PROPID_CLEARCACHES: When passed to a texture map or material, the material should dump any of its caches. For example, the bitmap texture responds to this by freeing the bitmap from memory. For sample code see /MAXSDK/SAMPLES/MATERIALS/BMTEX.CPP.

PROPID_HAS_WSM: When passed to an INode, will return TRUE if the node has World Space Modifiers applied to it or FALSE if it does not. For sample code see /MAXSDK/SAMPLES/IMPEXP/3DSEXP.CPP.

Note for 3ds Max version 1.2:

A new id has been created and assigned the constant:

#define PROPID_EVAL_STEPSIZE_BUG_FIXED 0x1000.

This only effects the evaluation of objects when rendering them using motion blur. Motion blur works by evaluating the object numerous times (at fractions of a frame apart) and combining these images by blending them together.

Originally, 3ds Max would make these evaluations in reverse order within a sub-frame -- from the last one, to the second to the last one, back to the first one. There is a problem with this for certain plug-ins that need to compute their state from time 0 forward. For these objects, the backwards approach may be too computationally intensive.

Both the forward and backward approaches exist in 3ds Max and the developer may choose which method to use. 3ds Max interrogates the object to see how it should handle the evaluation process -- either going backwards or forwards. It calls this method with id set to the constant PROPID_EVAL_STEPSIZE_BUG_FIXED. If a plug-in implements this method to return nonzero, it means the plug-in works correctly using forward stepping, and 3ds Max will use that approach. If a plug-in does not implement this method and handle the id of PROPID_EVAL_STEPSIZE_BUG_FIXED it will return the default value of zero. This means the older method of backwards evaluation will be used.

Therefore, a plug-in object that wants to handle motion blur using forward stepping should implement this method, and if passed an id of PROPID_EVAL_STEPSIZE_BUG_FIXED, should return nonzero.
Parameters:
id The id of the property to retrieve.
Default Implementation:
{ return NULL; }
Sample Code:
This code is from /MAXSDK/SAMPLES/CONTROLLERS/PATHCTRL.CPP. It is used to restore the inverse kinematics user interface parameters of the path controller. It retrieves the property data on the aprops property list. See the Data Members at the beginning of Animatable for details on aprops.

        void* PathPosition::GetProperty(ULONG id)
        {
            if (id==PROPID_INTERPUI || id==PROPID_JOINTPARAMS) {
                int index = aprops.FindProperty(id);
                if (index>=0) {
                    return aprops[index];
                }
                else {
                    return NULL;
                }
            }
            else {
                return Animatable::GetProperty(id);
            }
        }

Reimplemented in MtlBase, ShapeObject, and MSMtlXtnd.

virtual int NumSubs ( ) [inline, virtual]
virtual Animatable* SubAnim ( int  i ) [inline, virtual]
Remarks:
This method returns a pointer to the 'i-th' sub-anim. If a plug-in is using a parameter block to manage all its parameters it should just return a pointer to the parameter block itself from this method. This method may return NULL so developers need to check the return value before calling other sub anim methods (such as SubAnimName()).
Parameters:
i This is the index of the sub-anim to return.
Default Implementation:
{ return NULL };

Reimplemented in EaseCurveList, MultCurveList, Control, MtlLib, MtlBaseLib, GizmoClass, SimpleManipulator, ShapeObject, PatchObject, SimpleMod, SimpleMod2, SimpleWSMMod, SimpleWSMMod2, SimpleObject, SimpleWSMObject, SimpleOSMToWSMObject, SimpleParticle, SimpleShape, SimpleSpline, SplineShape, MSCustAttrib, MSPluginSimpleObject, MSSimpleObjectXtnd, MSPluginSimpleManipulator, MSSimpleManipulatorXtnd, MSPluginModifier, MSModifierXtnd, MSPluginSimpleMod, MSSimpleModXtnd, MSPluginTexmap, MSTexmapXtnd, MSPluginMtl, MSMtlXtnd, MSPluginTrackViewUtility, MSPluginObject< ShapeObject >, MSPluginObject< HelperObject >, MSPluginObject< GeomObject >, MSPluginObject< GenCamera >, MSPluginObject< GenLight >, MSObjectXtnd< GenCamera, MSPluginCamera >, MSObjectXtnd< HelperObject, MSPluginHelper >, MSObjectXtnd< GeomObject, MSPluginGeomObject >, MSObjectXtnd< ShapeObject, MSPluginShape >, MSObjectXtnd< GenLight, MSPluginLight >, MSPluginSpecialFX< Effect8 >, MSPluginSpecialFX< Atmospheric >, MSSpecialFXXtnd< Effect, MSPluginEffect >, and MSSpecialFXXtnd< Atmospheric, MSPluginAtmos >.

{ return NULL; }  
virtual CoreExport MSTR SubAnimName ( int  i ) [virtual]
Remarks:
This method returns the name of the 'i-th' sub-anim to appear in track view. The system has no idea what name to assign to the sub-anim (it only knows it by the virtual array index), so this method is called to retrieve the name to display. Developer need to make sure the 'i-th' SubAnim() is non-NULL or this method will fail.
Parameters:
i The index of the parameter name to return
Returns:
The name of the 'i-th' parameter.

Reimplemented in EaseCurveList, MultCurveList, Control, MtlLib, MtlBaseLib, GizmoClass, SimpleManipulator, ShapeObject, PatchObject, SimpleMod, SimpleWSMMod, SimpleObject, SimpleWSMObject, SimpleOSMToWSMObject, SimpleParticle, SimpleShape, SimpleSpline, SplineShape, MSCustAttrib, MSPluginSimpleObject, MSSimpleObjectXtnd, MSPluginSimpleManipulator, MSSimpleManipulatorXtnd, MSPluginModifier, MSModifierXtnd, MSPluginSimpleMod, MSSimpleModXtnd, MSPluginTexmap, MSTexmapXtnd, MSPluginMtl, MSMtlXtnd, MSPluginTrackViewUtility, MSPluginObject< ShapeObject >, MSPluginObject< HelperObject >, MSPluginObject< GeomObject >, MSPluginObject< GenCamera >, MSPluginObject< GenLight >, MSObjectXtnd< GenCamera, MSPluginCamera >, MSObjectXtnd< HelperObject, MSPluginHelper >, MSObjectXtnd< GeomObject, MSPluginGeomObject >, MSObjectXtnd< ShapeObject, MSPluginShape >, MSObjectXtnd< GenLight, MSPluginLight >, MSPluginSpecialFX< Effect8 >, MSPluginSpecialFX< Atmospheric >, MSSpecialFXXtnd< Effect, MSPluginEffect >, and MSSpecialFXXtnd< Atmospheric, MSPluginAtmos >.

virtual BOOL BypassTreeView ( ) [inline, virtual]
Remarks:
This method indicates to the system that this anim should not appear in the Track View. Note: Track View was formally referred to as Tree View. This is what parameter blocks do for example. They don't show up in track view, just their sub-anims do. This prevents the extra level of the parameter block from appearing.
Returns:
Return TRUE to not appear in the Track View. Note that if you return TRUE your children will appear in the track view regardless.
Default Implementation:
{ return FALSE; }

Reimplemented in EaseCurveList, MultCurveList, and LinearShape.

{ return FALSE; } 
virtual BOOL BypassTrackBar ( ) [inline, virtual]
Remarks:
This method indicates to the system that this anim should not appear in the Track Bar. The anim won't show up in the Track Bar, just its sub-anims will. This function is similar to BypassTreeView(), but refers to the Track Bar instead of the Track View.
Returns:
Return TRUE to not appear in the Track Bar. Note that if you return TRUE your children will appear in the Track Bar regardless.
Default Implementation:
{ return BypassTreeView(); }
{ return BypassTreeView(); } 
virtual BOOL BypassPropertyLevel ( ) [inline, virtual]
Remarks:
Use this method in order to cause parameters in this Animatable (as a sub-anim) to appear to reside at the level of the parent Animatable in the scripter. Return TRUE and this Animatable won't appear as a property in the scripter however it's sub-anims children will. The default implementation returns FALSE indicating it will appear normally.
Default Implementation:
{ return FALSE; }

Reimplemented in BaseShader, and ShadowType.

{ return FALSE; } 
virtual BOOL InvisibleProperty ( ) [inline, virtual]
Remarks:
This method controls the visibility of this Animatable and all of it sub-anims to appear as properties in the scripter. Return TRUE and it won't nor will it's sub-anims. Returning FALSE (the default implementation) causes this Animatable and it's sub-anims to appear as normal.
Default Implementation:
{ return FALSE; }
{ return FALSE; } 
virtual BOOL AssignController ( Animatable control,
int  subAnim 
) [inline, virtual]
Remarks:
This method is called to assign the controller to the sub-anim whose index is passed.
Parameters:
control The controller to assign.
subAnim The index of the sub-anim to assign the controller to.
Default Implementation:
{ return FALSE; }
Returns:
Returns TRUE if the controller was assigned; otherwise FALSE.

Reimplemented in EaseCurveList, MultCurveList, PatchObject, SimpleMod, and SplineShape.

{ return FALSE; }
virtual BOOL CanAssignController ( int  subAnim ) [inline, virtual]

Return true if we can reassign the subanim specified.

Implement this function to return false if we wish to prevent any subanim from being replaced. If this method returns false for any id, that subanim will not be able to be re-assigned via the UI or MaxScript controls. Note that this will not prevent re-assigning in C++ in any way (via the ReplaceReference or AssignController functions).

Parameters:
subAnum - The ID of the SubAnim to check.
Returns:
TRUE if it is legal to assign a new Animatable to the specified SubAnim
{ return TRUE; }
virtual BOOL CanDeleteSubAnim ( int  i ) [inline, virtual]
Remarks:
Returns TRUE if the specified sub-anim controller can be deleted; otherwise FALSE.

A new "Delete Controller" button has been added to the Track View toolbar that is enabled when one or more delete-able tracks are selected. This method allows a plug-in to indicate to the Track View that one or more of its sub-controllers are delete-able. This provides a way to allow the user to delete node sub-controllers such as the visibility track, "Image Motion Blur Multiplier", "Object Motion Blur On/Off", etc. If the user selects one of the above-mentioned tracks in the Track View the "Delete Controller" button will become available.
Parameters:
i The zero based index of the sub-anim.
Default Implementation:
{return FALSE;}
{ return FALSE; }
virtual void DeleteSubAnim ( int  i ) [inline, virtual]
Remarks:
This method is called to delete the specified sub-anim controller. See the remarks in CanDeleteSubAnim() above.
Parameters:
i The zero based index of the sub-anim.
Default Implementation:
{}
{}
virtual DWORD GetSubAnimCurveColor ( int  subNum ) [inline, virtual]
Remarks:
Return the suggested color to draw a sub-anim's function curve. For example, the independent X, Y, Z position controller implements this method to return the suggested color for each of it's sub-controllers. The Euler Angle Controller uses these so its 3 sub-controllers are drawn in different colors.
Parameters:
subNum The index of the sub-anim.
Returns:
One of the following values:

PAINTCURVE_GENCOLOR

PAINTCURVE_XCOLOR

PAINTCURVE_YCOLOR

PAINTCURVE_ZCOLOR
Default Implementation:
{return PAINTCURVE_GENCOLOR;}
{ return PAINTCURVE_GENCOLOR; }
virtual int SubNumToRefNum ( int  subNum ) [inline, virtual]
Remarks:
This method is used for copying and pasting in the track view. It converts an anim index to a reference index or returns -1 if there is no correspondence. If a client does not wish an anim to be copied or pasted then it can return -1 even if there is a corresponding reference num.
Parameters:
subNum The anim index to return the corresponding reference index of.
Default Implementation:
{ return -1}
Returns:
The reference index corresponding to the anim index passed. Return -1 if there is no correspondence.

Reimplemented in EaseCurveList, MultCurveList, GizmoClass, PatchObject, SimpleMod, and SplineShape.

{ return -1; }
virtual BOOL CanCopyAnim ( ) [inline, virtual]
Remarks:
In addition to SubNumToRefNum(), if an anim doesn't want to be copied (via Track View or the Edit Modifier Stack 'Copy' button) it can return FALSE from this method, otherwise it can use the default implementation to return TRUE.
Default Implementation:
{return TRUE;}

Reimplemented in MSCustAttrib.

{ return TRUE; }
virtual BOOL CanMakeUnique ( ) [inline, virtual]
Remarks:
An anim can implement this method to return FALSE to prohibit make unique from being applied to it.
Default Implementation:
{return TRUE;}
{ return TRUE; }
virtual int NumChildren ( ) [inline, virtual]
Remarks:
This method is used internally.
{ return 0; }   
virtual Animatable* ChildAnim ( int  i ) [inline, virtual]
Remarks:
This method is used internally.
{ return NULL; } 
virtual CoreExport MSTR NodeName ( ) [virtual]
Remarks:
This method is used internally.
CoreExport int EnumAnimTree ( AnimEnum animEnum,
Animatable client,
int  subNum 
)
Remarks:
Implemented by the System.

This method recursively enumerates the Animatable hierarchy. It will call the AnimEnum::proc() method passing it the anim, that anim's parent (the client), and the sub-anim index of that anim to the client, for every anim and sub-anim in the hierarchy.
Parameters:
animEnum The callback object, called once for each sub anim from 0 to subNum-1. See Class AnimEnum.

client The client anim. This is the Animatalbe whose sub-anims are enumerated.

subNum The sub-anim index of the client at which to begin the enumeration. Pass 0 to do them all.
Returns:
One of the following values:

ANIM_ENUM_PROCEED

ANIM_ENUM_STOP

ANIM_ENUM_ABORT
CoreExport int HasSubElements ( int  type = 0 )
Remarks:
Implemented by the System.

This method is used to determine if this Animatable has children or sub-anims. The type passed indicates what is tested.
Parameters:
type One of the following values:

0: Test for node children.

1: Test for sub-anims.
Returns:
Nonzero if the item has children or sub-anims; otherwise zero.
virtual int RenderBegin ( TimeValue  t,
ULONG  flags = 0 
) [inline, virtual]
Remarks:
This method is called once at the beginning of each render. A plug-in can use this method to do any work required before a rendering actually begins. For example, some of the standard 3ds Max plug-ins use this method to toggle between their 'viewport' state and the 'rendering' state. The Optimize modifier has two settings, one for the viewports and one for the rendering. When this method is called it then performs the switch from viewport to renderer.
Parameters:
t The time that the render is beginning.
flags The following flag value can be checked:

RENDERBEGIN_IN_MEDIT
Indicates that the render is occurring in the Material Editor.
Returns:
Nonzero if the method is implemented; otherwise 0.
Default Implementation:
{ return 0; }
{ return 0; }
virtual int RenderEnd ( TimeValue  t ) [inline, virtual]
Remarks:
This method is called once at the end of each render.
Parameters:
t The time of the last rendered frame.
Returns:
Nonzero if the method is implemented; otherwise 0.
Default Implementation:
{ return 0; }
{ return 0; }
virtual void EditTrack ( ) [inline, virtual]
virtual int NumKeys ( ) [inline, virtual]
Remarks:
This method returns the number of keys managed by the plug-in, or NOT_KEYFRAMEABLE if it does not work with keys.
Default Implementation:
{return NOT_KEYFRAMEABLE;}

Reimplemented in DefNoteTrack.

{ return NOT_KEYFRAMEABLE; }
virtual TimeValue GetKeyTime ( int  index ) [inline, virtual]
Remarks:
This method returns the time of the key specified by index.
Parameters:
index Specifies the key whose time should be returned.
Default Implementation:
{return 0;}

Reimplemented in DefNoteTrack.

{ return 0; }
virtual int GetKeyIndex ( TimeValue  t ) [inline, virtual]
Remarks:
Returns the index of the key at time t or -1 if no key is found at the specified time.
Parameters:
t Specifies the time at which to retrieve the key index.
Default Implementation:
{return -1;}
{ return -1; }
virtual BOOL GetNextKeyTime ( TimeValue  t,
DWORD  flags,
TimeValue &  nt 
) [inline, virtual]
Remarks:
An item should implement this method to allow the Key Mode button in 3ds Max's UI to function properly. If Key Mode is set, and the user clicks the Previous Key or Next Key button, this method will be called to retrieve the next or previous key.
Parameters:
t The current time (frame slider position).
flags One or more of the following values:

NEXTKEY_LEFT
Search to the left.

NEXTKEY_RIGHT
Search to the right.

NEXTKEY_POS
Next position key.

NEXTKEY_ROT
Next rotation key.

NEXTKEY_SCALE
Next scale key.
nt The time of the previous or next key is returned here.
Returns:
TRUE if the key time was retrieved; otherwise FALSE.
Default Implementation:
{ return FALSE;}
{ return FALSE; }
virtual void CopyKeysFromTime ( TimeValue  src,
TimeValue  dst,
DWORD  flags 
) [inline, virtual]
Remarks:
This method is called to copy or interpolate a new key from a source time to a destination time.
Parameters:
src The source time.
dst The destination time.
flags These filter flags are passed to a transform (Matrix3) controller. The TM can decide what to do with them. They have obvious meaning for the PRS controller. One or more of the following values:

COPYKEY_POS
Copy the position key.

COPYKEY_ROT
Copy the rotation key.

COPYKEY_SCALE Copy the scale key.
{} 
virtual void DeleteKeyAtTime ( TimeValue  t ) [inline, virtual]
Remarks:
This method is called to delete the key at the specified time.
Parameters:
t Specifies the time to delete the key.
Default Implementation:
{}
{}
virtual BOOL IsKeyAtTime ( TimeValue  t,
DWORD  flags 
) [inline, virtual]
Remarks:
Returns TRUE if there is a key of the specified type at the specified time; otherwise FALSE.
Parameters:
t Specifies the time to check for a key.
flags One or more of the following values:

KEYAT_POSITION
KEYAT_ROTATION
KEYAT_SCALE
Default Implementation:
{return FALSE;}
{ return FALSE; }
virtual int GetKeyTimes ( Tab< TimeValue > &  times,
Interval  range,
DWORD  flags 
) [inline, virtual]
Remarks:
This method is called to build a table of time values, one time for each key within the interval passed. The plug-in should load up the table passed with the time of each key present over the specified time range.
Parameters:
times The table of time values to build. See Class Tab.

range The range of time over which to retrieve the key times. See Class Interval.

flags One of the following values:

KEYAT_POSITION
Return for Position keys only.

KEYAT_ROTATION
Return for Rotation keys only.

KEYAT_SCALE
Return for Scale keys only.
Returns:
The plug-in should return an offset so the system can access the keys using an index. Thus it should return the number of keys skipped because their times were before range.Start(). For example, say the first keyframe in the interval passed was actually the third key overall. The plug-in should return 2 (two keys preceded the first one stored). In this way, the system can access the key as the i-th key in the table plus 2.
Default Implementation:
{return 0;}
{ return 0; }       
virtual int GetKeySelState ( BitArray sel,
Interval  range,
DWORD  flags 
) [inline, virtual]
Remarks:
When this method is called, the plug-in should update the BitArray sel to indicate if its keys present in the interval passed are selected or deselected.
Parameters:
sel The bit array to update, one bit for each key within the interval range. If the key is selected, the corresponding bit should be 1, otherwise it should be 0. See Class BitArray.
range The range of time over which to retrieve the key selected state. See Class Interval.
flags One or more of the following values:

KEYAT_POSITION
Return for Position keys only.

KEYAT_ROTATION
Return for Rotation keys only.

KEYAT_SCALE Return for Scale keys only.
Note:
If the flags are passed as 0, use ALL keys within the range.
Returns:
The number of keys skipped because their times were before range.Start().
Default Implementation:
{return 0;}
{ return 0; }
CoreExport void OpenTreeEntry ( int  type,
DWORD  tv 
)
Remarks:
Implemented by the System.

This method may be called to open the specified Track View entry. The type parameter indicates if the child tree or the sub-anim (parameter) tree is opened.
Parameters:
type This value may be either 0 or 1. If 0, the child tree is opened. If 1, the sub-anim tree is opened.
tv This parameter specifies which Track View(s) are altered, one bit for each Track View. The open/closed state is independent for each Track View. The low-order 16 bits represent the 16 track views.
CoreExport void CloseTreeEntry ( int  type,
DWORD  tv 
)
Remarks:
Implemented by the System.

This method may be called to close the specified Track View entry. The type parameter indicates if the child tree or the sub-anim tree is closed.
Parameters:
type This value may be either 0 or 1. If 0, the child tree is closed. If 1, the sub-anim (parameter) tree is closed.
tv This parameter specifies which Track View(s) are altered, one bit for each Track View. The low-order 16 bits represent the 16 track views.
CoreExport int IsTreeEntryOpen ( int  type,
DWORD  tv 
)
Remarks:
Implemented by the System.

Returns nonzero if the specified tree is opened for this item, and zero if it is closed.
Parameters:
type This value may be either 0 or 1. If 0, the child tree is checked. If 1, the sub-anim (parameter) tree is checked.
tv This parameter is available in release 2.0 and later only. Specifies which Track View to check -- one bit per Track View.
CoreExport BOOL GetSelInTrackView ( DWORD  tv )
Remarks:
This method is available in release 2.0 and later only.

Implemented by the System.

Returns TRUE if this animatable is selected in the specified Track View; FALSE if not selected.
Parameters:
tv Specifies which Track View to check -- one bit per Track View.
CoreExport void SetSelInTrackView ( DWORD  tv,
BOOL  sel 
)
Remarks:
This method is available in release 2.0 and later only.

Implemented by the System.

Sets the state of this animatable to selected or deselected in the specified Track View.
Parameters:
tv Specifies which Track View to check -- one bit per Track View.
sel TRUE to select; FALSE to deselect.
CoreExport BOOL InTrackViewSelSet ( int  which )
Remarks:
This method is available in release 2.0 and later only.

Implemented by the System.

Returns TRUE if this animatable is in the specified selection set; otherwise FALSE.
Parameters:
which Indicates the Track View selection set to check -- this should be >=0 and <MAX_TRACKVIEW_SELSETS
CoreExport void SetTrackViewSelSet ( int  which,
BOOL  inOut 
)
Remarks:
This method is available in release 2.0 and later only.

Implemented by the System.

Sets the selected or deselected state of this animatable in the specified selection set.
Parameters:
which Indicates the Track View selection set to modify -- this should be >=0 and <MAX_TRACKVIEW_SELSETS

inOut TRUE for in; FALSE for out.
virtual CoreExport Interval GetTimeRange ( DWORD  flags ) [virtual]
Remarks:
Implemented by the System.

Returns an interval representing the tracks time range, based on the flags passed.
Parameters:
flags One or more of the following values:

TIMERANGE_SELONLY
The bounding interval of selected keys only.

TIMERANGE_ALL
Whatever the channel's time range is - usually the bounding interval of all keys.

TIMERANGE_CHILDNODES
The node's time range should include its child nodes.

TIMERANGE_CHILDANIMS
A animatable's child anim ranges should be included.
Returns:
An interval representing the tracks time range.

Reimplemented in DefNoteTrack.

virtual void EditTimeRange ( Interval  range,
DWORD  flags 
) [inline, virtual]
Remarks:
This method is called to change the range of the anim (usually a controller) to the given range. This is the range that is used to compute the Out of Range Types. For example, this method may be called when the user is working in Position Range mode in the Track View.

Keyframe controllers generally support this method. Other controllers may or may not support this method. For example, a procedural controller may want to maintain a range upon which the animation is based. The user may then move the range bar around to move the procedural animation around.

The range passed is the range used to compute the Out of Range Types. This may be used for example with the Loop ORT to extend the range, either past the last key or before the first key, so there is some time to loop back to the start.

The 3ds Max keyframe controllers maintain an interval that is their range. It is normally defined to be the first key to the last key. If the user goes into Position Range mode and moves the range around, this method is called. The keyframe controllers set a flag to indicate that the range is no longer linked to the first key or the last key. Then the range is stored in the interval, and this is considered the 'in range' portion of the controller. If time is evaluated outside of this range it applies the ORTs to determine the value.
Parameters:
range The new range for the anim.

flags EDITRANGE_LINKTOKEYS
If this flag is set, the controller should re-establish the link between the start and end keys and its range. This is passed if the user presses the link to keys button in Track View. Thus, if one of the ends of the interval is at a key, link it to the key so that if the key moves, the interval moves.
Default Implementation:
{}
{};
virtual void DeleteTime ( Interval  iv,
DWORD  flags 
) [inline, virtual]
Remarks:
This method is called to delete the specified interval of time (or the keys within the interval).
Parameters:
iv The interval of time to delete.
flags One or more of the following values:

TIME_INCLEFT
Include the left endpoint.

TIME_INCRIGHT
Include the right endpoint.

TIME_NOSLIDE
Delete any keys in the interval but don't actually remove the block of time.
Default Implementation:
{}

Reimplemented in DefNoteTrack.

{}
virtual void ReverseTime ( Interval  iv,
DWORD  flags 
) [inline, virtual]
Remarks:
This method is called to reverse the data within the specified interval. For example, if the interval passed is from frame 10 to 20, and there is a key at frame 12, the key should be moved to frame 18. Considered another way, if all the times were normalized, and there was a value n between 0 and 1, n should be changed to 1-n.
Parameters:
iv The interval of time over which to reverse the data.
flags One or more of the following values:

TIME_INCLEFT
Include the left endpoint.

TIME_INCRIGHT
Include the right endpoint.
Default Implementation:
{}
Sample Code:
        INTERP_CONT_TEMPLATE
        void InterpControl<INTERP_CONT_PARAMS>::ReverseTime( Interval iv, DWORD flags )
        {
            Interval test = TestInterval(iv,flags);
            int n = keys.Count();
            HoldTrack();
            for ( int i = 0; i < n; i++ ) {
                if (keys[i].TimeLocked()) continue;
                if ( test.InInterval(keys[i].time) ) {
                    TimeValue delta = keys[i].time - iv.Start();
                    keys[i].time = iv.End()-delta;
                }
            }
            keys.KeysChanged();
            keys.CheckForDups();
            ivalid.SetEmpty();
            NotifyDependents(FOREVER, PART_ALL, REFMSG_CHANGE);
        }

Reimplemented in DefNoteTrack.

{}
virtual void ScaleTime ( Interval  iv,
float  s 
) [inline, virtual]
Remarks:
This method is called to scale an interval of time by the specified scale factor.
Parameters:
iv The interval of time to scale. The origin of the scale is at iv.Start().
s The scale factor for the time.
Default Implementation:
{}
Sample Code:
        INTERP_CONT_TEMPLATE
        void InterpControl<INTERP_CONT_PARAMS>::ScaleTime( Interval iv, float s)
        {
            int n = keys.Count();
            TimeValue delta = int(s*float(iv.End()-iv.Start())) + iv.Start() - iv.End();
            HoldTrack();
            for ( int i = 0; i < n; i++ ) {
                if (keys[i].TimeLocked()) continue;
                if ( iv.InInterval(keys[i].time) ) {
                    keys[i].time =
                        int(s*float(keys[i].time - iv.Start())) + iv.Start();
                } else
                if (keys[i].time > iv.End()) {
                    keys[i].time += delta;
                }
            }
            keys.KeysChanged();
            ivalid.SetEmpty();
            NotifyDependents(FOREVER, PART_ALL, REFMSG_CHANGE);
        }

Reimplemented in DefNoteTrack.

{}
virtual void InsertTime ( TimeValue  ins,
TimeValue  amount 
) [inline, virtual]
Remarks:
This method is called to insert the specified amount of time at the specified insertion point.
Parameters:
ins The time to begin the insertion.
amount The amount of time to insert.
Default Implementation:
{}

Reimplemented in DefNoteTrack.

{}
virtual BOOL SupportTimeOperations ( ) [inline, virtual]
Remarks:
If an anim supports time operations in the track view (cut, copy, paste, etc.), it should implement this method to return TRUE. When it is FALSE the user cannot select blocks of time in the anim's track.
Default Implementation:
{return FALSE;}

Reimplemented in DefNoteTrack.

{ return FALSE; }
virtual CoreExport void MapKeys ( TimeMap map,
DWORD  flags 
) [virtual]
Remarks:
The method is called to update the keys specified by the flags, using the TimeMap passed. The plug-in should go through the specified keys and change their time to TimeMap::map(time). See the sample code below for how this is done.
Parameters:
map Point to instance of Class TimeMap.

flags The flags indicate the keys to operate on. One or more of the following values:

TRACK_DOSEL
Selected keys only.

TRACK_DOALL
All the keys, ignore their selection state.

TRACK_SLIDEUNSEL
Slide unselected keys to the right. Keys are slid by the amount the last key was transformed.

TRACK_RIGHTTOLEFT
Enumerate right to left. If TRACK_SLIDEUNSEL is set, keys will slide to the left.

TRACK_DOSUBANIMS
Sub-Animatables keys as well.

TRACK_DOCHILDNODES
Child Nodes keys as well

TRACK_MAPRANGE
The range, if not locked to first and last key, should be mapped as well.
Sample Code:
        INTERP_CONT_TEMPLATE
        void InterpControl<INTERP_CONT_PARAMS>::MapKeys(TimeMap *map,DWORD flags )
        {
            int n = keys.Count();
            BOOL changed = FALSE;
            if (!n) goto doneMapKeys;
            HoldTrack();
            if (flags&TRACK_DOALL) {
                for (int i = 0; i < n; i++) {
                    if (keys[i].TimeLocked()) continue;
                    keys[i].time = map->map(keys[i].time);
                    changed = TRUE;
                }
            } else if (flags&TRACK_DOSEL) {
                BOOL slide = flags&TRACK_SLIDEUNSEL;
                TimeValue delta = 0, prev;
                int start, end, inc;
                if (flags&TRACK_RIGHTTOLEFT) {
                    start = n-1;
                    end = -1;
                    inc = -1;
                }
                else {
                    start = 0;
                    end = n;
                    inc = 1;
                }
                for (int i = start; i != end; i += inc) {
                    if (keys[i].TimeLocked()) continue;
                    if (keys[i].TestKFlag(KEY_SELECTED)) {
                        prev = keys[i].time;
                        keys[i].time =
                            map->map(keys[i].time);
                        delta = keys[i].time - prev;
                        changed = TRUE;
                    }
                    else if (slide) {
                        keys[i].time += delta;
                    }
                }
            }
            if (flags&TRACK_MAPRANGE && keys.TestTFlag(RANGE_UNLOCKED)) {
                TimeValue t0 = map->map(keys.range.Start());
                TimeValue t1 = map->map(keys.range.End());
                keys.range.Set(t0,t1);
            }
            if (changed) {
                keys.KeysChanged();
                ivalid.SetEmpty();
                NotifyDependents(FOREVER, PART_ALL,
                    REFMSG_CHANGE);
            }
            doneMapKeys:
            Animatable::MapKeys(map,flags);
        }

Reimplemented in DefNoteTrack.

virtual void DeleteKeys ( DWORD  flags ) [inline, virtual]
Remarks:
This method is called to delete keys, as specified by the flags passed.
Parameters:
flags One or more of the following values:

TRACK_DOSEL
Delete selected keys only.

TRACK_DOALL
Delete all keys (ignore selection state).

TRACK_SLIDEUNSEL
Slide unselected keys to the right.

TRACK_RIGHTTOLEFT
Enumerate right to left. If TRACK_SLIDEUNSEL is set, keys will slide to the left.
Default Implementation:
{}

Reimplemented in DefNoteTrack.

{}
virtual void DeleteKeyByIndex ( int  index ) [inline, virtual]
Remarks:
Deletes the key specified by the index passed.
Parameters:
index The index of the key to delete.
Default Implementation:
{}
{}
virtual void SelectKeys ( TrackHitTab sel,
DWORD  flags 
) [inline, virtual]
Remarks:
This method is called to select or deselect a set of keys identified by the TrackHitTab and the specified flags.
Parameters:
sel The table of track hit records. See Class TrackHitRecord and Class Tab. Note the following: typedef Tab<TrackHitRecord> TrackHitTab;

flags Either SELKEYS_SELECT, SELKEYS_DESELECT, or a combination of SELKEYS_CLEARKEYS and SELKEYS_CLEARCURVE will be specified.

One or more of the following values:

SELKEYS_SELECT
The keys should be selected.

SELKEYS_DESELECT
The keys should be deselected.

SELKEYS_CLEARKEYS
All keys should be deselected.

SELKEYS_CLEARCURVE
All keys on the function curve should be deselected.

SELKEYS_FCURVE
Indicates that we are operating on the keys of a function curve, and not of a track.
Default Implementation:
{}

Reimplemented in DefNoteTrack.

{}
virtual void SelectSubKeys ( int  subNum,
TrackHitTab sel,
DWORD  flags 
) [inline, virtual]
Remarks:
This method is available in release 2.0 and later only.

This method is called on the client when the client takes over control of an anims function curves. It's called to select or deselect a set of keys identified by the TrackHitTab and the specified flags.
Parameters:
subNum The index of the sub-anim to select or deselect
sel The table of track hit records. See Class TrackHitRecord and Class Tab. Note the following: typedef Tab<TrackHitRecord> TrackHitTab;

flags Either SELKEYS_SELECT, SELKEYS_DESELECT, or a combination of SELKEYS_CLEARKEYS and SELKEYS_CLEARCURVE will be specified.

One or more of the following values:

SELKEYS_SELECT
The keys should be selected.

SELKEYS_DESELECT
The keys should be deselected.

SELKEYS_CLEARKEYS
All keys should be deselected.

SELKEYS_CLEARCURVE
All keys on the function curve should be deselected.

SELKEYS_FCURVE
Indicates that we are operating on the keys of a function curve, and not of a track.
Default Implementation:
{}
{} 
virtual void SelectSubCurve ( int  subNum,
BOOL  sel 
) [inline, virtual]
Remarks:
This method is available in release 2.0 and later only.

This method is called to set the selected state of the sub-curve whose index is passed.
Parameters:
subNum The index of the sub-anim to select or deselect
sel TRUE to select the curve; FALSE to deselect it.
Default Implementation:
{}
{}
virtual void SelectKeyByIndex ( int  i,
BOOL  sel 
) [inline, virtual]
Remarks:
This method is available in release 2.0 and later only.

This method is called to set the selected state of the key whose index is passed.
Parameters:
i The key to select or deselect.
sel TRUE to select the key; FALSE to deselect it.
Default Implementation:
{}

Reimplemented in DefNoteTrack.

{}
virtual BOOL IsKeySelected ( int  i ) [inline, virtual]
Remarks:
Returns TRUE if the key specified by the index is selected; otherwise FALSE.
Parameters:
i The index of the key to test.
Default Implementation:
{return FALSE;}
{ return FALSE; }
virtual void FlagKey ( TrackHitRecord  hit ) [inline, virtual]
Remarks:
This method is called to have the plug-in flag or mark a specific key identified by the TrackHitRecord.

As an example, when the user goes to move a selection set of keys in the Track View, a yellow marker is drawn. To move the group of keys, the user clicks on a single one. The system needs to track this one key as it is moved, and needs a way to identify it. This method is called so the developer can flag this key as the one that was selected. This is needed because the Track View doesn't know anything about a specific controllers ordering of keys and thus cannot refer to it by index.

The system will call GetFlagKeyIndex() (described below) to retrieve the index of the key that was flagged.
Parameters:
hit The hit record that the controller gave the Track View in the first place to identify the hit. Thus this is enough information to identify the key. See Class TrackHitRecord.
Default Implementation:
{}
Sample Code:
        INTERP_CONT_TEMPLATE
        void InterpControl<INTERP_CONT_PARAMS>::FlagKey(TrackHitRecord hit)
        {
            int n = keys.Count();
            for ( int i = 0; i < n; i++ ) {
                keys[i].ClearKFlag(KEY_FLAGGED);
            }
            assert(hit.hit>=0&&hit.hit<(DWORD)n);
            keys[hit.hit].SetKFlag(KEY_FLAGGED);
        }

Reimplemented in DefNoteTrack.

{}
virtual int GetFlagKeyIndex ( ) [inline, virtual]
Remarks:
Returns the index of the key that is flagged, or -1 if no keys are flagged. See the method above.
Default Implementation:
{return -1;}
Sample Code:
        INTERP_CONT_TEMPLATE
        int InterpControl<INTERP_CONT_PARAMS>::GetFlagKeyIndex()
        {
            int n = keys.Count();
            for ( int i = 0; i < n; i++ ) {
                if (keys[i].TestKFlag(KEY_FLAGGED)) {
                    return i;
                }
            }
            return -1;
        }

Reimplemented in DefNoteTrack.

{ return -1; } 
virtual int NumSelKeys ( ) [inline, virtual]
Remarks:
Returns the number of selected keys.
Default Implementation:
{return 0;}

Reimplemented in DefNoteTrack.

{ return 0; }
virtual void CloneSelectedKeys ( BOOL  offset = FALSE ) [inline, virtual]
Remarks:
This method is called to make a copy of the selected keys.
Parameters:
offset If TRUE, set the new key time to be centered between the original key and the next key.

Reimplemented in DefNoteTrack.

{}   
virtual void AddNewKey ( TimeValue  t,
DWORD  flags 
) [inline, virtual]
Remarks:
This method is called to add a new key at the specified time. The value of the key is set to the value of the previous key, or interpolated between keys, based on the flags passed.
Parameters:
t The time to add the key.
flags One or more of the following values:

ADDKEY_SELECT
Select the new key and deselect any other selected keys.

ADDKEY_INTERP
If TRUE then initialize the new key to the interpolated value at that time. If FALSE, initialize the key to the value of the previous key.
Default Implementation:
{}

Reimplemented in DefNoteTrack.

{}
virtual void MoveKeys ( ParamDimensionBase dim,
float  delta,
DWORD  flags 
) [inline, virtual]
Remarks:
This method is called to move selected keys vertically in the function curve editor. This moves the key values but does not alter the key times. The developer adds the delta to the selected key values, after converting them using the dimension *dim passed. See the sample code below for how this may be done.
Parameters:
dim Used to scale the parameter's values into and out of units used in the user interface. For example, if the parameter was an angle, it would be shown in degrees, but stored in radians. Methods of this class allow the value to be converted back and forth. This is needed because the delta passed is in user interface units. Thus the selected key values need to be converted before the delta is applied. See Class ParamDimensBase.
delta The amount to move the keys (move the values - not the times). This is in the units of the user interface. For example, if an angle has a value in the function curve editor of 100 degrees, 100 would be passed as the delta.
flags Not currently used.
Default Implementation:
{}
Sample Code:
        INTERP_CONT_TEMPLATE
        void InterpControl<INTERP_CONT_PARAMS>::MoveKeys(ParamDimensionBase *dim,float delta,DWORD flags)
        {
            int n = keys.Count();
            if (!n) return;
            float m = 1.0f;
            Interval valid;
            BOOL changed = FALSE;
            HoldTrack();
            for (int i = 0; i < n; i++ ) {
                for (int j=0;j<ELS;j++) {
                    if (keys[i].AnyElemSelected()) {
                        m = GetMultVal(keys[i].time,valid);
                    }
                    if (keys[i].ElemSelected(j)) {
                        keys[i][j] = dim->UnConvert(dim->Convert(keys[i][j]*m)+delta)/m;
                        changed = TRUE;
                    }
                }
            }
            if (changed) {
        // FALSE indicates that key times didn't
        // change so sorting isn't necessary.
                keys.KeysChanged(FALSE);
                ivalid.SetEmpty();
                NotifyDependents(FOREVER, PART_ALL, REFMSG_CHANGE);
            }
        }
{}  
virtual void ScaleKeyValues ( ParamDimensionBase dim,
float  origin,
float  scale,
DWORD  flags 
) [inline, virtual]
Remarks:
This method is called to scale selected keys values. This scales the key values but does not alter the key times. The developer scales the selected key values about the specified origin, after converting them using the dimension *dim passed.

Note the following macro available for scaling about an origin:

#define ScaleAboutOrigin(val,origin,scale)

((((val)-(origin))*(scale))+(origin))
Parameters:
dim Used to scale the parameter's values into and out of units used in the user interface. For example, if the parameter was an angle, it would be shown in degrees, but stored in radians. Methods of this class allow the value to be converted back and forth. See Class ParamDimensBase.
origin The origin about which the keys are scaled.
scale The scale factor to apply to the key values.
flags Not currently used.
Default Implementation:
{}
Sample Code:
        INTERP_CONT_TEMPLATE
        void InterpControl<INTERP_CONT_PARAMS>::ScaleKeyValues(ParamDimensionBase *dim,float origin,float scale,DWORD flags)
        {
            int n = keys.Count();
            if (!n) return;
            BOOL changed = FALSE;
            HoldTrack();
            for (int i = 0; i < n; i++ ) {
                for (int j=0;j<ELS;j++) {
                    if (keys[i].ElemSelected(j)) {
                        keys[i][j] = dim->UnConvert(ScaleAboutOrigin(dim->Convert(keys[i][j]),origin,scale));
                        changed = TRUE;
                    }
                }
            }
            if (changed) {
                keys.KeysChanged(FALSE);
                ivalid.SetEmpty();
                NotifyDependents(FOREVER, PART_ALL, REFMSG_CHANGE);
            }
        }
                         {}
virtual void SelectCurve ( BOOL  sel ) [inline, virtual]
Remarks:
The plug-in keeps track of whether its function curve is selected or not. This method is called to have the plug-in select or deselect its function curve.
Parameters:
sel TRUE if the curve should be selected; FALSE if it should be deselected.
Default Implementation:
{}
{}
virtual BOOL IsCurveSelected ( ) [inline, virtual]

Returns TRUE if the function curve is selected; otherwise returns FALSE.

Default Implementation:
{return FALSE;}
{ return FALSE; }       
virtual BOOL IsSubCurveSelected ( int  subNum ) [inline, virtual]

Returns the selected state of the sub-curve whose index is passed.

Parameters:
subNum The index of the sub-anim
Returns:
TRUE if subNum is seletected.
{ return FALSE; }
virtual int GetSelKeyCoords ( TimeValue &  t,
float &  val,
DWORD  flags 
) [inline, virtual]
Remarks:
This method is used to determine the commonality of the selected keys for display in the time/value type in fields of Track View. It is also used to retrieve the value and/or time of the selected keys (if there is only one selected, or they are common to the selected keys). The flags parameter specified which values to retrieve. The return value indicates if nothing, or several keys were selected. It also indicates if the selected keys shared a common time and/or common value.
Parameters:
t The time of the selected keys is returned here (if appropriate).
val The value of the selected keys is returned here (if appropriate).
flags One of the following values:

KEYCOORDS_TIMEONLY
Only the time t needs to be updated.

KEYCOORDS_VALUEONLY
Only the value val needs to be updated.
Returns:
This indicates what was selected, and what these keys had in common. One or more of the following values should be set:

KEYS_NONESELECTED
This indicates that no keys are selected.

KEYS_MULTISELECTED
This indicates that multiple keys are selected. Both of these last two bits could be set.

KEYS_COMMONTIME
If the selected keys share the same time then this flag should be set. In this case it is appropriate to update t if required.

KEYS_COMMONVALUE
If the selected keys share the same value then this flag should be set. In this case it is appropriate to update val if required.
Default Implementation:
{return KEYS_NONESELECTED;}

Reimplemented in DefNoteTrack.

                                                                           { 
            return KEYS_NONESELECTED; 
        }
virtual void SetSelKeyCoords ( TimeValue  t,
float  val,
DWORD  flags 
) [inline, virtual]
Remarks:
This method is called to update the time and/or value of the selected keys as specified by the flags. This is called if the user uses the time/value type in fields of Track View.
Parameters:
t The time to set for the selected keys (if the flags indicate this is needed).
val The value to set for the selected keys (if the flags indicate this is needed).
flags One of the following values:

KEYCOORDS_TIMEONLY
Only the time needs to be updated.

KEYCOORDS_VALUEONLY
Only the value needs to be updated.
Default Implementation:
{}

Reimplemented in DefNoteTrack.

{}
virtual int SetSelKeyCoordsExpr ( ParamDimension dim,
MCHAR *  timeExpr,
MCHAR *  valExpr,
DWORD  flags 
) [inline, virtual]
Remarks:
This method is similar to SetSelKeyCoords() above. In that case you're given a time and a value and are to update the selected keys with these values (based on the flags passed). In this case, you are instead passed time and value expressions (as strings). The ideas is that these strings are evaulated as expressions and the resulting values are used to updated the selected keys. For instance, the user could select a bunch of keys and then type in n+45. This would add 45 to all the values of the keys.

Developers can use the 3ds Max expression parser (see Class Expr) to evaluate the strings. Debug SDK users can see /MAXSDKDB/SDKSRC/CTRLTEMP.H for an example (or see the sample code below)). If a plug-in doesn't support this feature it can return FALSE from this method and the old SetSelKeyCoords() method will be called. Note that the variable names are defined as KEYCOORDS_TIMEVAR and KEYCOORDS_VALVAR.
Parameters:
dim This is used to convert the parameter value once you get it.
timeExpr A string containing the time expression.
valExpr A string containing the value expression.
flags One of the following values:

KEYCOORDS_TIMEONLY
Only the time t needs to be updated.

KEYCOORDS_VALUEONLY
Only the value val needs to be updated.
Returns:
This indicates what was selected, and what these keys had in common. One or more of the following values should be set:

KEYCOORDS_EXPR_UNSUPPORTED
Don't implement this method

KEYCOORDS_EXPR_ERROR
Error in expression

KEYCOORDS_EXPR_OK
Expression evaluated
Default Implementation:
{return KEYCOORDS_EXPR_UNSUPPORTED;}

Sample Code:
        INTERP_CONT_TEMPLATE
        int InterpControl<INTERP_CONT_PARAMS>::SetSelKeyCoordsExpr( ParamDimension *dim, MCHAR *timeExpr, MCHAR *valExpr, DWORD flags)
        {
            Expr texpr, vexpr;
            float vin, vout=0.0f, tfin, tfout=0.0f;
        
            if (timeExpr) {
                texpr.defVar(SCALAR_VAR,KEYCOORDS_TIMEVAR);
                if (texpr.load(timeExpr)!=EXPR_NORMAL) return KEYCOORDS_EXPR_ERROR;
            }
            if (valExpr) {
                vexpr.defVar(SCALAR_VAR,KEYCOORDS_VALVAR);
                if (vexpr.load(valExpr)!=EXPR_NORMAL) return KEYCOORDS_EXPR_ERROR;
            }
        
            int n = keys.Count();
            if (!n) return KEYCOORDS_EXPR_OK;
            HoldTrack();
            for (int i = 0; i < n; i++ ) {
                if (!(flags&KEYCOORDS_VALUEONLY)) {
                    if (keys[i].TimeLocked()) continue;
                    if (keys[i].TestKFlag(KEY_SELECTED)) {
                        tfin = float(keys[i].time)/float(GetTicksPerFrame());
                        texpr.eval(&tfout, 1, &tfin);
                        keys[i].time = int(tfout*GetTicksPerFrame());
                    }
                }
                if (!(flags&KEYCOORDS_TIMEONLY)) {
                    for (int j=0;j<ELS;j++) {
                        if (keys[i].ElemSelected(j)) {
                            vin = dim->Convert(keys[i][j]);
                            vexpr.eval(&vout, 1, &vin);
                            keys[i][j] = dim->UnConvert(vout);
                        }
                    }
                }
            }
            keys.KeysChanged();
            keys.CheckForDups();
            ivalid.SetEmpty();
            NotifyDependents(FOREVER, PART_ALL, REFMSG_CHANGE);
            return KEYCOORDS_EXPR_OK;
                         {
                return KEYCOORDS_EXPR_UNSUPPORTED;
        }
virtual void AdjustTangents ( TrackHitRecord  hit,
ParamDimensionBase dim,
Rect rcGraph,
float  tzoom,
int  tscroll,
float  vzoom,
int  vscroll,
int  dx,
int  dy,
DWORD  flags 
) [inline, virtual]
Remarks:
If a plug-in has tangent handles, this method is called if the user adjusts them. If a plug-in doesn't have tangent handles, this method may be ignored. This method is called if the user selects one of the handles and moves the mouse. This method is passed the dx, and dy of the mouse motion.

The plug-in may have any types of handles it wishes, and it is responsible for processing whatever needs to be done when the user adjusts them. The method is passed information about the screen space, such as the overall rectangle, and time and value scroll and zoom factors. See Screen-Time-Value Macros for macros to convert in and out of screen space.
Parameters:
hit This identifies the handle that was selected.
dim The parameter dimension. See Class ParamDimensionBase.
rcGraph This is the rectangle of the graph viewport.
tzoom This is the time zoom factor.
tscroll This is the time scroll factor.
vzoom This is the value zoom factor.
vscroll This is the value scroll factor.
dx The mouse movement in screen coordinates in the x direction.
dy The mouse movement in screen coordinates in the y direction.
flags One of the following values:

ADJTAN_LOCK
Indicates the tangents are locked.

ADJTAN_BREAK
Indicates the tangents have been broken.
Default Implementation:
{}
                         {};
virtual CoreExport BOOL SubAnimSetKeyBufferPresent ( int  subNum ) [virtual]

returns true if the sub-anim has a "Set Key" buffer present

See also:
SetKeyBufferPresent
Parameters:
subNum - The index of the SubAnim to test.
Returns:
TRUE if the SubAnim has a SetKey buffer present
Default Implementation:
        {
            if (SubAnim(SubNum)) return SubAnim(subNum)->SetKeyBufferPresent();
            return FALSE;
        }
virtual BOOL SetKeyBufferPresent ( ) [inline, virtual]

returns true if there is a "Set Key" buffer present

This method should be implemented for a keyframeable controller to support the "Set Key" animation mode. When in the "Set Key" mode, if the user modifies a keyframe controller the controller should create a temporary buffer to hold the new value until the user either commits or cancels the change.

Note:
It is the plugins responsibility to ensure that the correct value (either the temp buffer or the permanent keyframed value) is returned from GetValue. For an example implementation of this method, look at samples/controllers/boolctrl.cpp
Returns:
True if a buffer is present
{ return FALSE; }
virtual CoreExport void SubAnimCommitSetKeyBuffer ( TimeValue  t,
int  subNum 
) [virtual]

Commit any "Set Key" buffers on the given sub-anim.

See also:
CommitSetKeyBuffer
Parameters:
subNum - The index of the SubAnim to commit.
Default Implementation:
        {
            Animatable* anim = SubAnim(subNum);
            if ( anim ) anim->CommitSetKeyBuffer(t);
        }
virtual void CommitSetKeyBuffer ( TimeValue  t ) [inline, virtual]

Commit any "Set Key" buffers.

This function will be called whenever the user clicks the the large "Set Keys" button. If this animatable is keyable, it should commit any temporary "Set Key" buffers to its permanent keyframe storage. For an example implementation of this method, look at samples/controllers/boolctrl.cpp

{}
virtual CoreExport void SubAnimRevertSetKeyBuffer ( int  subNum ) [virtual]

Revert any "Set Key" buffers on the given sub-anim.

See also:
RevertSetKeyBuffer
Parameters:
subNum - The index of the SubAnim to revert.
Default Implementation:
        {
            Animatable* anim = SubAnim(subNum);
            if ( anim ) anim->RevertSetKeyBuffer(t);
        }
virtual void RevertSetKeyBuffer ( ) [inline, virtual]

Revert any "Set Key" buffers.

If this animatable currently has a "Set Key" buffer, revert the value and remove the buffer. For an example implementation of this method, look at samples/controllers/boolctrl.cpp

{}
virtual CoreExport BOOL IsAnimated ( ) [virtual]
Remarks:
Returns TRUE if this animatable actually has animation; otherwise FALSE. This method is recursive, so for example, if you call node->IsAnimated() it will return TRUE if any aspect of the node is animated; otherwise it will return FALSE.
Default Implementation:
The default implementation returns TRUE if a child anim has animation.

Reimplemented in DefNoteTrack.

virtual BOOL CanCopyTrack ( Interval  iv,
DWORD  flags 
) [inline, virtual]
Remarks:
Returns TRUE if this item can copy its data over the specified range; otherwise returns FALSE.
Parameters:
iv The interval of time that would be copied.
flags One or more of the following values:

TIME_INCLEFT
Include the left endpoint.

TIME_INCRIGHT
Include the right endpoint.
Default Implementation:
{return FALSE;}

Reimplemented in DefNoteTrack.

{ return FALSE; }
virtual BOOL CanPasteTrack ( TrackClipObject cobj,
Interval  iv,
DWORD  flags 
) [inline, virtual]
Remarks:
Returns TRUE if this item can paste its data over the specified range; otherwise returns FALSE.
Parameters:
cobj The clipboard object that would be pasted. The item should look at the SuperClassID and Class_ID of the creator of the clip object to determine if it is a suitable object to paste. See Class TrackClipObject.
iv The interval of time that would be pasted.
flags One or more of the following values:

TIME_INCLEFT
Include the left endpoint.

TIME_INCRIGHT
Include the right endpoint.
Default Implementation:
{return FALSE;}

Reimplemented in DefNoteTrack.

{ return FALSE; }
virtual TrackClipObject* CopyTrack ( Interval  iv,
DWORD  flags 
) [inline, virtual]
Remarks:
This method is called to copy the item's track data over the specified interval.
Parameters:
iv The interval of time over which to copy the track data.
flags One or more of the following values:

TIME_INCLEFT
Include the left endpoint.

TIME_INCRIGHT
Include the right endpoint.
Returns:
The item should return an instance of a class derived from TrackClipObject that contains the data for the item. See Class TrackClipObject.
Default Implementation:
{return NULL;}

Reimplemented in DefNoteTrack.

{ return NULL; }
virtual void PasteTrack ( TrackClipObject cobj,
Interval  iv,
DWORD  flags 
) [inline, virtual]
Remarks:
This method is called to paste the specified clip object to this track. This method will not be called unless CanPasteTrack() returned TRUE.
Parameters:
cobj The data to paste.
iv The interval of time to paste.
flags One or more of the following values:

TIME_INCLEFT
Include the left endpoint.

TIME_INCRIGHT
Include the right endpoint.

Reimplemented in DefNoteTrack.

{}
virtual BOOL CanCopySubTrack ( int  subNum,
Interval  iv,
DWORD  flags 
) [inline, virtual]
Remarks:
This method is available in release 2.0 and later only.

If CanCopyTrack() returns FALSE then this method is called on the sub-anim (passing the sub number).

This is used in particular for Parameter Blocks. In that case, if there is no controller plugged into the track, the copying and pasting of controllers can't be done (since there is no controller). However, this method allows the Parameter Block to handle it.
Parameters:
subNum Specifies the sub-anim to check.
iv The interval of time over which to copy the track data.
flags One or more of the following values:

TIME_INCLEFT
Include the left endpoint.

TIME_INCRIGHT
Include the right endpoint.
Returns:
TRUE if the specified item can copy its data over the specified range; otherwise FALSE.
Default Implementation:
{return FALSE;}
{ return FALSE; }
virtual BOOL CanPasteSubTrack ( int  subNum,
TrackClipObject cobj,
Interval  iv,
DWORD  flags 
) [inline, virtual]
Remarks:
This method is available in release 2.0 and later only.

Returns TRUE if the specified item can paste its data over the specified range; otherwise returns FALSE.

Plug-ins can implement pasting for cases where their sub-anims don't implement it. An example of this is the Parameter Block class. It implements this method to allow pasting parameters that don't have controllers assigned to them. These aren't called on the client unless the sub-anim doesn't implement CanPasteTrack().
Parameters:
subNum Specifies the sub-anim to check.
cobj The data to paste.
iv The interval of time to paste.
flags One or more of the following values:

TIME_INCLEFT
Include the left endpoint.

TIME_INCRIGHT
Include the right endpoint.
Returns:
TRUE if the specified item can paste its data over the specified range; otherwise FALSE.
Default Implementation:
{return FALSE;}
{ return FALSE; }
virtual TrackClipObject* CopySubTrack ( int  subNum,
Interval  iv,
DWORD  flags 
) [inline, virtual]
Remarks:
This method is available in release 2.0 and later only.

This method is called to copy the specified sub anim's track data over the specified interval.
Parameters:
subNum The number of the sub-anim to copy.
iv The interval of time over which to copy the track data.
flags One or more of the following values:

TIME_INCLEFT
Include the left endpoint.

TIME_INCRIGHT
Include the right endpoint.
Returns:
The item should return an instance of a class derived from TrackClipObject that contains the data for the item. See Class TrackClipObject.
Default Implementation:
{return NULL;}
{ return NULL; }
virtual void PasteSubTrack ( int  subNum,
TrackClipObject cobj,
Interval  iv,
DWORD  flags 
) [inline, virtual]
Remarks:
This method is available in release 2.0 and later only.

This method is called to paste the specified clip object to the specified sub-anim track.
Parameters:
subNum The number of the sub-anim to paste.
cobj The data to paste.
iv The interval of time to paste.
flags One or more of the following values:

TIME_INCLEFT
Include the left endpoint.

TIME_INCRIGHT
Include the right endpoint.
Default Implementation:
{}
{}
virtual int GetTrackVSpace ( int  lineHeight ) [inline, virtual]
Remarks:
Returns the vertical space occupied by the track in units of one line.
Parameters:
lineHeight The height of a single line in pixels.
Default Implementation:
{ return 1; }

Reimplemented in DefNoteTrack.

{ return 1; }
virtual int HitTestTrack ( TrackHitTab hits,
Rect rcHit,
Rect rcTrack,
float  zoom,
int  scroll,
DWORD  flags 
) [inline, virtual]
Remarks:
This method is called to determine which keys lie within the rcHit rectangle. Keys that are hit are added to the hits table.
Parameters:
hits The table of TrackHitRecords to update. Each key that lies within the hit rectangle (is hit) should be added to this table. It is up to the plug-in to define a scheme that allows it to identify its hits using the data members of Class TrackHitRecord. Also see Class Tab for methods to add to the table.
rcHit This is the region that was selected for hit testing. This may be a small rectangle about the mouse pick point, or a larger rectangle if the user selected by window.
rcTrack This is the entire rectangular region of the track.
zoom The is the time zoom factor.
scroll This is the time scroll factor.
flags One or more of the following value:

HITTRACK_SELONLY
Selected only.

HITTRACK_UNSELONLY
Unselected only.

HITTRACK_ABORTONHIT
Abort hit testing on first hit.

HITCURVE_TESTTANGENTS
Hit test curve tangents.
Returns:
One of the following values:

TRACK_DONE
This indicates the track was hit tested.

TRACK_DORANGE
This indicates that the system will handle hit testing to the range bar for the item. For example a node returns this value because it does not have any keys. Therefore it just lets the user hit test the range bar. In general, anything that is not a leaf controller will not implement this method and return the default. The system will then simply hit test the range bar.

TRACK_ASKCLIENT
If a plug-in returns this value then the anim's client will be given a chance to paint the track in Track View. If a client returns this value then the method PaintSubTrack() will be called.
Default Implementation:
{ return TRACK_DORANGE; }

Reimplemented in DefNoteTrack.

                          { return TRACK_DORANGE; }
virtual int PaintTrack ( ParamDimensionBase dim,
HDC  hdc,
Rect rcTrack,
Rect rcPaint,
float  zoom,
int  scroll,
DWORD  flags 
) [inline, virtual]
Remarks:
This method is called to display the item in the track view. If an item needs to draw itself in a special fashion, it implements this method to do so. For example, a sound plug-in may draw its waveform using this method. If an item does not need to draw itself, the default implementation may be used. This draws the range bar for the item.

Note: When drawing something to appear in Track View, a developer should not do any clipping of their own. 3ds Max will take care of all clipping itself.
Parameters:
dim The dimension for the parameter of this track.
hdc The handle of the device context.
rcTrack The entire rectangle of the inside of the track.
rcPaint This is the rectangular region that needs to be repainted - the invalid region.
zoom The time zoom factor.
scroll The time scroll factor.
flags One or more of the following values which are filters for controllers with more than one curve:

DISPLAY_XCURVE
DISPLAY_YCURVE

Note:
RGB controllers interpret X as red, Y as green, and Z as blue. DISPLAY_ZCURVE
Returns:
One of the following values:

TRACK_DONE
Indicates the track was painted.

TRACK_DORANGE
Indicates the system should draw the range bars for the item.

TRACK_ASKCLIENT
Indicates the anim's client will be given a chance to paint the track in Track View. See Animatable::PaintSubTrack() which will be called to do this.
Default Implementation:
{ return TRACK_DORANGE; }

Reimplemented in DefNoteTrack.

                          { return TRACK_DORANGE; }
virtual int PaintSubTrack ( int  subNum,
ParamDimensionBase dim,
HDC  hdc,
Rect rcTrack,
Rect rcPaint,
float  zoom,
int  scroll,
DWORD  flags 
) [inline, virtual]
Remarks:
This method is available in release 2.0 and later only.

This method will be called if PaintTrack returns TRACK_ASKCLIENT. This gives the anim's client a chance to paint the tracks in Track View.
Parameters:
subNum Specifies the sub-anim to paint.
dim The dimension for the parameter of this track.
hdc The handle of the device context.
rcTrack The entire rectangle of the inside of the track.
rcPaint This is the rectangular region that needs to be repainted - the invalid region.
zoom The time zoom factor.
scroll The time scroll factor.
flags One or more of the following values which are filters for controllers with more than one curve:

DISPLAY_XCURVE
DISPLAY_YCURVE
DISPLAY_ZCURVE
Note:
RGB controllers interpret X as red, Y as green, and Z as blue.
Returns:
One of the following values:

TRACK_DONE
Indicates the track was painted.

TRACK_DORANGE
Indicates the system should draw the range bars for the item.
Default Implementation:
{return TRACK_DORANGE;}
                         {return TRACK_DORANGE;}
virtual int PaintFCurves ( ParamDimensionBase dim,
HDC  hdc,
Rect rcGraph,
Rect rcPaint,
float  tzoom,
int  tscroll,
float  vzoom,
int  vscroll,
DWORD  flags 
) [inline, virtual]
Remarks:
This method is called to draw the function curve of the anim.
Parameters:
dim The parameter dimension. See Class ParamDimensionBase.
hdc The handle of the device context.
rcGraph The entire rectangle of the inside of the graph region.
rcPaint This is the rectangular region that needs to be repainted - the invalid region.
tzoom The time zoom factor.
tscroll The time scroll factor.
vzoom The value zoom factor.
vscroll The value scroll factor.
flags One or more of the following values which are filters for controllers with more than one curve:

PAINTCURVE_SHOWTANGENTS
Show the curve tangent handles.

PAINTCURVE_FROZEN
Show the curve in a frozen state. DISPLAY_XCURVE
DISPLAY_YCURVE
DISPLAY_ZCURVE
PAINTCURVE_GENCOLOR
Draw the curve in its standard color.

The following options are passed to float controllers indicating a sugested color for drawing:

PAINTCURVE_XCOLOR
Draw the curve in red.

PAINTCURVE_YCOLOR
Draw the curve in green.

PAINTCURVE_ZCOLOR
Draw the curve in blue.
Note:
RGB controllers interpret X as red, Y as green and Z as blue.
Returns:
A plug-in should always return 0.
Default Implementation:
{ return 0; }

Reimplemented in Control.

                          { return 0; }
virtual int HitTestFCurves ( ParamDimensionBase dim,
TrackHitTab hits,
Rect rcHit,
Rect rcGraph,
float  tzoom,
int  tscroll,
float  vzoom,
int  vscroll,
DWORD  flags 
) [inline, virtual]
Remarks:
This method is called to hit test the item's function curves. It is called to determine which keys on the curve lie within the rcHit rectangle. Keys that are hit are added to the hits table.
Parameters:
dim The parameter dimension. See Class ParamDimensionBase.
hits The table of TrackHitRecords to update. Each key that lies within the hit rectangle (is hit) should be added to this table. It is up to the plug-in to define a scheme that allows it to identify its hits using the data members of Class TrackHitRecord. Also see Class Tab for methods to add to the table.
rcHit This is the region that was selected for hit testing. This may be a small rectangle about the mouse pick point, or a larger rectangle if the user selected by window.
rcGraph This is the entire rectangle of the graph region.
tzoom This is the time zoom factor.
tscroll This is the time scroll factor.
vzoom This is the time zoom factor.
vscroll This is the time scroll factor.
flags One or more of the following values:

HITTRACK_SELONLY
Selected only.

HITTRACK_UNSELONLY
Unselected only.

HITTRACK_ABORTONHIT
Abort hit testing on first hit.

HITCURVE_TESTTANGENTS
Hit Test curve tangent handles.

The following are filters for controllers with more than one curve.

DISPLAY_XCURVE

DISPLAY_YCURVE

DISPLAY_ZCURVE
Note:
RGB controllers interpret X as red, Y as green and Z as blue.
Returns:
One of the following values to indicate what was hit:

HITCURVE_KEY
Hit one or more keys.

HITCURVE_WHOLE
Hit the curve (anywhere).

HITCURVE_TANGENT
Hit a tangent handle.

HITCURVE_NONE
Nothing was hit.

HITCURVE_ASKCLIENT
Ask the client to hit test the function curve. See Animatable::HitTestSubFCurves().
Default Implementation:
{ return HITCURVE_NONE; }
                          { return HITCURVE_NONE; }
virtual int PaintSubFCurves ( int  subNum,
ParamDimensionBase dim,
HDC  hdc,
Rect rcGraph,
Rect rcPaint,
float  tzoom,
int  tscroll,
float  vzoom,
int  vscroll,
DWORD  flags 
) [inline, virtual]
Remarks:
This method is called to draw the specified sub-anim function curve. This allows the client to paint its function curve.
Parameters:
subNum The sub-anim number to paint.
dim The parameter dimension. See Class ParamDimensionBase.
hdc The handle of the device context.
rcGraph The entire rectangle of the inside of the graph region.
rcPaint This is the rectangular region that needs to be repainted - the invalid region.
tzoom The time zoom factor.
tscroll The time scroll factor.
vzoom The value zoom factor.
vscroll The value scroll factor.
flags One or more of the following values:

PAINTCURVE_SHOWTANGENTS
Show the curve tangent handles.

PAINTCURVE_FROZEN
Show the curve in a frozen state.

The following values are filters for controllers with more than one curve.

DISPLAY_XCURVE
DISPLAY_YCURVE
DISPLAY_ZCURVE

PAINTCURVE_GENCOLOR
Draw the curve in its standard color.

The following options are passed to float controllers indicating a sugested color for drawing:

PAINTCURVE_XCOLOR
Draw the curve in red.

PAINTCURVE_YCOLOR
Draw the curve in green.

PAINTCURVE_ZCOLOR
Draw the curve in blue.
Note:
RGB controllers interpret X as red, Y as green and Z as blue.
Returns:
A plug-in should always return 0.
Default Implementation:
{ return 0; }
                          { return 0; }
virtual int HitTestSubFCurves ( int  subNum,
ParamDimensionBase dim,
TrackHitTab hits,
Rect rcHit,
Rect rcGraph,
float  tzoom,
int  tscroll,
float  vzoom,
int  vscroll,
DWORD  flags 
) [inline, virtual]
Remarks:
This method is called if HitTestFCurves() returns HITCURVE_ASKCLIENT. It allows the client to hit test its sub-anim curves.
Parameters:
subNum The sub-anim number to hit test.
dim The parameter dimension. See Class ParamDimensionBase.
hits The table of TrackHitRecord instances to update. Each key that lies within the hit rectangle (is hit) should be added to this table. It is up to the plug-in to define a scheme that allows it to identify its hits using the data members of Class TrackHitRecord. Also see Class Tab for methods to add to the table.
rcHit This is the region that was selected for hit testing. This may be a small rectangle about the mouse pick point, or a larger rectangle if the user selected by window.
rcGraph This is the entire rectangle of the graph region.
tzoom This is the time zoom factor.
tscroll This is the time scroll factor.
vzoom This is the time zoom factor.
vscroll This is the time scroll factor.
flags One or more of the following values:

HITTRACK_SELONLY
Selected only.

HITTRACK_UNSELONLY
Unselected only.

HITTRACK_ABORTONHIT
Abort hit testing on first hit.

HITCURVE_TESTTANGENTS
Hit Test curve tangent handles.

The follow are filters for controllers with more than one curve. (RGB controllers interpret X as red, Y as green and Z as blue.)

DISPLAY_XCURVE
DISPLAY_YCURVE
DISPLAY_ZCURVE
Returns:
One of the following values to indicate what was hit:

HITCURVE_KEY
Hit one or more keys.

HITCURVE_WHOLE
Hit the curve (anywhere).

HITCURVE_TANGENT
Hit a tangent handle.

HITCURVE_NONE
Nothing was hit.
Default Implementation:
{ return HITCURVE_NONE; }
                          { return HITCURVE_NONE; }
virtual void EditTrackParams ( TimeValue  t,
ParamDimensionBase dim,
MCHAR *  pname,
HWND  hParent,
IObjParam ip,
DWORD  flags 
) [inline, virtual]
Remarks:
This method is called for the plug-in to put up a modal dialog and let the user edit the tracks parameters for the selected keys. This function should not return until the user has completed editing at which time any windows that were created should be destroyed. Unlike BeginEditParams() and EndEditParams() this interface is modal.
Parameters:
t This time represents the horizontal position of where the user right clicked to bring up the modal edit track parameters dialog. See the flags below for when this parameter is valid.
dim The parameter dimension. See Class ParamDimensionBase.
pname The name of the parameter as given by the client.
hParent This is the parent window that should be used to create any dialogs.
ip An interface pointer available for calling functions in 3ds Max.
flags One or more of the following values:

EDITTRACK_FCURVE
The user is in the function curve editor.

EDITTRACK_TRACK
The user is in one of the track views.

EDITTRACK_SCENE
The user is editing a path in the scene.

EDITTRACK_BUTTON
The user invoked by choosing the properties button. In this case the time parameter is NOT valid.

EDITTRACK_MOUSE
The user invoked by right clicking with the mouse. In this case the time parameter is valid.
Default Implementation:
{}

Reimplemented in DefNoteTrack.

                         {}
virtual int TrackParamsType ( ) [inline, virtual]
Remarks:
This method returns a value that indicates how the track parameter editing is invoked.
Returns:
One of the following values:

TRACKPARAMS_NONE

Has no track parameters. If this is returned then EditTrackParams() will not be called.

TRACKPARAMS_KEY

Entered by right clicking on a selected key. This should be used if the dialog provides parameters for the entire controller (for example as the Noise controller's dialog does).

TRACKPARAMS_WHOLE

Entered by right clicking anywhere in the track. This should be used if the dialog will represent the selection of keys (as a key info type dialog does).
Default Implementation:
{return TRACKPARAMS_NONE;}

Reimplemented in DefNoteTrack.

{return TRACKPARAMS_NONE;}
virtual int GetFCurveExtents ( ParamDimensionBase dim,
float &  min,
float &  max,
DWORD  flags 
) [inline, virtual]

This method is called to calculate the largest and smallest values of the anim.

The values max and min should be initialized before calling this function. A plugin implementing this function should not reset the values passed - in this way if max is passed with a larger value than the curve extents calculated for the current anim, the value of max will be unchanged.

Parameters:
dim - The dimension of the anim.
[out] min - The smallest value. These are in the units given by the dimension. For example, if it was an angle parameter that was displayed in degrees, the units returned through min should be in degrees as well. A class should implement this method to not reset this value
[out] max - The largest value. These are in the units given by the dimension. For example, if it was an angle parameter that was displayed in degrees, the units returned through max should be in degrees as well.
flags - One or more of the following values which are filters for controllers with more than one curve:

DISPLAY_XCURVE
DISPLAY_YCURVE
DISPLAY_ZCURVE
Note:
RGB controllers interpret X as red, Y as green and Z as blue.
Returns:
If this method is processed, return nonzero; otherwise zero.

Reimplemented in Control.

                         { return 0; }
virtual int GetSubFCurveExtents ( int  subNum,
ParamDimensionBase dim,
float &  min,
float &  max,
DWORD  flags 
) [inline, virtual]

This method is called to calculate the largest and smallest values of the specified subanim.

The values max and min should be initialized before calling this function. A plugin implementing this function should not reset the values passed - in this way if max is passed with a larger value than the curve extents calculated for the current anim, the value of max will be unchanged.

Parameters:
subNum - The index of the SubAnim to query for curve extents
dim - The dimension of the anim.
[out] min - The smallest value. These are in the units given by the dimension. For example, if it was an angle parameter that was displayed in degrees, the units returned through min should be in degrees as well. A class should implement this method to not reset this value
[out] max - The largest value. These are in the units given by the dimension. For example, if it was an angle parameter that was displayed in degrees, the units returned through max should be in degrees as well.
flags - One or more of the following values which are filters for controllers with more than one curve:

DISPLAY_XCURVE
DISPLAY_YCURVE
DISPLAY_ZCURVE
Note:
RGB controllers interpret X as red, Y as green and Z as blue.
Returns:
If this method is processed, return nonzero; otherwise zero.
                         { return 0; }
virtual ParamDimension* GetParamDimension ( int  i ) [inline, virtual]
Remarks:
Returns the type of dimension of the 'i-th' sub-anim. A dimension describes the type and order of magnitude of a sub-anim.
Parameters:
i Specifies the sub-anim (parameter) to return the dimension of.
Returns:
The dimension of the 'i-th' sub-anim (parameter).
Default Implementation:
{return defaultDim;}

Reimplemented in EaseCurveList, MultCurveList, and IParamBlock2.

{ return defaultDim; }
virtual LRESULT CALLBACK TrackViewWinProc ( HWND  hwnd,
UINT  message,
WPARAM  wParam,
LPARAM  lParam 
) [inline, virtual]

This function is obsolete.

Reimplemented in DummyObject, SimpleShape, and SimpleSpline.

                            { return 0;}
virtual BOOL SelectSubAnim ( int  subNum ) [inline, virtual]
Remarks:
This method is available in release 2.0 and later only.

When a user is in Track View in Edit Keys mode and clicks on the green triangle of a controller then this method will be called on the client with the appropriate sub number that corresponds to it. For instance, the Editable Mesh object implements this to allow the user to select vertices that are animated from the Track View.
Parameters:
subNum The index of the sub-anim that was clicked on.
Returns:
TRUE if implemented; otherwise FALSE. (Track View will call RedrawViewports() if something returns TRUE from this method).
Default Implementation:
{return FALSE;}

Reimplemented in PatchObject, and SplineShape.

{ return FALSE; }
CoreExport void AddNoteTrack ( NoteTrack note )
Remarks:
Implemented by the System.

This method adds the specified note track.
Parameters:
note The note track to add. The Note Tracks provided by 3ds Max are derived from Class DefNoteTrack (which is derived from NoteTrack). See that class for the methods and data members used to access Note Tracks.
CoreExport void DeleteNoteTrack ( NoteTrack note,
BOOL  delNote = TRUE 
)
Remarks:
Implemented by the System.

This method deletes the specified note track.
Parameters:
note The note track to delete. The Note Tracks provided by 3ds Max are derived from Class DefNoteTrack (which is derived from NoteTrack). See that class for the methods and data members used to access Note Tracks.
delNote If delNote is FALSE the note track will be removed from the anim but not deleted.
CoreExport BOOL HasNoteTracks ( )
Remarks:
Implemented by the System.

This method returns TRUE if the track has note tracks; otherwise FALSE.
CoreExport int NumNoteTracks ( )
Remarks:
Implemented by the System.

This method returns the number of note tracks.
CoreExport NoteTrack* GetNoteTrack ( int  i )
Remarks:
Implemented by the System.

This method retrieves the 'i-th' note track.
Parameters:
i Specifies the note track to retrieve.
Returns:
A pointer to a Note Track. The Note Tracks provided by 3ds Max are derived from Class DefNoteTrack (which is derived from NoteTrack). See that class for the methods and data members used to access Note Tracks.
virtual CoreExport void EnumAuxFiles ( AssetEnumCallback assetEnum,
DWORD  flags = FILE_ENUM_ALL 
) [virtual]
Remarks:
This method is used to enumerate any 'auxiliary' files maintained by the item and record the filename with the callback. Entities which actually need to load auxiliary files (for instance texture maps) must implement this method, possibly calling ReferenceMaker::EnumAuxFiles() also. The ReferenceMaker implementation simply calls itself on all its references (see below).

Class Interface has a method that may be used to call this on the entire system. This includes the renderer, materials editor, atmospheric effects, background, video post, lights, etc. -- everything that may have auxiliary files associated with it. After specifying the appropriate flags a list of filenames is created that matched the enumeration conditions as specified by the flags. This is used for instance by the Archive function in 3ds Max to grab a list of bitmap files used by the system.
Parameters:
assetEnum The callback object that may be used to record the asset. See Class AssetEnumCallback.
flags See Auxilliary File Enumeration Flags
Sample Code:
This is the default implementation provided by ReferenceMaker.

        void ReferenceMaker::EnumAuxFiles(NameEnumCallback& nameEnum, DWORD flags)
        {
               if ((flags&FILE_ENUM_CHECK_AWORK1)&&TestAFlag(A_WORK1)) return;

               // no local aux files...
                     
               // enumerate my children. Derived classes don't need to do this since they should
               // call EnumAuxFiles on their base class, and so will eventually end up here
               if (flags&FILE_ENUM_DONT_RECURSE) return;
               for (int i=0; i<NumRefs(); i++) {
                      ReferenceMaker *srm = GetReference(i);
                      if (srm) {
                             if ((flags&FILE_ENUM_CHECK_AWORK1)&&srm->TestAFlag(A_WORK1)) continue;
                             srm->EnumAuxFiles(nameEnum,flags);
                             srm->SetAFlag(A_WORK1);
                      }
               }

               // pick up base class...
               Animatable::EnumAuxFiles(nameEnum,flags); 
        }

Reimplemented in MtlBase, ReferenceMaker, MSPluginTexmap, MSTexmapXtnd, MSPluginMtl, and MSMtlXtnd.

virtual void FreeAllBitmaps ( ) [inline, virtual]
Remarks:
This method is available in release 2.0 and later only.

This method frees all bitmaps in this Animatable but doesn't recurse. This is used for freeing all the scene bitmaps after a render.
Default Implementation:
{}
{}
virtual void GetSystemNodes ( INodeTab nodes,
SysNodeContext  Context 
) [inline, virtual]
Remarks:
The master controller of a system plug-in should implement this method to give 3ds Max a list of nodes that are part of the system. The master controller should fill in the given table with the INode pointers of the nodes that are part of the system. This will ensure that operations like cloning and deleting affect the whole system.

Said another way, GetSystemNodes() should be implemented for the master controller of a system, and should return a list of pointers to all nodes that are part of the system. GetInterface() should be implemented for the slave TM controllers of the system and return a pointer to the master controller.

3ds Max will use GetInterface() in the TM controller of each selected node to retrieve the master controller and then call GetSystemNodes() on the master controller to get the list of nodes.
Parameters:
nodes The table of nodes that are part of the system.
Context This parameter is available in release 4.0 and later only. This parameter can be used to specify the context under which the "system nodes" are used. These are; kSNCClone, kSNCDelete, kSNCFileMerge, and kSNCFileSave.
Default Implementation:
{}
{}
virtual BOOL IsSubClassOf ( Class_ID  classID ) [inline, virtual]

returns true if the animatable has sub-classed off the given class

If an object is a sub-class of a particular class, it will have a different ClassID() because it is a different class. This method allows an object to indicate that it is a sub-class of a particular class and therefore can be treated as one. For example, a class could be derived from TriObject. This derived class would have a different ClassID() then the TriObject's class ID however it still can be treated (cast) as a TriObject because it is derived from TriObject. Note the default implelementation: a class is considered to also be a subclass of itself.

Parameters:
classID The Class_ID of the item that this class is a sub-class of.
Returns:
TRUE if this class is a sub-class of classID; otherwise FALSE.
Default Implementation:
{return classID==ClassID();}

Reimplemented in PatchObject.

                                                    {
            return (classID == ClassID());
        }
virtual BOOL IsRefMaker ( ) [inline, virtual]

Tells whether it is a ReferenceMaker.

This function differentiates things sub classed from Animatable from subclasses of ReferenceMaker. The implementation of this method (in Animatable) returns FALSE and its implementation in ReferenceMaker returns TRUE.

Returns:
Default of FALSE.

Reimplemented in ReferenceMaker.

{ return FALSE; }
CoreExport void AddAppDataChunk ( Class_ID  cid,
SClass_ID  sid,
DWORD  sbid,
DWORD  len,
void *  data 
)

Adds application/plugin specific (custom) data to an Animatable.

This method is used to add an AppDataChunk to this Animatable. The chunk is identified using the Class_ID, and SuperClassID of the owner, and an ID for sub-chunks.

Note:
Developers who want to add appdata to the scene should see the method ReferenceTarget *Interface::GetScenePointer().
Parameters:
cid - The Class_ID of the owner of the chunk.
sid - The SuperClassID of the owner of the chunk.
sbid - An extra ID that lets the owner identify its sub-chunks.
len - The length of the data in bytes.
data - Pointer to the actual data. The data should be allocated on the heap by client code using MAX_malloc(). This will allow the system to free it safely (using MAX_free()). MAX_malloc() and MAX_free() are memory management routines implemented by the system.
Note:
Not allocating on the heap the data passed to this method may lead to unexpected behaviour of the application.
Client code does not need to free the data that has been passed to this method. The system will free it when the Animatable is deleted or when client code explicitely removes the custom data chunk from the Animatable by calling Animatable::RemoveAppDataChunk.
CoreExport AppDataChunk* GetAppDataChunk ( Class_ID  cid,
SClass_ID  sid,
DWORD  sbid 
)

Retrieves the application/plugin specific (custom) data stored with an Animatable.

This method is used to retrieve a pointer to an AppDataChunk. The chunk is identified using the Class_ID, SuperClassID and sub-chunk ID of the owner.

Parameters:
cid - The Class_ID of the owner of the chunk.
sid - The SuperClassID of the owner of the chunk.
sbid - An extra ID that lets the owner identify its sub-chunks.
Returns:
A pointer to the previously stored AppDataChunk, or NULL if it could not be found.
See also:
class AppDataChunk.
CoreExport BOOL RemoveAppDataChunk ( Class_ID  cid,
SClass_ID  sid,
DWORD  sbid 
)

Deletes the application/plugin specific (custom) data stored with an Animatable.

This method is used to delete an AppDataChunk. The chunk is identified using the Class_ID, SuperClassID and sub-chunk ID of the owner.

Parameters:
cid - The Class_ID of the owner of the chunk.
sid - The SuperClassID of the owner of the chunk.
sbid - An extra ID that lets the owner identify its sub-chunks.
Returns:
TRUE if the data was deleted, FALSE if it could not be found.
CoreExport void ClearAllAppData ( )

Deletes all application/plugin specific (custom) data stored with an Animatable.

Calling this method will remove all the AppData associated with this Animatable.

Note:
Plugins that call this method will erase all appdata chunks, not just their own. Therefore, it is usually more appropriate to call RemoveAppDataChunk() to remove custom application data associated with a specific Class_ID.
virtual CoreExport void MouseCycleCompleted ( TimeValue  t ) [virtual]
Remarks:
This method is available in release 2.0 and later only (previously in Class Control in 1.x).

This method is called on whatever controller the user is modifying with the mouse -- when the mouse button is released. For example when the user selects a node in the viewports, then drags, then releases the mouse button, this method is called. This method will also be called when the user clicks on a key in the track view and lets up. If a controller performs extensive calculation in its evaluation this method is handy. The controller could perhaps perform a simplified calculation during interactive adjustment of a node. Then when the user releases the mouse button this method is called and the extensive calculations are performed.

The default implementation of this method is recursive so it gets called on all sub-anims affected by a range bar operation.
Parameters:
t The time the mouse was released.
virtual CoreExport void MouseCycleStarted ( TimeValue  t ) [virtual]
Remarks:
This method is called on whatever controller the user is modifying with the mouse -- when the mouse button is pressed.

The default implementation of this method is recursive so it gets called on all sub-anims affected by a range bar operation.
Parameters:
t The time the mouse was first pressed.
virtual int NumParamBlocks ( ) [inline, virtual]
virtual IParamBlock2* GetParamBlock ( int  i ) [inline, virtual]
virtual IParamBlock2* GetParamBlockByID ( short  id ) [inline, virtual]
CoreExport bool SvSaveData ( ISave isave,
USHORT  id 
)
Remarks:
This method is available in release 3.0 and later only.

Implemented by the System.

This is the save method for schematic view data. For classes derived from ReferenceMaker, there is no need to call these. However, if you have a class derived from Animatable and it appears in the schematic view and you want to save schematic view properties for the object (node position, selection state, etc.) then you have to call this in your Save() method.
Parameters:
isave An interface for saving data. See Class ISave.
id The Chunk id (choosen by the developer).
Returns:
Returns true if saved okay; otherwise false.
CoreExport bool SvLoadData ( ILoad iLoad )
Remarks:
Implemented by the System.

This is the load method for schematic view data. For classes derived from ReferenceMaker, there is no need to call these. However, if you have a class derived from Animatable and it appears in the schematic view and you want to load schematic view properties for the object (node position, selection state, etc.) then you have to call this in your Load() method.
Parameters:
iLoad An interface for loading data. See Class ILoad.
Returns:
Returns true if loaded okay; otherwise false.
CoreExport DWORD SvGetRefIndex ( )
Remarks:
This method is for internal use only.
CoreExport void SvSetRefIndex ( DWORD  i )
Remarks:
This method is for internal use only.
CoreExport bool SvDeleteRefIndex ( )
Remarks:
This method is for internal use only.
Operators:
virtual CoreExport SvGraphNodeReference SvTraverseAnimGraph ( IGraphObjectManager gom,
Animatable owner,
int  id,
DWORD  flags 
) [virtual]
Remarks:
This method is available in release 3.0 and later only.

This method traverses the graph of objects in the 3ds Max scene, adding desired objects to the schematic view. Developers can specialize this behaviour by overriding this method and adding whatever objects are interesting to the schematic view. Objects are added to the schematic view by calling IGraphObjectManager::AddAnimatable(...). Reference lines are added to the schematic view by calling IGraphObjectManager::AddReference(...). Implementers of this method should call it recursively to process other objects in the scene.

See Class IGraphObjectManager.
Parameters:
gom Points to the schematic view window manager.
owner The owning animatable.
id This is usually the sub-anim number (but can actually be any value the developer chooses).
flags See List of Schematic %View AddAnimatable Flags.
Returns:
A SvGraphNodeReference object.

Reimplemented in Control, CustAttrib, MtlBase, Texmap, UVGen, XYZGen, TextureOutput, Object, Modifier, SpecialFX, and SimpleWSMMod.

CoreExport SvGraphNodeReference SvStdTraverseAnimGraph ( IGraphObjectManager gom,
Animatable owner,
int  id,
DWORD  flags 
)
Remarks:
This method is a default graph traversal function which can be called from SvTraverseAnimGraph(...) above to handle graph traversal in simple cases. This traversal follows the sub-anim and child references. See the code below.
Parameters:
gom Points to the schematic view window manager.
owner The owning animatable.
id This is usually the sub-anim number (but can actually be any value the developer chooses).
flags See List of Schematic %View AddAnimatable Flags.
Returns:
A SvGraphNodeReference object.
Default Implementation:
        // A default graph traversal function which can be
        // called from SvTraverseAnimGraph(...) to handle
        // graph traversal in simple cases. Follows sub-anim
        // and child references...
        SvGraphNodeReference Animatable::SvStdTraverseAnimGraph(IGraphObjectManager *gom, Animatable *owner, int id, DWORD flags)
        {
            int i;
            SvGraphNodeReference nodeRef;
            SvGraphNodeReference childNodeRef;
            gom->PushLevel(this);
            nodeRef = gom->AddAnimatable(this, owner, id, flags);
            if (nodeRef.stat == SVT_PROCEED) {
                for (i = 0; i < NumSubs(); i++) {
                    if (SubAnim(i)) {
                        childNodeRef = SubAnim(i)->SvTraverseAnimGraph(gom, this, i, flags);
                        if (childNodeRef.stat != SVT_DO_NOT_PROCEED)
                            gom->AddReference(nodeRef.gNode, childNodeRef.gNode, REFTYPE_SUBANIM);
                    }
                }
            }
            gom->PopLevel();
            return nodeRef;
        }
virtual CoreExport bool SvCanInitiateLink ( IGraphObjectManager gom,
IGraphNode gNode 
) [virtual]
Remarks:
Returns true if this animatable can be the initiator of a link operation in the schematic view.
Parameters:
gom Points to the schematic view window manager.
gNode Points to this node in the schematic view.

Reimplemented in Control, Mtl, and Modifier.

virtual CoreExport bool SvCanConcludeLink ( IGraphObjectManager gom,
IGraphNode gNode,
IGraphNode gNodeChild 
) [virtual]
Remarks:
Returns true if this animatable can be the receiver (parent) of a link operation in the schematic view.
Parameters:
gom Points to the schematic view window manager.
gNode Points to this node in the schematic view.
gNodeChild Points to the child node in the schematic view.
Default Implementation:
{ return false; }

Reimplemented in Control, and Modifier.

virtual CoreExport MSTR SvGetName ( IGraphObjectManager gom,
IGraphNode gNode,
bool  isBeingEdited 
) [virtual]
Remarks:
Returns the name of the object as it appears in the schematic view.
Parameters:
gom Points to the schematic view window manager.
gNode Points to this node in the schematic view.
isBeingEdited TRUE if the item is being edited; FALSE if not.
Default Implementation:
        {
            Animatable *owner;
            int subNum;
            MSTR name;
            owner = gNode->GetOwner();
            subNum = gNode->GetID();
            name = owner->SubAnimName(subNum);
            return name;
        }

Reimplemented in Control, MtlBase, UVGen, XYZGen, TextureOutput, Object, and Modifier.

virtual CoreExport bool SvCanSetName ( IGraphObjectManager gom,
IGraphNode gNode 
) [virtual]
Remarks:
Return true to permit the object's name to be edited in the schematic view.
Parameters:
gom Points to the schematic view window manager.
gNode Points to this node in the schematic view.
Default Implementation:
{ return false; }

Reimplemented in MtlBase, and Modifier.

virtual CoreExport bool SvSetName ( IGraphObjectManager gom,
IGraphNode gNode,
MSTR name 
) [virtual]
Remarks:
Called when the user changes the name of the object in the schematic view.
Parameters:
gom< Points to the schematic view window manager.
gNode Points to this node in the schematic view.
name The new name to set.
Returns:
TRUE if the name was changed; FALSE if not.

Reimplemented in MtlBase, and Modifier.

virtual CoreExport bool SvCanRemoveThis ( IGraphObjectManager gom,
IGraphNode gNode 
) [virtual]
Remarks:
This method is available in release 3.0 and later only.

Return true if this object can be removed in the schematic view; false if not.
Parameters:
gom Points to the schematic view window manager.
gNode Points to this node in the schematic view.
Default Implementation:
{ return false; }

Reimplemented in Modifier.

virtual CoreExport bool SvRemoveThis ( IGraphObjectManager gom,
IGraphNode gNode 
) [virtual]

Called when the user deletes this object in the schematic view...

Parameters:
gom Points to the schematic view window manager.
gNode Points to this node in the schematic view.
Returns:
true if deleted; false if not.

Reimplemented in Modifier.

virtual CoreExport bool SvIsSelected ( IGraphObjectManager gom,
IGraphNode gNode 
) [virtual]

Returns true if the object is selected in its schematic view.

Reimplemented in MtlBase, Object, and Modifier.

virtual CoreExport bool SvIsHighlighted ( IGraphObjectManager gom,
IGraphNode gNode 
) [virtual]
Remarks:
Returns true if the object is to be highlighted in the schematic view; otherwise false.
Parameters:
gom Points to the schematic view window manager.
gNode Points to this node in the schematic view.
Default Implementation:
{ return false; }
virtual CoreExport COLORREF SvHighlightColor ( IGraphObjectManager gom,
IGraphNode gNode 
) [virtual]
Remarks:
This method is available in release 3.0 and later only.

Returns the highlight color for this node. The highlight color is used to outline nodes in the schematic view when SvIsHighlighted(...) returns true.
Parameters:
gom Points to the schematic view window manager.
gNode Points to this node in the schematic view.
Returns:
See COLORREF-DWORD format.
Default Implementation:
{ return gom->SvGetUIColor(SV_UICLR_PLUGIN_HIGHLIGHT); }

Reimplemented in MtlBase, Object, and Modifier.

virtual CoreExport COLORREF SvGetSwatchColor ( IGraphObjectManager gom,
IGraphNode gNode 
) [virtual]
Remarks:
This method is available in release 3.0 and later only.

Returns a color which is used to paint the triangular color swatch that appears in the upper-right hand corner of the node in the schematic view. One can return SV_NO_SWATCH to indicate that no swatch is to be drawn.
Parameters:
gom Points to the schematic view window manager.
gNode Points to this node in the schematic view.
Returns:
See COLORREF-DWORD format.
Default Implementation:
{ return SV_NO_SWATCH; }
virtual CoreExport bool SvIsInactive ( IGraphObjectManager gom,
IGraphNode gNode 
) [virtual]
Remarks:
This method is available in release 3.0 and later only.

Returns true if this object is inactive; false is active. The schematic view draws inactive nodes in a grayed-out state.
Parameters:
gom Points to the schematic view window manager.
gNode Points to this node in the schematic view.
Default Implementation:
{ return false; }
virtual CoreExport bool SvLinkChild ( IGraphObjectManager gom,
IGraphNode gNodeThis,
IGraphNode gNodeChild 
) [virtual]
Remarks:
This method is called to link this object to the gNodeChild passed.
Parameters:
gom Points to the schematic view window manager.
gNodeThis Points to this node in the schematic view.
gNodeChild Points to the child node in the schematic view.
Returns:
true if linked; false if not.
Default Implementation:
{ return false; }

Reimplemented in Control, and Modifier.

virtual CoreExport bool SvHandleDoubleClick ( IGraphObjectManager gom,
IGraphNode gNode 
) [virtual]
Remarks:
This method is available in release 3.0 and later only.

This method is called when this node is double-clicked in the schematic view.
Parameters:
gom Points to the schematic view window manager.
gNode Points to the node in the schematic view.
Returns:
true is handled; false if not interested in the event.
Default Implementation:
{ return false; }

Reimplemented in Control, MtlBase, Object, and Modifier.

virtual CoreExport MultiSelectCallback* SvGetMultiSelectCallback ( IGraphObjectManager gom,
IGraphNode gNode 
) [virtual]
Remarks:
This method is called before a multiple select/deselect operation in the schematic view. Returns a callback used to perform the (de)selection. May return NULL if this object cannot be selected in some principle editor outside the schematic view.
Parameters:
gom Points to the schematic view window manager.
gNode Points to the node in the schematic view.
Returns:
A pointer to the callback object. See Class MultiSelectCallback.
Default Implementation:
{ return NULL; }

Reimplemented in MtlBase, Object, and Modifier.

virtual CoreExport bool SvCanSelect ( IGraphObjectManager gom,
IGraphNode gNode 
) [virtual]
Remarks:
Returns true if this object can be selected in some editor (viewport, material editor, plug-in specific editor, etc.). Selection is actually accomplished by via the SvGetMultiSelectCallback(...) mechanism described above.
Parameters:
gom Points to the schematic view window manager.
gNode Points to the node in the schematic view.
Default Implementation:
{ return false; }

Reimplemented in MtlBase, Object, and Modifier.

virtual CoreExport bool SvEditProperties ( IGraphObjectManager gom,
IGraphNode gNode 
) [virtual]
Remarks:
This method is reserved for future use.
Default Implementation:
{ return false; }

Reimplemented in Control.

virtual CoreExport MSTR SvGetTip ( IGraphObjectManager gom,
IGraphNode gNode 
) [virtual]
Remarks:
Returns a string to be displayed in the tip window for this object in the schematic view.
Parameters:
gom Points to the schematic view window manager.
gNode Points to the node in the schematic view.
Default Implementation:
{ return SvGetName(gom, gNode, false); }
virtual CoreExport MSTR SvGetRefTip ( IGraphObjectManager gom,
IGraphNode gNode,
IGraphNode gNodeMaker 
) [virtual]
Remarks:
Returns a string to be displayed in the tip window in the schematic view for a reference from "gNodeMaker" to this.
Parameters:
gom Points to the schematic view window manager.
gNode Points to the node in the schematic view.
gNodeMaker Points to the Maker node in the schematic view.
Sample Code:
        {
            return gNodeMaker->GetAnim()->SvGetName(gom, gNodeMaker, false) + " -> " + SvGetName(gom, gNode, false);
        }
virtual CoreExport bool SvCanDetach ( IGraphObjectManager gom,
IGraphNode gNode 
) [virtual]
Remarks:
Returns true is this object can respond to the SvDetach(...) method; false if not.
Parameters:
gom Points to the schematic view window manager.
gNode Points to the node in the schematic view.
Default Implementation:
{ return false;}
virtual CoreExport bool SvDetach ( IGraphObjectManager gom,
IGraphNode gNode 
) [virtual]
Remarks:
This method is called to detach this object from its owner.
Parameters:
gom Points to the schematic view window manager.
gNode Points to the node in the schematic view.
Returns:
Returns true if detached; otherwise false.
Default Implementation:
{ return false;}
virtual CoreExport MSTR SvGetRelTip ( IGraphObjectManager gom,
IGraphNode gNodeTarget,
int  id,
IGraphNode gNodeMaker 
) [virtual]

Returns a string to be displayed in the tip window in the schematic view for a relationship from "gNodeMaker" to "gNodeTarget"...

Parameters:
gom Points to the schematic view window manager.
gNodeTarget the IGraphNode that represents the target of the relationship.
id The value passed as the IGraphObjectManager::AddRelationship ID parameter. Usually the subanim number.
gNodeMaker The IGraphNode that represents the maker of the relationship (the animatable being called)
Returns:
A string to be displayed in the tooltip
Sample Code
        {
            return SvGetName(gom, gNodeMaker, false) + " -> " + gNodeTarget->GetAnim()->SvGetName(gom, gNodeTarget, false);
        }
virtual CoreExport bool SvCanDetachRel ( IGraphObjectManager gom,
IGraphNode gNodeTarget,
int  id,
IGraphNode gNodeMaker 
) [virtual]

Returns true if this object can respond to the SvDetachRel(...) method...

Parameters:
gom Points to the schematic view window manager.
gNodeTarget the IGraphNode that represents the target of the relationship.
id The value passed as the IGraphObjectManager::AddRelationship ID parameter. Usually the subanim number.
gNodeMaker The IGraphNode that represents the maker of the relationship (the animatable being called)
Returns:
true if this animatable can process a call to SvDetachRel
Default Implementation:
        {
            return false;
        }
virtual CoreExport bool SvDetachRel ( IGraphObjectManager gom,
IGraphNode gNodeTarget,
int  id,
IGraphNode gNodeMaker 
) [virtual]

Detach this relationship.

gNodeMaker is called to detach gNodeTarget

Parameters:
gom Points to the schematic view window manager.
gNodeTarget the IGraphNode that represents the target of the relationship.
id The value passed as the IGraphObjectManager::AddRelationship ID parameter. Usually the subanim number.
gNodeMaker The IGraphNode that represents the maker of the relationship (the animatable being called)
Returns:
true if the relationship was detached
Default Implementation:
        {
            return false;
        }
virtual CoreExport bool SvHandleRelDoubleClick ( IGraphObjectManager gom,
IGraphNode gNodeTarget,
int  id,
IGraphNode gNodeMaker 
) [virtual]

Called when this relationship is double-clicked in the schematic view...

Parameters:
gom Points to the schematic view window manager.
gNodeTarget the IGraphNode that represents the target of the relationship.
id The value passed as the IGraphObjectManager::AddRelationship ID parameter. Usually the subanim number.
gNodeMaker The IGraphNode that represents the maker of the relationship (the animatable being called)
Returns:
true if the double click was handled
Default Implementation:
        {
            return false;
        }
CoreExport ICustAttribContainer* GetCustAttribContainer ( )

This method returns a pointer to the custom attributes container interface class.

See Class ICustAttribContainer for more information.

CoreExport void AllocCustAttribContainer ( )

This method allocates space for a custom attributes container.

CoreExport void DeleteCustAttribContainer ( )

This method deletes space used by a custom attributes container.

virtual bool IsParamBlockDesc2Used ( ParamBlockDesc2 desc ) [inline, virtual]

Returns true if the passed description is being used.

When plugins use a dynamic Paramblock2 system, and build a ParamBlockDesc2 on demand, the list maintained by the ClassDesc may not reflect the active configuration in the plugin. This method lets the system filter the list maintained by asking the plugin (such as the DxMaterial) whether the current ParamBlockDesc2 is currently used by the plugin. Anybody querying the ClassDesc for the ParamBlockDesc2 needs to make sure that the descriptor is currently being used by the plugin.
This mostly goes for maxscript.

Parameters:
desc The description to test
Returns:
true if the plugin is currently using a parameter block built from desc.
Default Implementation:
        {
            return false;
        }  
{ return true; }

Friends And Related Function Documentation

friend class ISaveImp [friend]
friend class ILoadImp [friend]

Member Data Documentation

DWORD aflag [protected]
AnimPropertyList aprops [protected]

Animatable Animatable Animatable Animatable Animatable Animatable Animatable Animatable Animatable Animatable
Animatable Animatable Animatable Animatable Animatable Animatable Animatable Animatable Animatable Animatable