Class INodeExposure

3DS Max Plug-In SDK

Class INodeExposure

class INodeExposure: public FPMixinInterface

Description:

This class is only available in release 5 or later.

This interface provides the ability for a node to define whether it is visible in any of max’s dialog boxes. This interface will be extended and used by more of 3ds max’s core utilities, but currently ONLY TrackView and the Select Object/HideObject dialog box use this interface. By default this interface is not available through the default nodes, it needs to be added.

 

To get a pointer to this interface from a node the following code can be used.

 

INodeExposure* iNE = (INodeExposure*)node->GetInterface(NODEEXPOSURE_INTERFACE_TOAPPEND)

 

This will add a new INodeExposure interface to the node if it is not present. The next time you use this technique it will only return the interface and not create another new interface.

 

Data Members:

enum { 

  kSelectObjects, kSchematicView, kMaxscript,

  kMerge, kMergeAnimation, kReplace,

  kKeyEditor, kCurveEditor, kRangeEditor,

 };

 

This enum provides access to the different supported UI elements. It is used with various methods of the class to get/set the UI flags.

 

Methods:

Prototype:

bool IsExposedInTrackView() const

Remarks:

This will return true if it is visible in TrackView or false if it is not. This will return TRUE is the node is exposed in ANY of the TrackView states, kKeyEditor, kCurveEditor and kRangeEditor. It will return FALSE if ALL are set to false.

 

Prototype:

void SetExposedInTrackView(bool state)

Remarks:

This allows the state of the TrackView exposure flag to be set by the user. This will set the flag for all three TrackView flags. See comment in IsExposedInTrackView().

 

Prototype:

bool IsExposedInKeyEditor() const

Remarks:

Specifies whether the node is visible in the Key Editor of TrackView

Prototype:

void SetExposedInKeyEditor(bool state)

Remarks:

This allows the state of the Key Editor of Trackview exposure flag to be set by the user.

 

Prototype:

bool IsExposedInCurveEditor() const

Remarks:

Specifies whether the node is visible in the Function Curve Editor of Track View

Prototype:

void SetExposedInCurveEditor(bool state)

Remarks:

This allows the state of the Function Curve Editor of Track view exposure flag to be set by the user.

 

Prototype:

bool IsExposedInRangeEditor() const

Remarks:

Specifies whether the node is visible in the Key Range Editor of Track View

Prototype:

void SetExposedInRnageEditor(bool state)

Remarks:

This allows the state of the Key Range Editor of Track view exposure flag to be set by the user.

 

Prototype:

bool IsExposedInSelectObjects() const

Remarks:

This will return true if it is visible in Selected Objects/HideObjects Dialog box otherwise false

 

Prototype:

void SetExposedInSelectObjects (bool state)

Remarks:

This will set the flag for the exposure in Selected Objects/HideObjects dialog box

 

Parameters:

bool state

The value to set the flag

 

Prototype:

virtual bool IsExposed(int ui) const =0

Remarks:

This will return the exposure state of the UI element being queried

 

Parameters:

int ui

The UI flag to query. This should be a value from the UI enum – See data members section

 

 

Prototype:

virtual void SetExposed(bool state) const =0

Remarks:

This will set the state of all the UI elements to the state passed into the method

 

Parameters:

bool state

The state to set the nodes UI exposure

 

Prototype:

virtual void SetExposed(bool state, int ui) const =0

Remarks:

This will set the state of the individual UI element to the state passed into the method

 

Parameters:

bool state

The state to set the nodes UI exposure

int ui

The UI element to set