#include <iskin.h>
Public Member Functions |
|
GizmoClass () | |
int | NumParamBlocks () |
IParamBlock2 * | GetParamBlock (int i) |
IParamBlock2 * | GetParamBlockByID (BlockID id) |
int | NumRefs () |
Returns the total number of references this
ReferenceMaker can hold. |
|
RefTargetHandle | GetReference (int i) |
Returns the 'i-th' reference. |
|
void | DeleteThis ()=0 |
int | NumSubs () |
Animatable * | SubAnim (int i) |
MSTR | SubAnimName (int i) |
int | SubNumToRefNum (int subNum) |
RefResult | NotifyRefChanged (Interval changeInt, RefTargetHandle hTarget, PartID &partID, RefMessage message) |
Receives and responds to messages. |
|
virtual void | BeginEditParams (IObjParam *ip, ULONG flags, Animatable *prev) |
virtual void | EndEditParams (IObjParam *ip, ULONG flags, Animatable *next) |
virtual IOResult | Load (ILoad *iload) |
Called for loading data. |
|
virtual IOResult | Save (ISave *isave) |
Called for saving data. |
|
virtual void | GetWorldBoundBox (TimeValue t, INode *inode, ViewExp *vpt, Box3 &box, ModContext *mc) |
virtual int | Display (TimeValue t, GraphicsWindow *gw, Matrix3 tm) |
virtual Interval | LocalValidity (TimeValue t) |
virtual BOOL | IsEnabled () |
virtual BOOL | IsVolumeBased () |
virtual BOOL | IsInVolume (Point3 p, Matrix3 tm) |
virtual Point3 | DeformPoint (TimeValue t, int index, Point3 initialP, Point3 p, Matrix3 tm) |
virtual void | SetInitialName () |
virtual const MCHAR * | GetName () |
virtual void | SetName (const MCHAR *name) |
virtual void | SetName (MCHAR *name) |
virtual BOOL | InitialCreation (int count, Point3 *p, int numbeOfInstances, int *mapTable) |
virtual void | PreDeformSetup (TimeValue t) |
virtual void | PostDeformSetup (TimeValue t) |
virtual IGizmoBuffer * | CopyToBuffer () |
virtual void | PasteFromBuffer (IGizmoBuffer *buffer) |
virtual void | Enable (BOOL enable) |
virtual BOOL | IsEditing () |
virtual void | EndEditing () |
virtual void | EnableEditing (BOOL enable) |
virtual int | HitTest (TimeValue t, INode *inode, int type, int crossing, int flags, IPoint2 *p, ViewExp *vpt, ModContext *mc, Matrix3 tm) |
virtual void | SelectSubComponent (HitRecord *hitRec, BOOL selected, BOOL all, BOOL invert=FALSE) |
virtual void | Move (TimeValue t, Matrix3 &partm, Matrix3 &tmAxis, Point3 &val, Matrix3 tm, BOOL localOrigin=FALSE) |
virtual void | GetSubObjectCenters (SubObjAxisCallback *cb, TimeValue t, INode *node, Matrix3 tm) |
virtual void | GetSubObjectTMs (SubObjAxisCallback *cb, TimeValue t, INode *node, Matrix3 tm) |
virtual void | ClearSelection (int selLevel) |
virtual void | SelectAll (int selLevel) |
virtual void | InvertSelection (int selLevel) |
Public Attributes |
|
ISkin * | bonesMod |
IParamBlock2 * | pblock_gizmo_data |
Protected Member Functions |
|
virtual void | SetReference (int i, RefTargetHandle rtarg) |
Stores a
ReferenceTarget as its 'i-th' reference`. |
GizmoClass | ( | ) | [inline] |
{ pblock_gizmo_data = NULL; bonesMod = NULL; }
int NumParamBlocks | ( | ) | [inline, virtual] |
Reimplemented from Animatable.
{ return 1; }
IParamBlock2* GetParamBlock | ( | int | i | ) | [inline, virtual] |
Reimplemented from Animatable.
{ if (i == 0) return pblock_gizmo_data; else return NULL; }
IParamBlock2* GetParamBlockByID | ( | BlockID | id | ) | [inline, virtual] |
Reimplemented from Animatable.
{ if (pblock_gizmo_data->ID() == id) return pblock_gizmo_data ; else return NULL; }
int NumRefs | ( | ) | [inline, virtual] |
Returns the total number of references this ReferenceMaker can hold.
The plugin implements this method to indicate the total number of of references it can make. This includes all references whether they are NULL (inactive) or non-NULL (active) at the time when this method is called. A plugin can hold a variable number of references, thus the return value of this method is not to be cached and reused by client code.
Reimplemented from ReferenceMaker.
{return 1;}
RefTargetHandle GetReference | ( | int | i | ) | [inline, virtual] |
Returns the 'i-th' reference.
The plugin implements this method to return its 'i-th' reference. The plug-in simply keeps track of its references using an integer index for each one. This method is normally called by the system.
i | - The index of the reference to retrieve. Valid values are from 0 to NumRefs()-1. |
Reimplemented from ReferenceMaker.
{ if (i==0) { return (RefTargetHandle)pblock_gizmo_data; } return NULL; }
virtual void SetReference | ( | int | i, |
RefTargetHandle | rtarg | ||
) | [inline, protected, virtual] |
Stores a ReferenceTarget as its 'i-th' reference`.
The plugin implements this method to store the reference handle passed to it as its 'i-th' reference. In its implementation of this method, the plugin should simply assign the reference handle passed in as a parameter to the member variable that holds the 'i-th' reference. Other reference handling methods such as ReferenceMaker::DeleteReference(), or ReferenceMaker::ReplaceReference() should not be called from within this method. The plugin itself or other plugins should not call this method directly. The system will call this method when a new reference is created or an existing one is replaced by calling ReferenceMaker::ReplaceReference().
i | - The index of the reference to store. Valid values are from 0 to NumRefs()-1. |
rtarg | - The reference handle to store. |
Reimplemented from ReferenceMaker.
{ if (i==0) { pblock_gizmo_data = (IParamBlock2*)rtarg; } }
void DeleteThis | ( | ) | [pure virtual] |
int NumSubs | ( | ) | [inline, virtual] |
Reimplemented from Animatable.
{return 1;}
Animatable* SubAnim | ( | int | i | ) | [inline, virtual] |
i | This is the index of the sub-anim to return. |
Reimplemented from Animatable.
{ return GetReference(i);}
MSTR SubAnimName | ( | int | i | ) | [inline, virtual] |
i | The index of the parameter name to return |
Reimplemented from Animatable.
{return _M(""); }
int SubNumToRefNum | ( | int | subNum | ) | [inline, virtual] |
subNum | The anim index to return the corresponding reference index of. |
Reimplemented from Animatable.
{return -1;}
RefResult NotifyRefChanged | ( | Interval | changeInt, |
RefTargetHandle | hTarget, | ||
PartID & | partID, | ||
RefMessage | message | ||
) | [inline, virtual] |
Receives and responds to messages.
A plugin which makes references must implement a method to receive and respond to messages broadcast by its dependents. This is done by implementing NotifyRefChanged(). The plugin developer usually implements this method as a switch statement where each case is one of the messages the plugin needs to respond to. The Method StdNotifyRefChanged calls this, which can change the partID to new value. If it doesn't depend on the particular message& partID, it should return REF_DONTCARE.
changeInt | - This is the interval of time over which the message is active. Currently, all plug-ins will receive FOREVER for this interval. |
hTarget | - This is the handle of the reference target the message was sent by. The reference maker uses this handle to know specifically which reference target sent the message. |
partID | - This contains information specific to the message passed in. Some messages don't use the partID at all. See the section List of Reference Messages for more information about the meaning of the partID for some common messages. |
message | - The message parameters passed into this method is the specific message which needs to be handled. |
Implements ReferenceMaker.
{
return REF_SUCCEED;
}
virtual void BeginEditParams | ( | IObjParam * | ip, |
ULONG | flags, | ||
Animatable * | prev | ||
) | [inline, virtual] |
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 from Animatable.
{}
virtual void EndEditParams | ( | IObjParam * | ip, |
ULONG | flags, | ||
Animatable * | next | ||
) | [inline, virtual] |
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 from Animatable.
{}
Called for loading data.
Called by the system to allow the plug-in to load its data. See the section on Loading and Saving for an overview of the load - save process.
iload | - This interface pointer may be used to call methods to read data from disk. |
Reimplemented from ReferenceMaker.
{return IO_OK;}
Called for saving data.
Called by the system to allow the plugin to save its data.
isave | - This pointer may be used to call methods to write data to disk. See the section on Loading and Saving for an overview of the load/save process. |
Reimplemented from ReferenceMaker.
{return IO_OK;}
virtual void GetWorldBoundBox | ( | TimeValue | t, |
INode * | inode, | ||
ViewExp * | vpt, | ||
Box3 & | box, | ||
ModContext * | mc | ||
) | [inline, virtual] |
virtual int Display | ( | TimeValue | t, |
GraphicsWindow * | gw, | ||
Matrix3 | tm | ||
) | [inline, virtual] |
{ return 1;}
virtual Interval LocalValidity | ( | TimeValue | t | ) | [inline, virtual] |
{return FOREVER;}
virtual BOOL IsEnabled | ( | ) | [inline, virtual] |
{ return TRUE; }
virtual BOOL IsVolumeBased | ( | ) | [inline, virtual] |
{return FALSE;}
{ return FALSE;}
virtual Point3 DeformPoint | ( | TimeValue | t, |
int | index, | ||
Point3 | initialP, | ||
Point3 | p, | ||
Matrix3 | tm | ||
) | [inline, virtual] |
{return p;}
virtual void SetInitialName | ( | ) | [inline, virtual] |
{}
virtual const MCHAR* GetName | ( | ) | [inline, virtual] |
{return NULL;}
virtual void SetName | ( | const MCHAR * | name | ) | [inline, virtual] |
{}
virtual void SetName | ( | MCHAR * | name | ) | [inline, virtual] |
{ SetName(const_cast<const MCHAR*>(name)); }
virtual BOOL InitialCreation | ( | int | count, |
Point3 * | p, | ||
int | numbeOfInstances, | ||
int * | mapTable | ||
) | [inline, virtual] |
{ return TRUE;}
virtual void PreDeformSetup | ( | TimeValue | t | ) | [inline, virtual] |
{}
virtual void PostDeformSetup | ( | TimeValue | t | ) | [inline, virtual] |
{}
virtual IGizmoBuffer* CopyToBuffer | ( | ) | [inline, virtual] |
{ return NULL;}
virtual void PasteFromBuffer | ( | IGizmoBuffer * | buffer | ) | [inline, virtual] |
{}
virtual void Enable | ( | BOOL | enable | ) | [inline, virtual] |
{}
virtual BOOL IsEditing | ( | ) | [inline, virtual] |
{ return FALSE;}
virtual void EndEditing | ( | ) | [inline, virtual] |
{}
virtual void EnableEditing | ( | BOOL | enable | ) | [inline, virtual] |
{}
virtual int HitTest | ( | TimeValue | t, |
INode * | inode, | ||
int | type, | ||
int | crossing, | ||
int | flags, | ||
IPoint2 * | p, | ||
ViewExp * | vpt, | ||
ModContext * | mc, | ||
Matrix3 | tm | ||
) | [inline, virtual] |
{return 0;}
virtual void SelectSubComponent | ( | HitRecord * | hitRec, |
BOOL | selected, | ||
BOOL | all, | ||
BOOL | invert =
FALSE |
||
) | [inline, virtual] |
{}
virtual void Move | ( | TimeValue | t, |
Matrix3 & | partm, | ||
Matrix3 & | tmAxis, | ||
Point3 & | val, | ||
Matrix3 | tm, | ||
BOOL | localOrigin =
FALSE |
||
) | [inline, virtual] |
{}
virtual void GetSubObjectCenters | ( | SubObjAxisCallback * | cb, |
TimeValue | t, | ||
INode * | node, | ||
Matrix3 | tm | ||
) | [inline, virtual] |
{}
virtual void GetSubObjectTMs | ( | SubObjAxisCallback * | cb, |
TimeValue | t, | ||
INode * | node, | ||
Matrix3 | tm | ||
) | [inline, virtual] |
{}
virtual void ClearSelection | ( | int | selLevel | ) | [inline, virtual] |
{}
virtual void SelectAll | ( | int | selLevel | ) | [inline, virtual] |
{}
virtual void InvertSelection | ( | int | selLevel | ) | [inline, virtual] |
{}