ClassDesc2 Class Reference

ClassDesc2 Class Reference
+ Related help topics:

#include <iparamb2.h>

Class Description

See also
Class ClassDesc, Class Animatable, Class ParamBlockDesc2, Class IParamMap2, Class IObjParam, Class ParamMap2UserDlgProc, Class IAutoMParamDlg.

Description:
A subclass of ClassDesc which you specialize to provide a class descriptor for plug-in classes that will use the ParamBlock2 system. It contains a table of ParamBlockDesc2s for all the parameter blocks used in the plug-in and a number of sets of methods including access to the block descriptors, auto user interface management, auto param block2 construction, and access to any automatically-maintained ParamMap2s.
+ Inheritance diagram for ClassDesc2:

Public Member Functions

PB2Export ClassDesc2 ()
 
PB2Export ~ClassDesc2 ()
 
PB2Export void ResetClassParams (BOOL fileReset)
 
PB2Export int NumParamBlockDescs ()
 
PB2Export ParamBlockDesc2GetParamBlockDesc (int i)
 
PB2Export ParamBlockDesc2GetParamBlockDescByID (BlockID id)
 
PB2Export ParamBlockDesc2GetParamBlockDescByName (const MCHAR *name)
 
PB2Export void AddParamBlockDesc (ParamBlockDesc2 *pbd)
 
PB2Export void ClearParamBlockDescs ()
 
PB2Export void BeginEditParams (IObjParam *ip, ReferenceMaker *obj, ULONG flags, Animatable *prev)
 
PB2Export void EndEditParams (IObjParam *ip, ReferenceMaker *obj, ULONG flags, Animatable *prev)
 
PB2Export void InvalidateUI ()
 
PB2Export void InvalidateUI (ParamBlockDesc2 *pbd)
 
PB2Export void InvalidateUI (ParamBlockDesc2 *pbd, ParamID id, int tabIndex=-1)
 
PB2Export void MakeAutoParamBlocks (ReferenceMaker *owner)
 
PB2Export int NumParamMaps ()
 
PB2Export IParamMap2GetParamMap (int i)
 
PB2Export IParamMap2GetParamMap (ParamBlockDesc2 *pbd, MapID map_id=0)
 
PB2Export bool SetUserDlgProc (ParamBlockDesc2 *pbd, MapID map_id, ParamMap2UserDlgProc *proc=NULL)
 
bool SetUserDlgProc (ParamBlockDesc2 *pbd, ParamMap2UserDlgProc *proc=NULL)
 
PB2Export ParamMap2UserDlgProcGetUserDlgProc (ParamBlockDesc2 *pbd, MapID map_id=0)
 
PB2Export IAutoMParamDlgCreateParamDlgs (HWND hwMtlEdit, IMtlParams *imp, ReferenceTarget *obj)
 
PB2Export IAutoMParamDlgCreateParamDlg (BlockID id, HWND hwMtlEdit, IMtlParams *imp, ReferenceTarget *obj, MapID mapID=0)
 
PB2Export IAutoEParamDlgCreateParamDialogs (IRendParams *ip, SpecialFX *obj)
 
PB2Export IAutoRendererParamDlgCreateParamDialogs (IRendParams *ip, Renderer &renderer)
 Creates the automatically-managed parameter dialogs defined with the P_AUTO_UI or P_AUTO_UI_QT flags in the parameter block descriptors. More...
 
PB2Export IAutoRendererParamDlgCreateParamDialog (BlockID id, IRendParams *ip, Renderer &renderer, MapID mapID)
 Creates the automatically-managed parameter dialog for the given parameter block and parameter map only. More...
 
PB2Export IAutoEParamDlgCreateParamDialog (BlockID id, IRendParams *ip, SpecialFX *obj, MapID mapID=0)
 
PB2Export void MasterDlgDeleted (IAutoMParamDlg *dlg)
 
PB2Export void MasterDlgDeleted (IAutoEParamDlg *dlg)
 
PB2Export void MasterDlgDeleted (IAutoRendererParamDlg &dlg)
 Used internally. More...
 
PB2Export IAutoMParamDlgGetMParamDlg ()
 
PB2Export IAutoEParamDlgGetEParamDlg ()
 
PB2Export void RestoreRolloutState ()
 
PB2Export ParamID LastNotifyParamID (ReferenceMaker *owner, IParamBlock2 *&pb)
 
PB2Export void Reset (ReferenceMaker *owner, BOOL updateUI=TRUE, BOOL callSetHandlers=TRUE)
 
PB2Export void GetValidity (ReferenceMaker *owner, TimeValue t, Interval &valid)
 
PB2Export void RemoveParamBlockDesc (ParamBlockDesc2 *pbd)
 
virtual MaxSDK::QMaxParamBlockWidgetCreateQtWidget (ReferenceMaker &owner, IParamBlock2 &paramBlock, const MapID paramMapID, MSTR &rollupTitle, int &rollupFlags, int &rollupCategory)
 Creates a Qt widget to be associated with the given parameter map ID. More...
 
virtual MaxSDK::QMaxParamBlockWidgetCreateQtWidget (ReferenceMaker &owner, IParamBlock2 &paramBlock, const MapID paramMapID, MSTR &rollupTitle, int &rollupFlags, int &rollupCategory, Class_ID &tabID)
 Creates a Qt widget that is connected to the given parameter block. More...
 
- Public Member Functions inherited from ClassDesc
virtual ~ClassDesc ()
 
virtual int IsPublic ()=0
 Controls if the plug-in shows up in lists from the user to choose from. More...
 
virtual const MCHARClassName ()=0
 This method returns the name of the class. More...
 
virtual SClass_ID SuperClassID ()=0
 This method returns a system defined constant describing the class this plug-in class was derived from. More...
 
virtual Class_ID ClassID ()=0
 This method must return the unique ID for the object. More...
 
virtual const MCHARCategory ()=0
 This methods returns a string describing the category a plug-in fits into. More...
 
virtual DWORD InitialRollupPageState ()
 This method returns a DWORD which is used to initialize the rollup state in both the create branch and the modify branch. More...
 
virtual const MCHARInternalName ()
 Returns a string which provides a fixed, machine parsable internal name for the plug-in. More...
 
virtual bool UseOnlyInternalNameForMAXScriptExposure ()
 Returns true if only the InternalName is to be used for MAXScript exposure. More...
 
virtual HINSTANCE HInstance ()
 Returns the DLL instance handle of the plug-in. More...
 
virtual CoreExport const MCHARGetRsrcString (INT_PTR id)
 Returns a pointer to the string from the resource string table. More...
 
virtual Class_ID SubClassID ()
 This method can be used for further categorizing plugins. More...
 
virtual voidCreate (BOOL loading=FALSE)=0
 3ds Max calls this method when it needs a pointer to a new instance of the plug-in class. More...
 
virtual int BeginCreate (Interface *i)
 The custom creation process of the plug-in object is handled by this method. More...
 
virtual int EndCreate (Interface *i)
 The termination of the custom creation process is managed by the implementation of this method. More...
 
virtual BOOL OkToCreate (Interface *i)
 This method is used to enable or disable the button that allows the plug-ins class to be created. More...
 
virtual BOOL HasClassParams ()
 If a plug-in class has default parameters that it needs to allow the user to edit, TRUE should be returned and EditClassParams() and ResetClassParams() should be implemented. More...
 
virtual void EditClassParams (HWND hParent)
 If the user picks the class from the list this method is called. More...
 
virtual int NumActionTables ()
 3ds Max calls this to get the number of action tables a plug-in has. More...
 
virtual ActionTableGetActionTable (int i)
 Returns a pointer to the specified action table. More...
 
virtual BOOL IsManipulator ()
 Returns TRUE if the class implements a manipulator object; otherwise FALSE. More...
 
virtual BOOL CanManipulate (ReferenceTarget *hTarget)
 The method returns true if the class is a manipulator and it manipulates the given base object, modifier or controller. More...
 
virtual BOOL CanManipulateNode (INode *pNode)
 Returns TRUE if the manipulator applies to the given node; otherwise FALSE. More...
 
virtual ManipulatorCreateManipulator (ReferenceTarget *hTarget, INode *pNode)
 Creates a manipulator object When a manipulator returns TRUE to CanManipulate(ReferenceTarget* hTarget), the system calls this version of CreateManipulator() to create an instance of the manipulator. More...
 
virtual ManipulatorCreateManipulator (INode *pNode)
 Creates a manipulator object. More...
 
virtual BOOL NeedsToSave ()
 Returns TRUE if there is data associated with the class that needs to be saved in the 3ds Max file. More...
 
virtual IOResult Save (ISave *isave)
 If NeedsToSave() returns TRUE then this method should be implemented to save the data associated with the class. More...
 
virtual IOResult Load (ILoad *iload)
 If NeedsToSave() returns TRUE then this method should be implemented to load the data associated with the class. More...
 
virtual IParamMap2GetParamMap (ParamBlockDesc2 *pbd)
 Returns a pointer to the parameter map2 whose descriptor is passed. More...
 
virtual ParamMap2UserDlgProcGetUserDlgProc (ParamBlockDesc2 *pbd)
 Returns a pointer to the parameter map 2 user dialog proc (if any) for the specified descriptor. More...
 
virtual bool DrawRepresentation (COLORREF bkColor, HDC hDC, Rect &rect)
 Allows a plug-in to provide a custom image for display in Schematic View. More...
 
virtual int NumInterfaces ()
 Returns the number of function publishing interfaces maintained by the class descriptor. More...
 
virtual FPInterfaceGetInterfaceAt (int i)
 Returns the nth function publishing interface. More...
 
virtual CoreExport FPInterfaceGetInterface (Interface_ID id)
 Returns a pointer to the function publishing interface whose ID is specified. More...
 
virtual CoreExport FPInterfaceGetInterface (const MCHAR *name)
 Returns a pointer to the function publishing interface whose name is specified. More...
 
virtual CoreExport void AddInterface (FPInterface *fpi)
 Adds the specified interface to the list maintained by this class descriptor. More...
 
virtual void ClearInterfaces ()
 Deletes all the interfaces maintained by the class descriptor. More...
 
virtual INT_PTR Execute (int cmd, ULONG_PTR arg1=0, ULONG_PTR arg2=0, ULONG_PTR arg3=0)
 This function is maintained so the 3ds Max SDK can be extended without breaking backwards compatibility. More...
 

Protected Member Functions

void SetMParamDlg (IAutoMParamDlg *dlg)
 Sets the root level material ParamDlg. More...
 
void SetEParamDlg (IAutoEParamDlg *dlg)
 Sets the root level effect ParamDlg. More...
 
Tab< IParamMap2 * > & GetParamMaps ()
 

Additional Inherited Members

- Static Public Member Functions inherited from MaxHeapOperators
static UtilExport voidoperator new (size_t size)
 Standard new operator used to allocate objects If there is insufficient memory, an exception will be thrown. More...
 
static UtilExport voidoperator new (size_t size, const std::nothrow_t &e)
 Standard new operator used to allocate objects if there is insufficient memory, NULL will be returned. More...
 
static UtilExport voidoperator new (size_t size, const char *filename, int line)
 New operator used to allocate objects that takes the filename and line number where the new was called If there is insufficient memory, an exception will be thrown. More...
 
static UtilExport voidoperator new (size_t size, int block_type, const char *filename, int line)
 New operator used to allocate objects that takes the type of memory, filename and line number where the new was called If there is insufficient memory, an exception will be thrown. More...
 
static UtilExport voidoperator new (size_t size, const std::nothrow_t &e, const char *filename, int line)
 New operator used to allocate objects that takes the filename and line number where the new was called If there is insufficient memory, NULL will be returned. More...
 
static UtilExport voidoperator new (size_t size, unsigned long flags)
 New operator used to allocate objects that takes extra flags to specify special operations If there is insufficient memory, an exception will be thrown. More...
 
static UtilExport voidoperator new (size_t size, const std::nothrow_t &e, unsigned long flags)
 New operator used to allocate objects that takes extra flags to specify special operations If there is insufficient memory, NULL will be returned. More...
 
static UtilExport voidoperator new[] (size_t size)
 New operator used to allocate arrays of objects If there is insufficient memory, an exception will be thrown. More...
 
static UtilExport voidoperator new[] (size_t size, const std::nothrow_t &e)
 New operator used to allocate arrays of objects If there is insufficient memory, NULL will be returned. More...
 
static UtilExport voidoperator new[] (size_t size, const char *filename, int line)
 New operator used to allocate arrays of objects If there is insufficient memory, an exception will be thrown. More...
 
static UtilExport voidoperator new[] (size_t size, int block_type, const char *filename, int line)
 New operator used to allocate arrays of objects. More...
 
static UtilExport voidoperator new[] (size_t size, const std::nothrow_t &e, const char *filename, int line)
 New operator used to allocate arrays of objects If there is insufficient memory, NULL will be returned. More...
 
static UtilExport voidoperator new[] (size_t size, unsigned long flags)
 New operator used to allocate arrays of objects If there is insufficient memory, an exception will be thrown. More...
 
static UtilExport voidoperator new[] (size_t size, const std::nothrow_t &e, unsigned long flags)
 New operator used to allocate arrays of objects If there is insufficient memory, NULL will be returned. More...
 
static UtilExport void operator delete (void *ptr)
 Standard delete operator used to deallocate an object If the pointer is invalid, an exception will be thrown. More...
 
static UtilExport void operator delete (void *ptr, const std::nothrow_t &e)
 Standard delete operator used to deallocate an object If the pointer is invalid, nothing will happen. More...
 
static UtilExport void operator delete (void *ptr, const char *filename, int line)
 Delete operator used to deallocate an object that takes the filename and line number where the delete was called If the pointer is invalid, an exception will be thrown. More...
 
static UtilExport void operator delete (void *ptr, int block_type, const char *filename, int line)
 Delete operator used to deallocate an object that takes the type of memory, filename and line number where the delete was called If the pointer is invalid, an exception will be thrown. More...
 
static UtilExport void operator delete (void *ptr, const std::nothrow_t &e, const char *filename, int line)
 Delete operator used to deallocate an object that takes the filename and line number where the delete was called If the pointer is invalid, nothing will happen. More...
 
static UtilExport void operator delete (void *ptr, unsigned long flags)
 Delete operator used to deallocate an object that takes extra flags to specify special operations If the pointer is invalid, an exception will be thrown. More...
 
static UtilExport void operator delete (void *ptr, const std::nothrow_t &e, unsigned long flags)
 Delete operator used to deallocate an object that takes extra flags to specify special operations If the pointer is invalid, nothing will happen. More...
 
static UtilExport void operator delete[] (void *ptr)
 Standard delete operator used to deallocate an array of objects If the pointer is invalid, an exception will be thrown. More...
 
static UtilExport void operator delete[] (void *ptr, const std::nothrow_t &e)
 Standard delete operator used to deallocate an array of objects If the pointer is invalid, nothing will happen. More...
 
static UtilExport void operator delete[] (void *ptr, const char *filename, int line)
 Delete operator used to deallocate an array of objects that takes the filename and line number where the delete was called If the pointer is invalid, an exception will be thrown. More...
 
static UtilExport void operator delete[] (void *ptr, int block_type, const char *filename, int line)
 Delete operator used to deallocate an array of objects that takes the type of memory, filename and line number where the delete was called If the pointer is invalid, an exception will be thrown. More...
 
static UtilExport void operator delete[] (void *ptr, const std::nothrow_t &e, const char *filename, int line)
 Delete operator used to deallocate an array of objects that takes the filename and line number where the delete was called If the pointer is invalid, nothing will happen. More...
 
static UtilExport void operator delete[] (void *ptr, unsigned long flags)
 Delete operator used to deallocate an array of objects that takes extra flags to specify special operations If the pointer is invalid, an exception will be thrown. More...
 
static UtilExport void operator delete[] (void *ptr, const std::nothrow_t &e, unsigned long flags)
 Delete operator used to deallocate an array of objects that takes extra flags to specify special operations If the pointer is invalid, an exception will be thrown. More...
 
static UtilExport voidoperator new (size_t size, void *placement_ptr)
 Placement new operator. More...
 
static UtilExport void operator delete (void *ptr, void *placement_ptr)
 Placement delete operator. More...
 
static UtilExport voidaligned_malloc (size_t size, size_t alignment)
 Allocates memory on a specified alignment boundary. More...
 
static UtilExport voidaligned_realloc (void *ptr, size_t size, size_t alignment)
 Reallocates memory on a specified alignment boundary. More...
 
static UtilExport void aligned_free (void *ptr)
 Frees a block of memory that was allocated with aligned_malloc/aligned_realloc. More...
 

Constructor & Destructor Documentation

Remarks
Constructor. The master ParamDlg and Effect ParamDlg pointers are set to NULL.
Remarks
Destructor.

Member Function Documentation

void SetMParamDlg ( IAutoMParamDlg dlg)
inlineprotected

Sets the root level material ParamDlg.

This method may be called by derived classes that want to handle the material ParamDlg creation themselves, instead of using one of the "paramdlg" creation methods of class ClassDesc2.

Parameters
[in]dlg- The new master Material dialog pointer
2472 { masterMDlg = dlg; }
void SetEParamDlg ( IAutoEParamDlg dlg)
inlineprotected

Sets the root level effect ParamDlg.

This method may be called by derived classes that want to handle the effect ParamDlg creation themselves, instead of using one of the "paramdlg" creation methods of class ClassDesc2.

Parameters
[in]dlg- The new master effect dialog pointer
2479 { masterEDlg = dlg; }
Tab<IParamMap2*>& GetParamMaps ( )
inlineprotected
Remarks
Allows access to the parameter maps currently posted to the UI.
Returns
A Tab containing any current parameter maps
2483 { return paramMaps; }
PB2Export void ResetClassParams ( BOOL  fileReset)
virtual
Remarks
This method may be called to restore all sticky parameters to their default values.
Parameters
fileResetThis parameter is not used.

Reimplemented from ClassDesc.

PB2Export int NumParamBlockDescs ( )
inlinevirtual
Remarks
Implemented by the System.

This is a method of the base class ClassDesc. This class provides an implementation of the method used by plug-ins using the ParamBlock2 system.

Returns the number of parameter block2 descriptors used by this plug-in class.

Reimplemented from ClassDesc.

2504 { return pbDescs.Count(); }
int Count() const
Retrieves the number of items in the Tab.
Definition: tab.h:219
PB2Export ParamBlockDesc2* GetParamBlockDesc ( int  i)
inlinevirtual
Remarks
Implemented by the System.

This is a method of the base class ClassDesc. This class provides an implementation of the method used by plug-ins using the ParamBlock2 system.

Returns a pointer to the 'i-th' parameter block2 descriptor.
Parameters
iThe zero based index of the parameter block2 descriptor to return.

Reimplemented from ClassDesc.

2511 { return pbDescs[i]; }
PB2Export ParamBlockDesc2* GetParamBlockDescByID ( BlockID  id)
virtual
Remarks
Implemented by the System.

This is a method of the base class ClassDesc. This class provides an implementation of the method used by plug-ins using the ParamBlock2 system.

Returns a pointer to the parameter block2 descriptor as specified by its BlockID.

Note: typedef short BlockID;
Parameters
idThe permanent ID for the parameter block.

Reimplemented from ClassDesc.

PB2Export ParamBlockDesc2* GetParamBlockDescByName ( const MCHAR name)
Remarks
Returns a pointer to the parameter block2 descriptor as specified by the descriptor's internal name.
Parameters
nameThe internal name of the parameter block descriptor.
PB2Export void AddParamBlockDesc ( ParamBlockDesc2 pbd)
virtual
Remarks
Implemented by the System.

This is a method of the base class ClassDesc. This class provides an implementation of the method used by plug-ins using the ParamBlock2 system.

Adds a parameter block2 to the list of those maintained by this class descriptor.
Parameters
pbdPoints to the parameter block2 descriptor of the parameter block2 to add.

Reimplemented from ClassDesc.

PB2Export void ClearParamBlockDescs ( )
inline
Remarks
Implemented by the System.

Removes all the parameter block 2 descriptors maintained by this plug-in.
2537 { pbDescs.ZeroCount(); }
void ZeroCount()
Resets the number of used items to zero.
Definition: tab.h:231
PB2Export void BeginEditParams ( IObjParam ip,
ReferenceMaker obj,
ULONG  flags,
Animatable prev 
)
virtual
Remarks
Implemented by the System.

This is a method of the base class ClassDesc. This class provides an implementation of the method used by plug-ins using the ParamBlock2 system.

This method is called to handle the beginning of the automatic command panel user interface management provided by the param map 2 system. This method is called by the plug-in from its Animatable::BeginEditParams() method. The parameters passed to that method are simply passed along to this method.
Parameters
ipThe interface pointer passed to the plug-in.
objPoints to the plug-in class calling this method.
flagsThe flags passed along to the plug-in in Animatable::BeginEditParams().
prevThe pointer passed to the plug-in in Animatable::BeginEditParams().

Reimplemented from ClassDesc.

PB2Export void EndEditParams ( IObjParam ip,
ReferenceMaker obj,
ULONG  flags,
Animatable prev 
)
virtual
Remarks
Implemented by the System.

This is a method of the base class ClassDesc. This class provides an implementation of the method used by plug-ins using the ParamBlock2 system.

This method is called to handle the ending of the automatic command panel user interface management provided by the param map 2 system. This method is called by the plug-in from its Animatable::EndEditParams() method. The parameters passed to that method are simply passed along to this method.
Parameters
ipThe interface pointer passed to the plug-in.
objPoints to the plug-in class calling this method.
flagsThe flags passed along to the plug-in in Animatable::EndEditParams().
prevThe pointer passed to the plug-in in Animatable::EndEditParams().

Reimplemented from ClassDesc.

PB2Export void InvalidateUI ( )
Remarks
Implemented by the System.

This invalidates the entire UI for every parameter map of the plug-in.
PB2Export void InvalidateUI ( ParamBlockDesc2 pbd)
virtual
Remarks
Implemented by the System.

This is a method of the base class ClassDesc. This class provides an implementation of the method used by plug-ins using the ParamBlock2 system.

This is called if the user interface parameters needs to be updated. This invalidates the entire UI managed by the param map whose description is passed.
Parameters
pbdPoints to the parameter block descriptor for the rollup.

Reimplemented from ClassDesc.

PB2Export void InvalidateUI ( ParamBlockDesc2 pbd,
ParamID  id,
int  tabIndex = -1 
)
Remarks
Implemented by the System.

This is called if a certain user interface parameter of the specified parameter map needs to be updated. The parameter ID of the control is passed. If the parameter is a Tab<> then the index into the table of the parameter is passed.
Parameters
pbdPoints to the parameter block descriptor for the rollup.
idThe permanent parameter ID of the parameter.
tabIndexIf the parameter is a Tab<> then this is the zero based index into the table. The default value of -1 indicates it is not a table.
PB2Export void MakeAutoParamBlocks ( ReferenceMaker owner)
virtual
Remarks
Implemented by the System.

This is a method of the base class ClassDesc. This class provides an implementation of the method used by plug-ins using the ParamBlock2 system.

This method is called to create the parameter blocks for the plug-in.
Parameters
ownerPoints to the plug-in class calling this method.

Reimplemented from ClassDesc.

PB2Export int NumParamMaps ( )
inlinevirtual
Remarks
Implemented by the System.

This is a method of the base class ClassDesc. This class provides an implementation of the method used by plug-ins using the ParamBlock2 system.

Returns the number of automatically-maintained parameter map2s.

Reimplemented from ClassDesc.

2609 { return paramMaps.Count(); }
int Count() const
Retrieves the number of items in the Tab.
Definition: tab.h:219
PB2Export IParamMap2* GetParamMap ( int  i)
inlinevirtual
Remarks
Implemented by the System.

This is a method of the base class ClassDesc. This class provides an implementation of the method used by plug-ins using the ParamBlock2 system.

Parameters
iPoints to the parameter block descriptor2 associated with this parameter map.
Returns
A pointer to the parameter map2 as specified by the parameter block2 pointer passed.

Reimplemented from ClassDesc.

2616 { return paramMaps[i]; }
PB2Export IParamMap2* GetParamMap ( ParamBlockDesc2 pbd,
MapID  map_id = 0 
)
Remarks
Implemented by the System.

This is a method of the base class ClassDesc. This class provides an implementation of the method used by plug-ins using the ParamBlock2 system.

Returns a pointer to the parameter map2 as specified by the parameter block2 pointer passed.
Parameters
pbdPoints to the parameter block descriptor2 associated with this parameter map.
map_idThis parameter specifies the ID of the map/rollout to get.
PB2Export bool SetUserDlgProc ( ParamBlockDesc2 pbd,
MapID  map_id,
ParamMap2UserDlgProc proc = NULL 
)
Remarks
This overload of SetUserDlgProc() has a new parameter, map_id, that specifies the ID of the parameter map/rollup to set the user dialog proc for. See original function for the rest of the description.
bool SetUserDlgProc ( ParamBlockDesc2 pbd,
ParamMap2UserDlgProc proc = NULL 
)
inlinevirtual
Remarks
Implemented by the System.

This is a method of the base class ClassDesc. This class provides an implementation of the method used by plug-ins using the ParamBlock2 system.

Returns true if the proc was registered with a parameter map. If the proc was not registered with the parameter map, DeleteThis() will not be called on proc when the user dialog procs are cleared, potentially resulting in leakage of the proc. This method allows the developer to provide special handling for controls not processed automatically by the parameter map (or those that need additional processing). The developer provides a dialog proc to process the messages from the controls. This method is used to tell the parameter map that the developer defined method should be called. The given proc will be called after default processing is done.

Note, in version 4.0 and later, this actually maps to a call on the explicit map ID overload of SetUserDlgProc() with default map ID of 0.
Parameters
pbdPoints to the parameter block descriptor for the parameter map.
procPoints to the class derived from ParamMap2UserDlgProc which handles the controls.

Reimplemented from ClassDesc.

2653 { return SetUserDlgProc(pbd, 0, proc); }
PB2Export bool SetUserDlgProc(ParamBlockDesc2 *pbd, MapID map_id, ParamMap2UserDlgProc *proc=NULL)
PB2Export ParamMap2UserDlgProc* GetUserDlgProc ( ParamBlockDesc2 pbd,
MapID  map_id = 0 
)
Remarks
Implemented by the System.

This is a method of the base class ClassDesc. This class provides an implementation of the method used by plug-ins using the ParamBlock2 system.

Returns a pointer to the user dialog proc associated with the parameter map as specified by the parameter block descriptor2 pointer.
Parameters
pbdPoints to the parameter block descriptor for the parameter map.
map_idSpecifies the ID of the map/rollout to get the user dialog proc for.
PB2Export IAutoMParamDlg* CreateParamDlgs ( HWND  hwMtlEdit,
IMtlParams imp,
ReferenceTarget obj 
)
Remarks
Implemented by the System.

This method creates and returns a pointer to the object which handles the automatic processing of the user interface in the materials editor. This method loops over all parameter blocks which specify AUTO_UI and makes the AutoMParamDlgs for them. The first one becomes the master and the others are added to it.
Parameters
hwMtlEditThe window handle of the materials editor.
impThe interface pointer provided for calling methods in 3ds Max.
objPoints to the plug-in class calling this method.
PB2Export IAutoMParamDlg* CreateParamDlg ( BlockID  id,
HWND  hwMtlEdit,
IMtlParams imp,
ReferenceTarget obj,
MapID  mapID = 0 
)
Remarks
Implemented by the System.

This method creates and returns a pointer to the object which handles the automatic processing of the user interface in the materials editor. This method makes an AutoMParamDlg for the specified parameter block.
Parameters
idThe permanent ID of the parameter block.
hwMtlEditThe window handle of the materials editor.
impThe interface pointer provided for calling methods in 3ds Max.
objPoints to the plug-in class calling this method.
mapIDSpecifies the ID of the map/rollout in the parameter block to create AutoMParamDlg for.
PB2Export IAutoEParamDlg* CreateParamDialogs ( IRendParams ip,
SpecialFX obj 
)
Remarks
Implemented by the System.

This method creates and returns a pointer to the object which handles the automatic processing of the user interface in the rendering effects dialog. This method loops over all parameter blocks which specify AUTO_UI and makes the AutoMParamDlgs for them. The first one becomes the master and the others are added to it.
Parameters
ipThe interface pointer provided for calling methods in 3ds Max.
objPoints to the plug-in class calling this method. See Class SpecialFX.
PB2Export IAutoRendererParamDlg* CreateParamDialogs ( IRendParams ip,
Renderer renderer 
)

Creates the automatically-managed parameter dialogs defined with the P_AUTO_UI or P_AUTO_UI_QT flags in the parameter block descriptors.

This method should generally be called from Renderer::CreateParamDialog().

Parameters
ipThe interface passed to Renderer::CreateParamDialog().
rendererThe renderer for which the dialogs are being created.
Returns
The newly created dialog.
PB2Export IAutoRendererParamDlg* CreateParamDialog ( BlockID  id,
IRendParams ip,
Renderer renderer,
MapID  mapID 
)

Creates the automatically-managed parameter dialog for the given parameter block and parameter map only.

See also
IAutoRendererParamDlg* CreateParamDialogs(IRendParams *ip, Renderer& renderer)
PB2Export IAutoEParamDlg* CreateParamDialog ( BlockID  id,
IRendParams ip,
SpecialFX obj,
MapID  mapID = 0 
)
Remarks
Implemented by the System.

This method creates and returns a pointer to the object which handles the automatic processing of the user interface in the rendering effects dialog. This method makes an AutoEParamDlg for the specified parameter block.
Parameters
idThe permanent ID of the parameter block.
ipThe interface pointer provided for calling methods in 3ds Max.
objPoints to the plug-in class calling this method. See Class SpecialFX.
mapIDSpecifies the ID of the map/rollout in the parameter block to create AutoEParamDlg for.
PB2Export void MasterDlgDeleted ( IAutoMParamDlg dlg)
Remarks
Implemented by the System.

This method is called when an AutoMParamDlg is deleted.
Parameters
dlgPointer to the object which handles the automatic processing of the user interface in the materials editor.
PB2Export void MasterDlgDeleted ( IAutoEParamDlg dlg)
Remarks
Implemented by the System.

This method is called when an AutoEParamDlg is deleted.
Parameters
dlgPointer to the object which handles the automatic processing of the user interface in the rendering effects dialog.
PB2Export void MasterDlgDeleted ( IAutoRendererParamDlg dlg)

Used internally.

Called by the implementation of IAutoRendererParamDlg to un-register itself with the class descriptor.

PB2Export IAutoMParamDlg* GetMParamDlg ( )
inline
Remarks
Implemented by the System.

Returns the master dialog processing routine for the materials editor plug-in.
2735 { return masterMDlg; }
PB2Export IAutoEParamDlg* GetEParamDlg ( )
inline
Remarks
Implemented by the System.

Returns the master dialog processing routine for the rendering effects plug-in.
2739 { return masterEDlg; }
PB2Export void RestoreRolloutState ( )
Remarks
This method may be called to restore any saved rollout state (open/closed condition and scrolling position) for any parameter map maintained by the plug-in.
PB2Export ParamID LastNotifyParamID ( ReferenceMaker owner,
IParamBlock2 *&  pb 
)
Remarks
This method scans all the parameter blocks in the owner and returns the ParamID and parameter block making the most recent change notification.
Parameters
ownerThe owner of the parameter blocks.
pbThe parameter block which made the most recent notification.
Returns
The parameter ID of the parameter which made the most recent notification.
PB2Export void Reset ( ReferenceMaker owner,
BOOL  updateUI = TRUE,
BOOL  callSetHandlers = TRUE 
)
Remarks
This method may be called to reset all the parameters of all known parameter blocks to their default values and optionally update the user interface.
Parameters
ownerThe owner of this ClassDesc2.
updateUIIf TRUE to user interface is updated. If FALSE it's not.
callSetHandlersTRUE to call PBAccessor::Set() for all the parameters; otherwise FALSE.
PB2Export void GetValidity ( ReferenceMaker owner,
TimeValue  t,
Interval valid 
)
Remarks
This method updates the validity interval passed with the cumulative validity interval of all the owner's parameter blocks.
Parameters
ownerThe owner of this ClassDesc2.
tThe time about which to compute the interval.
validThe validity interval to update. The intersection of the provided "valid" interval with the interval for the provided TimeValue and returned as the updated interval value.
PB2Export void RemoveParamBlockDesc ( ParamBlockDesc2 pbd)
Remarks
Implemented by the System.

Removes a parameter block descriptor from the list of those maintained by this class descriptor, but does not delete it. This method would typically be used when a ParamBlockDesc2 is dynamically created and its life cycle is controlled by the plugin. You would then be able to remove the parameter block descriptor from the class descriptor when no instances of the plug-in require it.
Parameters
pbdA pointer to the parameter block descriptor to remove.
MaxSDK::QMaxParamBlockWidget * CreateQtWidget ( ReferenceMaker owner,
IParamBlock2 paramBlock,
const MapID  paramMapID,
MSTR rollupTitle,
int rollupFlags,
int rollupCategory 
)
inlinevirtual

Creates a Qt widget to be associated with the given parameter map ID.

This method should be implemented by the plugin developer in the class descriptor of their plugin. It should instantiate and return a class that inherits from QMaxParamBlockWidget, and that encapsulates a user interface object. The user interface object should be created using a tool like Qt Designer, and it should correspond to the parameter map that is passed in. For a complete example of how to use this method in a plugin, see 'Creating a Qt-based plug-in' in the 3ds Max Developer Guide.

Note that this method and the one below are identical, except that this one lacks the tabID parameter. You should only override the one below if you want to add a Qt widget to the Render Settings dialog. Otherwise, you should override this one.

Parameters
ownerThe owner of the dialog. This will normally be the owner of the parameter block, but in the case of P_CLASS_PARAMS, where the parameter block doesn't have an owner, this will be the object for which the dialog is being displayed.
paramBlockThe parameter block to which the parameter map belongs to. This parameter block must specify the P_AUTO_UI_QT flag, and it must not declare any UI properties using the p_ui flag.
paramMapIDThe ID of the parameter map, as specified in the parameter block descriptor.
[out]rollupTitleOutput parameter used to specify the title to be displayed in the rollup's header.
[out]rollupFlagsOutput parameter used to specify flags such as APPENDROLL_CLOSED.
[out]rollupCategoryOutput parameter used to specify the order in which rollups are positioned with values such as ROLLUP_CAT_STANDARD.
Returns
An instance of a new Qt widget which will be hosted in the parameter map's rollup.
Attention
The ownership of the Qt widget is transferred to the caller.
Remarks
May return a nullptr if no dialog should be shown for the given parameter map.
The default implementation of this method returns a nullptr.
See also
Qt in Parameter Maps and Parameter Blocks.
290 {
291  // Default implementation returns null.
292  // This method only needs to be implemented in plugins with a Qt-based UI that add a Qt widget to any dialog except the Render Settings dialog.
293  return nullptr;
294 }
MaxSDK::QMaxParamBlockWidget * CreateQtWidget ( ReferenceMaker owner,
IParamBlock2 paramBlock,
const MapID  paramMapID,
MSTR rollupTitle,
int rollupFlags,
int rollupCategory,
Class_ID tabID 
)
inlinevirtual

Creates a Qt widget that is connected to the given parameter block.

This method should be implemented by the plugin developer in the class descriptor of their plugin. It should instantiate and return a class that inherits from QMaxParamBlockWidget, and that encapsulates a user interface object. The user interface object should be created using a tool like Qt Designer, and it should correspond to the parameter map that is passed in. For a complete example of how to use this method in a plugin, see 'Creating a Qt-based plug-in' in the 3ds Max Developer Guide.

Note that this method and the one below are identical, except that this one lacks the tabID parameter. You should only override the one below if you want to add a Qt widget to the Render Settings dialog. Otherwise, you should override this one.

Parameters
ownerThe owner of the dialog. This will normally be the owner of the parameter block, but in the case of P_CLASS_PARAMS, where the parameter block doesn't have an owner, this will be the object for which the dialog is being displayed.
paramBlockThe parameter block to which the parameter map belongs to. This parameter block must specify the P_AUTO_UI_QT flag, and it must not declare any UI properties using the p_ui flag.
paramMapIDThe ID of the parameter map, as specified in the parameter block descriptor.
[out]rollupTitleOutput parameter used to specify the title to be displayed in the rollup's header.
[out]rollupFlagsOutput parameter used to specify flags such as APPENDROLL_CLOSED.
[out]rollupCategoryOutput parameter used to specify the order in which rollups are positioned with values such as ROLLUP_CAT_STANDARD.
Returns
An instance of a new Qt widget which will be hosted in the parameter map's rollup.
Attention
The ownership of the Qt widget is transferred to the caller.
Remarks
May return a nullptr if no dialog should be shown for the given parameter map.
The default implementation of this method returns a nullptr.
See also
Qt in Parameter Maps and Parameter Blocks.

You should only override this method if you want to add a Qt widget to the Render Settings dialog. Otherwise, you should override CreateQtWidget(ReferenceMaker& owner, IParamBlock2& paramBlock, const MapID paramMapID, MSTR& rollupTitle, int& rollupFlags, int& rollupCategory).

Parameters
[out]tabIDOutput parameter used to specify the Render Settings dialog tab in which the Qt widget is to be added. To add a Qt widget as a new tab to the Render Settings dialog, assign a unique Class ID to this parameter before returning. To obtain a unique Class ID, run the 3ds Max Class ID generator program, gencid.exe, which is located in your \maxsdk\help\ directory.
Remarks
The default implementation of this method calls the one above, ignoring the tabID parameter.
305 {
306  // Default implementation calls the method above, ignoring the tabID parameter.
307  // This method only needs to be implemented in plugins with a Qt-based UI that add a Qt widget to the Render Settings dialog.
308  return CreateQtWidget(owner, paramBlock, paramMapID, rollupTitle, rollupFlags, rollupCategory);
309 }
virtual MaxSDK::QMaxParamBlockWidget * CreateQtWidget(ReferenceMaker &owner, IParamBlock2 &paramBlock, const MapID paramMapID, MSTR &rollupTitle, int &rollupFlags, int &rollupCategory)
Creates a Qt widget to be associated with the given parameter map ID.
Definition: iparamb2.inline.h:283