Share via


Device.MaterialFixed (Propiedad)

Actualización: noviembre 2007

Obtiene o establece las propiedades de material actuales para el dispositivo, utilizando operaciones matemáticas de punto fijo.

Espacio de nombres:  Microsoft.WindowsMobile.DirectX.Direct3D
Ensamblado:  Microsoft.WindowsMobile.DirectX (en Microsoft.WindowsMobile.DirectX.dll)

Sintaxis

'Declaración
Public Property MaterialFixed As MaterialFixed
'Uso
Dim instance As Device
Dim value As MaterialFixed

value = instance.MaterialFixed

instance.MaterialFixed = value
public MaterialFixed MaterialFixed { get; set; }
public:
property MaterialFixed MaterialFixed {
    MaterialFixed get ();
    void set (MaterialFixed value);
}
public function get MaterialFixed () : MaterialFixed
public function set MaterialFixed (value : MaterialFixed)

Valor de propiedad

Tipo: Microsoft.WindowsMobile.DirectX.Direct3D.MaterialFixed
Una estructura MaterialFixed que representa las propiedades de material actuales que se van a obtener o las propiedades de material que se van a establecer.

Excepciones

Excepción Condición
InvalidCallException

Las propiedades de una estructura MaterialFixed no son válidas.

Ejemplos

En el ejemplo de código siguiente se muestra cómo se utiliza una estructura MaterialFixed.

' The following code example is from the
' Direct3D Mobile Meshes Sample of the 
' .NET Compact Framework Samples in the SDK.

' In this example, meshes are divided into subsets, 
' one for each material.
' Render them in a loop.
Dim i As Integer
For i = 0 To meshMaterials.Length
    ' Set the material and texture for this subset
    device.MaterialFixed = meshMaterials(i)
    device.SetTexture(0, meshTextures(i))

    ' Draw the mesh subset
    mesh.DrawSubset(i)
Next i
// The following code example is from the
// Direct3D Mobile Meshes Sample of the
// .NET Compact Framework Samples in the SDK.

// Meshes are divided into subsets, one for each material. Render them in
// a loop
for( int i=0; i<meshMaterials.Length; i++ )
{
    // Set the material and texture for this subset
    device.MaterialFixed = meshMaterials[i];
    device.SetTexture(0, meshTextures[i]);

    // Draw the mesh subset
    mesh.DrawSubset(i);
}

Permisos

Plataformas

Windows CE, Windows Mobile para Smartphone, Windows Mobile para Pocket PC

.NET Framework y .NET Compact Framework no admiten todas las versiones de cada plataforma. Para obtener una lista de las versiones compatibles, vea Requisitos de sistema de .NET Framework.

Información de versión

.NET Compact Framework

Compatible con: 3.5, 2.0

Vea también

Referencia

Device (Clase)

Device (Miembros)

Microsoft.WindowsMobile.DirectX.Direct3D (Espacio de nombres)