MeshComponent.SetMaterial(Int32, Material) Method
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Sets an override material for a given material slot.
public:
void SetMaterial(int idx, Microsoft::Azure::RemoteRendering::Material ^ material);
public void SetMaterial (int idx, Microsoft.Azure.RemoteRendering.Material material);
member this.SetMaterial : int * Microsoft.Azure.RemoteRendering.Material -> unit
Public Sub SetMaterial (idx As Integer, material As Material)
Parameters
- material
- Material
The material to set as the override. Passing null
clears any previous override, such that the mesh's default material is used again.
Remarks
A IndexOutOfRange error occurs if 'idx' is outside the valid range.