iparamb.h File Reference
 
 
 
iparamb.h File Reference

This reference page is linked to from the following overview topics: Creating the Parameter Block and Referencing It, Creating a Parameter Block 1.


#include "maxheap.h"
#include "ref.h"
#include "ioapi.h"
#include "paramtype.h"

Classes

class   UserType
class   GetParamName
class   GetParamDim
class   ParamBlockDesc
class   ParamBlockDescID
class   IParamArray
class   IParamBlock
class   ParamVersionDesc
class   ParamBlockPLCB
  This is a handy post load call back for fixing up parameter blocks. This will look up the version of the loaded callback and fix it up so it matches the current version. NOTE: this deletes itself when its done. See Parameter Maps for more details. More...
class   ParamBlockPLCBEx
  Extension of the ParamBlockPLCB class. More...

Defines

#define  PB_COUNT_CHUNK   0x0001
#define  PB_PARAM_CHUNK   0x0002
#define  PB_INDEX_CHUNK   0x0003
#define  PB_ANIMATABLE_CHUNK   0x0004
#define  PB_VERSION_CHUNK   0x0005
#define  PB_LOCKED_CHUNK   0x0006
#define  PB_FLOAT_CHUNK   (TYPE_FLOAT + 0x100)
#define  PB_INT_CHUNK   (TYPE_INT + 0x100)
#define  PB_RGBA_CHUNK   (TYPE_RGBA + 0x100)
#define  PB_POINT3_CHUNK   (TYPE_POINT3 + 0x100)
#define  PB_BOOL_CHUNK   (TYPE_BOOL + 0x100)
#define  PB_TYPE_CHUNK   0x0200
#define  PB_TYPE_FLOAT_CHUNK   (PB_TYPE_CHUNK + TYPE_FLOAT)
#define  PB_TYPE_INT_CHUNK   (PB_TYPE_CHUNK + TYPE_INT)
#define  PB_TYPE_RGBA_CHUNK   (PB_TYPE_CHUNK + TYPE_RGBA)
#define  PB_TYPE_POINT3_CHUNK   (PB_TYPE_CHUNK + TYPE_POINT3)
#define  PB_TYPE_BOOL_CHUNK   (PB_TYPE_CHUNK + TYPE_BOOL)
#define  PB_TYPE_USER_CHUNK   (PB_TYPE_CHUNK + TYPE_USER)

Functions

CoreExport IParamBlock CreateParameterBlock (ParamBlockDesc *pdesc, int count)
CoreExport IParamBlock CreateParameterBlock (ParamBlockDescID *pdesc, int count, DWORD version)
CoreExport IParamBlock UpdateParameterBlock (ParamBlockDescID *pdescOld, int oldCount, IParamBlock *oldPB, ParamBlockDescID *pdescNew, int newCount, DWORD newVersion)

Define Documentation

#define PB_COUNT_CHUNK   0x0001
#define PB_PARAM_CHUNK   0x0002
#define PB_INDEX_CHUNK   0x0003
#define PB_ANIMATABLE_CHUNK   0x0004
#define PB_VERSION_CHUNK   0x0005
#define PB_LOCKED_CHUNK   0x0006
#define PB_FLOAT_CHUNK   (TYPE_FLOAT + 0x100)
#define PB_INT_CHUNK   (TYPE_INT + 0x100)
#define PB_RGBA_CHUNK   (TYPE_RGBA + 0x100)
#define PB_POINT3_CHUNK   (TYPE_POINT3 + 0x100)
#define PB_BOOL_CHUNK   (TYPE_BOOL + 0x100)
#define PB_TYPE_CHUNK   0x0200
#define PB_TYPE_FLOAT_CHUNK   (PB_TYPE_CHUNK + TYPE_FLOAT)
#define PB_TYPE_INT_CHUNK   (PB_TYPE_CHUNK + TYPE_INT)
#define PB_TYPE_RGBA_CHUNK   (PB_TYPE_CHUNK + TYPE_RGBA)
#define PB_TYPE_POINT3_CHUNK   (PB_TYPE_CHUNK + TYPE_POINT3)
#define PB_TYPE_BOOL_CHUNK   (PB_TYPE_CHUNK + TYPE_BOOL)
#define PB_TYPE_USER_CHUNK   (PB_TYPE_CHUNK + TYPE_USER)

Function Documentation

CoreExport IParamBlock* CreateParameterBlock ( ParamBlockDesc pdesc,
int  count 
)
Remarks:
Implemented by the System.

This method is used to create a parameter block.
Parameters:
ParamBlockDesc *pdesc

This is an array of parameter block descriptors.

int count

This is the number in the array.
Returns:
A pointer to the created parameter block. On error NULL is returned.
CoreExport IParamBlock* CreateParameterBlock ( ParamBlockDescID pdesc,
int  count,
DWORD  version 
)
Remarks:
Implemented by the System.

This method is used to create a parameter block with a version number to aide in backwards compatibility.
Parameters:
ParamBlockDesc *pdesc

This is an array of parameter block descriptors.

int count

This is the number in the array.

DWORD version

This is used to indicate a version of the parameter block. This is used for backwards compatibility when loading 3ds Max files that were saved with a previous version of the parameter block structure. There is a mechanism which allows the older format to be converted to the newer format so the older files may still be loaded and used. See the Advanced Topics section on Parameter Maps for more information.
Returns:
A pointer to the created parameter block. On error NULL is returned.
CoreExport IParamBlock* UpdateParameterBlock ( ParamBlockDescID pdescOld,
int  oldCount,
IParamBlock oldPB,
ParamBlockDescID pdescNew,
int  newCount,
DWORD  newVersion 
)
Remarks:
Implemented by the System.

This creates a new parameter block, based on an existing parameter block of a later version. The new parameter block inherits any parameters from the old parameter block whose parameter IDs match.
Parameters:
ParamBlockDescID *pdescOld

The existing parameter block descriptor.

int oldCount

The number of old parameters.

IParamBlock *oldPB

The old parameter block.

ParamBlockDescID *pdescNew

The new parameter block descriptor.

int newCount

The number of new parameters.

DWORD newVersion

The version of the new parameter block.
Returns:
The new parameter block.