IFXModelData |
IFXModelData is the interface to the container component that is used by modifiers (IFXModifier).
IFXModelData provides access to parameters and pointers of a specific element in the scene. That element might be a meshgroup or a particle group. The ModelData container is used to encapsulate the parameters and information related to the element, which may be needed by any given modifier. IFXModelData inherits the IFXUnknown interface, and is supported by the CIFXModelData component.
When to Use
The IFXModelData interface is used to get or set modifier related parameters for a particular object. These parameters are held in a ModelData object (CIFXModelData). Modifiers require an IFXModelData interface from which they can query or set information for the element (model) upon which they are acting. Each model is associated with a list of modifiers, and the single CIFXModelData component is passed along (like a baton in a relay race) from modifier to modifier when the modifier list is triggered. Because the CIFXModelData component must service the needs of all possible modifiers, it contains a wide range of parameters. There are basic parameters, which provide access to the actual geometry of a model; there are parameters that describe which shaders are used to render the different parts of the element; there are parameters that facilitate collision detection; there are parameters which are intended primarily for use by a physics modifier.
Geometry
|
Interface Methods |
Description |
|
Retrieves the IFXMeshGroup interface currently associated with the model data container. |
|
|
Assigns an IFXMeshGroup interface to the model data container |
|
|
Retrieves the IFXUpdatesGroup interface currently associated with the model data container |
|
|
Assigns an IFXUpdatesGroup interface to the model data container |
|
|
Retrieves the IFXEdgeGroup interface currently associated with the model data container |
|
|
Assigns an IFXEdgeGroup interface to the model data container |
|
|
Retrieves the Shader state for the model |
|
|
Retrieves a model's NeighborMesh or creates one if there are no update records |
|
|
Sets the model's modifier generator |
|
|
Gets the model's modifier generator |
Shader mappings for the MeshGroup and EdgeGroup (1:1)
|
Retrieves the IFXStyle interface from the specified entry in the model data's style palette |
|
|
Retrieves the IFXPalette interface for the model data's style palette |
|
|
Assigns an IFXPalette interface to the model data for use as a style palette |
Model sphere bound
|
Recalculates the bounding sphere of the mesh group currently associated with the model data container |
|
|
Retrieves the IFXSGVector representing the mesh group's bounding sphere |
|
|
Assigns the specified IFXSGVector as the bounding sphere of the model data container's mesh group. Useful for avoiding the expensive RebuildBound() call |
|
|
Indicates whether the bound volume updates have been enabled |
Physics
|
Computes the volume of each of the meshes in the mesh group and assigns each volume in the associated volume array |
|
|
Retrieves the volume array of the mesh group currently associated with the model data container |
|
|
Retrieves the coefficient of angular drag associated with the model data container's current mesh group |
|
|
Assigns an angular drag coefficient to the model data container's current mesh group |
|
|
Retrieves the coefficient of linear drag associated with the model data container's current mesh group |
|
|
Assigns a linear drag coefficient to the model data container's current mesh group |
Model bounding hierarchy
|
Retrieves the CIFXBoundHierarchy of the model data container's current mesh group |
|
|
Assigns a CIFXBoundHierarchy to the model data container's current mesh group |
Particle System
|
Retrieves the IFXParticleGroup interface of the particle group currently associated with the model data container |
|
|
Assigns an IFXParticleGroup interface to the model data container |
Bound Hierarchy
|
Indicates whether the flag has been set |
Cache status
|
Gets the modified cache status |
|
|
Sets the modified cache status |
|
|
Sets the modified channel status |
This method retrieves a pointer to an IFXMeshGroup. This is the interface to the mesh group that is currently assigned to the model data container.
Parameters:
|
ppOutMeshGroup |
The address of an IFXMeshGroup interface pointer |
Comments:
The mesh group is not relevant if the model data container is associated with a particle group.
This method assigns an IFXMeshGroup interface to the model data container. This is the interface to the mesh group currently assigned to the model data container.
Parameters:
|
pInMeshGroup |
A pointer to a mesh group interface |
Comments:
The mesh group is not relevant if the model data container is associated with a particle group.
This method retrieves a pointer to an IFXUpdatesGroup. This is the interface to the updates group that is currently assigned to the model data container. UpdateGroups are necessary for MRM level of detail modifications.
Parameters:
|
ppOutUpdatesGroup |
The address of an IFXUpdatesGroup interface pointer |
Comments:
The updates group is not relevant if the model data container is associated with a particle group.
This method assigns an IFXUpdatesGroup interface to the model data container. This is the interface to the updates group currently assigned to the model data container. UpdateGroups are necessary for MRM level of detail modifications.
Parameters:
|
pInUpdatesGroup |
A pointer to an IFXUpdatesGroup interface |
Comments:
The updates group is not relevant if the model data container is associated with a particle group.
This method retrieves a pointer to an IFXEdgeGroup. This is the interface to the edge group that is currently assigned to the model data container. EdgeGroups are used by modifiers that generate or access edgelists for the geometry in the model data. A model data container is not required to have an edge group interface, so this method can legitimately return a NULL pointer.
Parameters:
|
ppOutEdgeGroup |
The address of an IFXEdgeGroup interface pointer |
Comments:
The method can return NULL if the model data container does not currently contain an EdgeGroup interface. The edge group is not relevant if the model data container is associated with a particle group.
This method assigns an IFXEdgeGroup interface to the model data container. This is the interface to the edge group currently assigned to the model data container. EdgeGroups are used by modifiers that generate or access edgelists for the geometry in the model data. A model data container is not required to have an edge group interface, and thus this method can legitimately accept a NULL argument.
Parameters:
|
pInEdgeGroup |
A pointer to an IFXEdgeGroup interface |
Comments:
It is acceptable for pInEdgeGroup to be NULL. This causes the model data container to disassociate from any EdgeGroup currently assigned to it. The edge group is not relevant if the model data container is associated with a particle group.
This method retrieves the shader state of a model.
Parameters:
|
ppOutShaderState |
Pointer to SIFXModelShaderState |
This method retrieves the model's NeighborMesh. It allows a NeighborMesh to be created if no update records exist.
Parameters:
|
ppOutNeighborMesh |
Pointer to IFXNeighborMesh |
This method sets the model's modifier generator.
Parameters:
|
pGenerator |
Pointer to IFXModifier |
This method retrieves the model's modifier generator.
Parameters:
|
ppOutGenerator |
Handle to IFXModifier |
This method retrieves a pointer to an IFXStyle. This is the interface to the style that is currently assigned to the specified mesh in the model data's mesh group. See IFXStyle for further information on styles.
Parameters:
|
uInStyle |
The index of the desired style in the model data's StylePalette. This corresponds to the index into the mesh group of the mesh to which the style is assigned. |
|
ppOutStyle |
The address of an IFXStyle interface pointer |
X - This method will relay the return values of any internal function calls which failed.
Comments:
The style is not relevant if the model data container is associated with a particle group.
This method retrieves a pointer to an IFXPalette. This is the interface to the StylePalette that is currently assigned to the model data's mesh group. The StylePalette must have an entry for every mesh in the mesh group. See IFXStyle for further information on styles.
Parameters:
|
ppOutStylePalette |
The address of an IFXPalette interface pointer |
X - This method will relay the return values of any internal function calls which failed.
Comments:
You must call Release() on *ppOutStylePalette after you are finished using the palette.
The style is not relevant if the model data container is associated with a particle group.
This method assigns an IFXPalette interface to the model data container. This is the interface to the StylePalette that is currently assigned to the model data's mesh group. The StylePalette must have an entry for every mesh in the mesh group. See IFXStyle for further information on styles.
Parameters:
|
pInStylePalette |
A pointer to an IFXPalette interface |
Comments:
It is not necessary to call AddRef() on pInStylePalette prior to calling SetStylePalette.
This method calculates the bounding sphere of the entire meshgroup of the model data container.
Parameters:
None
This method retrieves an IFXSGVector which represents the bounding sphere of the mesh group assigned to the model data container. The (x,y,z) values of the retrieved vector are the coordinates of the center of the bounding sphere, the (h) component of the vector is the radius of the sphere. All values are in model space.
Parameters:
|
pOutBoundingSphere |
A pointer to an IFXSGVector interface |
This method assigns a bounding sphere (in the form of a 4 component vector) for the meshgroup of the model data container. This method should be used when bounding information already exists, in order to avoid the expensive RebuildBound() method.
Parameters:
|
IFXSGVectorBoundingSphere |
Vector representing the bounding sphere of a meshgroup |
Return Values:
None
This method indicates whether the bound volume updates have been enabled.
Parameters:
|
bEnabled |
Enabled status |
Return Values:
None
This method computes the volume of each of the meshes in the MeshGroup and fills in each volume in the volume array of the model data container.
Parameters:
None
X - This method will relay the return values of any internal function calls which failed.
This method retrieves the volume array of the MeshGroup currently associated with the model data container. The volume array is just an array of floats (F32), with one entry for each mesh in the mesh group.
Parameters:
|
ppfVolumeArray |
Pointer to the volume array |
This method retrieves the coefficient of angular drag, which applies to the MeshGroup as a whole.
Parameters:
|
pfOutAngularDragCoefficient |
A pointer to the floating point value representing the angular drag coefficient |
This method assigns the coefficient of angular drag, which applies to the MeshGroup as a whole.
Parameters:
|
fInAngularDragCoefficient |
A floating point value representing the angular drag coefficient |
This method retrieves the coefficient of linear drag, which applies to the MeshGroup as a whole.
Parameters:
|
pfOutLinearDragCoefficient |
A pointer to the floating point value representing the linear drag coefficient |
This method assigns the coefficient of linear drag, which applies to the MeshGroup as a whole.
Parameters:
|
fInLinearDrawCoefficient |
A floating point value representing the linear drag coefficient |
This method retrieves a CIFXBoundHierarchy object, which is the bounding hierarchy for the model data container's current MeshGroup.
Parameters:
|
ppOutBoundHierarchy |
The address of a pointer to a CIFXBoundHierarchy object |
This method assigns a CIFXBoundHierarchy object to the model data container. This will be used as the bounding hierarchy for the model data container's current MeshGroup.
Parameters:
|
pInBoundHierarchy |
A pointer to a CIFXBoundHierarchy object |
This method gets the modified status.
Parameters:
None
Return Values:
U32
This method sets the modified status.
Parameters:
|
uInModifiedStatusBitField |
Bit field number |
Return Values:
None
This method gets reallocated status.
Parameters:
None
Return Values:
U32
This method sets reallocated status.
Parameters:
|
uInReallocatedStatusBitField |
Bit field number |
Return Values:
None
This method retrieves the interface to the particle group currently associated with the model data container, if in fact there is a particle group.
Parameters:
|
ppOutParticleGroup |
The address of an IFXParticleGroup interface pointer |
This method assigns an IFXParticleGroup interface to the model data container.
Parameters:
|
pInParticleGroup |
A pointer to an IFXParticleGroup interface |
This method indicates whether the flag has been set.
Parameters:
|
bBoundHierarchyDirtyFlag |
Indicator of whether the flag has been set |
Return Values:
None
This method sets the modified status channel number.
Parameters:
|
uInModifiedStatusChannels |
Channel number |
Return Values:
None
§See asterisked (*) statement at Legal Information © 2001 Intel Corporation.