| Package com.ms.com.directX |
Previous |
Microsoft Packages |
Index |
Next |
Applications use the methods of the d3dMaterial class to retrieve and set the properties of materials.
public class d3dMaterial implements Id3dMaterial
{
public void InternalSetObject(IUnknown lpdd);
public IUnknown InternalGetObject();
public void Initialize(d3d dev);
public void SetMaterial(d3dMaterialStruc mat);
public void GetMaterial(d3dMaterialStruc mat);
public int GetHandle(d3dDevice dev);
public void Reserve();
public void Unreserve();
}
The methods can be organized into the following groups:
| Color reservation | Reserve |
| Unreserve | |
| Materials | GetMaterial |
| SetMaterial | |
| Miscellaneous | GetHandle |
| Initialize |
public int GetHandle(d3dDevice dev);Retrieves the material handle for the d3dMaterial object. This handle is used in all Direct3D API calls where a material is to be referenced. A material can be used by only one device at a time.
If the device is destroyed, the material is disassociated from the device.
Return Value:
Returns the material handle corresponding to the d3dMaterial object.
Parameter Description dev d3dDevice object in which the material is being used.
public void GetMaterial(d3dMaterialStruc mat);Retrieves the material data for the d3dMaterial object.
Return Value:
No return value.
Parameter Description mat d3dMaterialStruc object that receives the current material properties. See Also: SetMaterial
public void Initialize(d3d dev);Initializes the d3dMaterial object.
Return Value:
No return value.
Parameter Description dev d3d object.
public void Reserve();Not currently implemented.
public void SetMaterial(d3dMaterialStruc mat);Sets the material data for the d3dMaterial object.
Return Value:
No return value.
Parameter Description mat d3dMaterialStruc object that contains the material properties to be set. See Also: GetMaterial
public void Unreserve();Not currently implemented.
| © 1997 Microsoft Corporation. All rights reserved. Terms of Use. |