3ds Max C++ API Reference
|
This API is meant to be implemented by plugins and used by renderers to instantiate objects at render-time. More...
Classes | |
struct | ChannelInfo |
struct | InstanceMatIDInfo |
Material ID overrides. More... | |
struct | InstanceUVWInfo |
UVW channel override data. More... | |
struct | MotionBlurInfo |
Motion blur information struct. More... | |
class | RenderInstanceSource |
Information about a given source, to be instanced multiple times. More... | |
class | RenderInstanceTarget |
Information about a given instance of a RenderInstanceSource. More... | |
class | RenderTimeInstancingInterface |
The RenderTimeInstancingInterface allows a renderer to access an object's instancing information so that it can do efficient instancing at render-time. More... | |
Typedefs | |
typedef int | ChannelID |
A data channel ID. | |
Enumerations | |
enum | DataFlags : signed int { df_none = 0 , df_mesh = 1 << 0 , df_inode = 1 << 1 , df_pluginMustDelete = 1 << 31 } |
Defines what the RenderInstanceSource::GetData() method returns and how to treat it. More... | |
Functions | |
RenderTimeInstancingInterface * | GetRenderTimeInstancingInterface (BaseObject *obj) |
This API is meant to be implemented by plugins and used by renderers to instantiate objects at render-time.
As an example, let's say that you write an object plugin that allows users to create a new geometric primitive called SuperTeapot. If you implemented this API in your object plugin, and if your renderer used it, you could do things like have a single SuperTeapot in your scene that's rendered as 1000 teapots, each with unique transformation matrices, materials, material IDs, UVWs, etc.
This API consists of three classes:
It's easier to understand how those classes are related by starting with the last one and moving up the list:
If you, for example, wanted to instantiate a teapot 100 times and a box 200 times in your plugin, then:
For an example of how to implement this API in an object plugin, see the RenderTimeInstancedObject sample project. For an example of how to use this API in a renderer, see the description of the RenderTimeInstancingInterface class.
A data channel ID.
An opaque integer token that represents a data channel. Used to actually retrieve the channel's data.
Defines what the RenderInstanceSource::GetData() method returns and how to treat it.
Enumerator | |
---|---|
df_none | |
df_mesh | The RenderInstanceSource::GetData() method returns a pointer to a Mesh. |
df_inode | The RenderInstanceSource::GetData() method returns a pointer to an INode. |
df_pluginMustDelete | Set if the renderer is expected to delete the data pointer after it's done using it. |
|
inline |