This reference page is linked to from the following overview topics: Major New Features, SDK Change Details.
IContainer13 Interface.
IContainer13 extends container object functionality. In particular it provides support for new access rules that inherited containers may follow.
Previously, containers would only allow for no access when inherited or access to edit in place so that a user can save over the original definition. Now in addition a container can grant access to only add new objects over the inherited container or get full freedom to access anything that was unlocked on the original source definition. For the latter case the user can specify additional locks over certain items, such as all materials, all modifiers, all transforms or all objects, to restrict what's accessible further.
#include <IContainerObject.h>
Public Types |
|
enum | AccessType { eNoAccess = 0x0, eOnlyEditInPlace, eOnlyAddNewObjects, eAnythingUnlocked } |
Access possibilities for when a container is inherited. More... |
|
enum | LockedContents { eLockAllMaterials = 0x1, eLockAllModifiers = 0x2, eLockAllTransforms = 0x4, eLockAllObjects = 0x8 } |
Possibilities for items that may get locked when the AccessType is eAnythingUnlocked. More... |
|
enum | ProxyType { PROXYTYPE_NONE, PROXYTYPE_ALTERNATE } |
Public Member Functions |
|
virtual bool | SaveContainerAsVersion (bool newFileName, unsigned long saveAsVersion)=0 |
Saves the content and rules as the new
definition into a format compatible with the specified 3ds Max
version If there is no definition file name, the user will be
prompted for one. |
|
virtual MCHAR * | GetStatusString ()=0 |
Returns a status string for the container.
|
|
virtual void | SetStatusDisplay (bool status)=0 |
Sets whether the container displays its
status in the 3D viewports. |
|
virtual bool | GetStatusDisplay () const =0 |
Returns whether the container displays its
status in the 3D viewports. |
|
virtual const MCHAR * | GetEditingUser () const =0 |
Returns the user name currently editing the
definition for the container. |
|
virtual bool | IsUpdateNeeded () const =0 |
Returns whether the container is out of date
with its definition. |
|
virtual bool | IsInheritedClosed () const =0 |
Returns whether the container is both
inherited and its content is not currently local. |
|
Access Type
|
|
virtual void | SetAccessType (AccessType accessType)=0 |
Set the type of access for this container
when it gets inherited by another container. |
|
virtual AccessType | GetAccessType () const =0 |
Returns the type of access that the
container will provide when inherited. |
|
virtual AccessType | InheritedAccessType () const =0 |
Returns the type of access that the
container has based upon the access provided by its inherited
source. |
|
Locked Contents
|
|
virtual void | SetLockedContents (LockedContents content, bool clear)=0 |
Set what will be automatically locked when
the access type is set to AccessType::eAnythingUnlocked. |
|
virtual void | ClearLockedContents ()=0 |
Clear the locked content rules so that
nothing is automatically locked. |
|
virtual bool | IsLockedContents (LockedContents content) const =0 |
Get if this content will be automatically
locked when the access type is set to
AccessType::eAnythingUnlocked. |
|
Container proxies
|
|
Proxies offer the possibility to represent container content by something other than their definition. The following are the proxy types currently supported: PROXYTYPE_NONE: (default value) the container displays its definition PROXYTYPE_ALTERNATE: the container will display one of possibly several alternate definitions, one of which is current. |
|
virtual ProxyType | GetProxyType () const =0 |
Returns the proxy type used by the
container. |
|
virtual void | SetProxyType (ProxyType type)=0 |
Sets the proxy type used by the container.
|
|
virtual int | GetAlternateDefinitionCount () const =0 |
Returns the number of alternate definitions
for the container. |
|
virtual MaxSDK::AssetManagement::AssetUser |
GetAlternateDefinition (int defIndex) const =0 |
Returns the alternate definition for the
container from an index. |
|
virtual bool | SetAlternateDefinition (int defIndex, const MaxSDK::AssetManagement::AssetUser &val)=0 |
Sets an alternate definition for the
container. |
|
virtual bool | AppendAlternateDefinition (const MaxSDK::AssetManagement::AssetUser &val)=0 |
Appends one alternate definition to the
container alternate definitions. |
|
virtual bool | RemoveAlternateDefinition (int defIndex)=0 |
Removes one alternate definition from the
container alternate definitions. |
|
virtual int | GetCurrentAlternateDefinitionIndex () const =0 |
Returns the zero-based index of the current
alternate definition of the container. |
|
virtual void | SetCurrentAlternateDefinitionIndex (int defIndex)=0 |
Sets the current alternate definition of the
container. |
|
virtual MaxSDK::AssetManagement::AssetUser |
GetCurrentAlternateDefinition () const =0 |
Returns the current alternate definition of
the container. |
|
Static Public Member Functions |
|
static IContainerObject13 * | GetInterface (Animatable *anim) |
If the Animatable supports the IContainerObject13 interface, returns
a pointer to it. |
enum AccessType |
Access possibilities for when a container is inherited.
{ eNoAccess = 0x0, eOnlyEditInPlace , eOnlyAddNewObjects, eAnythingUnlocked};
enum LockedContents |
Possibilities for items that may get locked when the AccessType is eAnythingUnlocked.
eLockAllMaterials |
All materials are locked. |
eLockAllModifiers |
All modifiers are locked. |
eLockAllTransforms |
All transforms are locked. |
eLockAllObjects |
All objects are locked. |
{ eLockAllMaterials =0x1, eLockAllModifiers = 0x2 , eLockAllTransforms =0x4, eLockAllObjects= 0x8};
enum ProxyType |
virtual void SetAccessType | ( | AccessType | accessType | ) | [pure virtual] |
Set the type of access for this container when it gets inherited by another container.
This replaces IContainerObject::SetEditInPlace since different levels of access are now supported.
[in] | accessType | - |
virtual AccessType GetAccessType | ( | ) | const [pure virtual] |
Returns the type of access that the container will provide when inherited.
virtual AccessType InheritedAccessType | ( | ) | const [pure virtual] |
Returns the type of access that the container has based upon the access provided by its inherited source.
If it has no inherited source it will default to return the same value as IContainerObject13::GetAccessType.
virtual void SetLockedContents | ( | LockedContents | content, |
bool | clear | ||
) | [pure virtual] |
Set what will be automatically locked when the access type is set to AccessType::eAnythingUnlocked.
param[in] content - Type of content that will be automatically locked.
[in] | clear | - If true then clear any other locked content enum that was set, and only set the specified one. If false, then keep the other specified locked content types also. |
virtual void ClearLockedContents | ( | ) | [pure virtual] |
Clear the locked content rules so that nothing is automatically locked.
virtual bool IsLockedContents | ( | LockedContents | content | ) | const [pure virtual] |
Get if this content will be automatically locked when the access type is set to AccessType::eAnythingUnlocked.
param[in] - content The content type that we are checking to see if it will be locked.
virtual bool SaveContainerAsVersion | ( | bool | newFileName, |
unsigned long | saveAsVersion | ||
) | [pure virtual] |
Saves the content and rules as the new definition into a format compatible with the specified 3ds Max version If there is no definition file name, the user will be prompted for one.
[in] | newFileName | - if true, prompt the user for a definition file name |
[in] | saveAsVersion | - the version of 3ds Max in which the file is to be saved. Currently it supports saving to the current version of 3ds Max (MAX_RELEASE) and to 3ds Max 2010 (MAX_RELEASE_R12). |
virtual MCHAR* GetStatusString | ( | ) | [pure virtual] |
Returns a status string for the container.
virtual void SetStatusDisplay | ( | bool | status | ) | [pure virtual] |
Sets whether the container displays its status in the 3D viewports.
virtual bool GetStatusDisplay | ( | ) | const [pure virtual] |
Returns whether the container displays its status in the 3D viewports.
virtual const MCHAR* GetEditingUser | ( | ) | const [pure virtual] |
Returns the user name currently editing the definition for the container.
virtual bool IsUpdateNeeded | ( | ) | const [pure virtual] |
Returns whether the container is out of date with its definition.
virtual ProxyType GetProxyType | ( | ) | const [pure virtual] |
Returns the proxy type used by the container.
virtual void SetProxyType | ( | ProxyType | type | ) | [pure virtual] |
Sets the proxy type used by the container.
virtual int GetAlternateDefinitionCount | ( | ) | const [pure virtual] |
Returns the number of alternate definitions for the container.
virtual MaxSDK::AssetManagement::AssetUser GetAlternateDefinition | ( | int | defIndex | ) | const [pure virtual] |
Returns the alternate definition for the container from an index.
[in] | defIndex | - zero-based index of the alternate definition file to retrieve |
virtual bool SetAlternateDefinition | ( | int | defIndex, |
const MaxSDK::AssetManagement::AssetUser & | val | ||
) | [pure virtual] |
Sets an alternate definition for the container.
[in] | defIndex | - zero-based index of the alternate definition file to set. The index must be less than the current number of alternate definitions |
[in] | val | - an alternate definition file: either an empty asset or an asset of type kContainerAsset |
virtual bool AppendAlternateDefinition | ( | const MaxSDK::AssetManagement::AssetUser & | val | ) | [pure virtual] |
Appends one alternate definition to the container alternate definitions.
[in] | val | - an alternate definition file: either an empty asset or an asset of type kContainerAsset |
virtual bool RemoveAlternateDefinition | ( | int | defIndex | ) | [pure virtual] |
Removes one alternate definition from the container alternate definitions.
[in] | defIndex | - zero-based index of the alternate definition file to remove. |
virtual int GetCurrentAlternateDefinitionIndex | ( | ) | const [pure virtual] |
Returns the zero-based index of the current alternate definition of the container.
virtual void SetCurrentAlternateDefinitionIndex | ( | int | defIndex | ) | [pure virtual] |
Sets the current alternate definition of the container.
[in] | defIndex | - zero-based index of the alternate definition to set as current. The index must be less than the current number of alternate definitions |
virtual MaxSDK::AssetManagement::AssetUser GetCurrentAlternateDefinition | ( | ) | const [pure virtual] |
Returns the current alternate definition of the container.
virtual bool IsInheritedClosed | ( | ) | const [pure virtual] |
Returns whether the container is both inherited and its content is not currently local.
static IContainerObject13* GetInterface | ( | Animatable * | anim | ) | [inline, static] |
If the Animatable supports the IContainerObject13 interface, returns a pointer to it.
[in] | anim | - Animatable to be tested for support of the IContainer interface. |
Reimplemented from IContainerObject.
{ return anim? static_cast<IContainerObject13*>(anim->GetInterface(IID_CONTAINER13)): NULL;}