Struttura Vector3Fixed
Aggiornamento: novembre 2007
Rappresenta un vettore nello spazio tridimensionale (3D).
Spazio dei nomi: Microsoft.WindowsMobile.DirectX.Direct3D
Assembly: Microsoft.WindowsMobile.DirectX (in Microsoft.WindowsMobile.DirectX.dll)
Sintassi
'Dichiarazione
Public Structure Vector3Fixed
'Utilizzo
Dim instance As Vector3Fixed
public struct Vector3Fixed
public value class Vector3Fixed
JScript supporta l'utilizzo di strutture ma non la dichiarazione di nuove.
Note
Questa classe viene fornita per operazioni matematiche a virgola fissa.
Esempi
Nell'esempio di codice riportato di seguito viene illustrato come utilizzare una struttura Vector3Fixed.
' This example is taken from the
' Direct3D Mobile Fixed Point Lighting Sample
' of the .NET Compact Framework Samples in the SDK.
Select Case device.LightsFixed(2).Type
Case LightType.Point
device.LightsFixed(2).Position = New Vector3Fixed(4.5F * x, 4.5F * y, 4.5F * z)
device.LightsFixed(2).Attenuation1 = 0.4F
Case LightType.Directional
device.LightsFixed(2).Direction = New Vector3Fixed(x, y, z)
End Select
device.LightsFixed(2).Update()
End Sub
// This example is taken from the
// Direct3D Mobile Fixed Point Lighting Sample
// of the .NET Compact Framework Samples in the SDK.
switch(device.LightsFixed[2].Type)
{
case LightType.Point:
device.LightsFixed[2].Position =
new Vector3Fixed(4.5f * x, 4.5f * y, 4.5f * z);
device.LightsFixed[2].Attenuation1 = 0.4f;
break;
case LightType.Directional:
device.LightsFixed[2].Direction =
new Vector3Fixed(x, y, z);
break;
}
device.LightsFixed[2].Update();
Codice thread safe
Qualsiasi membro static (Shared in Visual Basic) pubblico di questo tipo è thread-safe. I membri di istanza non sono garantiti come thread-safe.
Piattaforme
Windows CE, Windows Mobile per Smartphone, Windows Mobile per Pocket PC
.NET Framework e .NET Compact Framework non supportano tutte le versioni di ciascuna piattaforma. Per un elenco delle versioni supportate, vedere Requisiti di sistema di .NET Framework.
Informazioni sulla versione
.NET Compact Framework
Supportato in: 3.5, 2.0
Vedere anche
Riferimenti
Spazio dei nomi Microsoft.WindowsMobile.DirectX.Direct3D
Altre risorse
Programmazione per Mobile Direct3D in .NET Compact Framework