Hinweis
Für den Zugriff auf diese Seite ist eine Autorisierung erforderlich. Sie können versuchen, sich anzumelden oder das Verzeichnis zu wechseln.
Für den Zugriff auf diese Seite ist eine Autorisierung erforderlich. Sie können versuchen, das Verzeichnis zu wechseln.
Beschreibt einen 2D-Vektor, der aus 16-Bit-Komponenten mit Vorzeichen und normalisierten ganzzahligen Komponenten besteht.
Eine Liste mit zusätzlichen Funktionen wie Konstruktoren und Operatoren, die bei XMSHORT2
der Programmierung in C++ verfügbar sind, finden Sie unter XMSHORT2-Erweiterungen.
Syntax
struct XMSHORT2 {
union {
struct {
int16_t x;
int16_t y;
};
uint32_t v;
};
void XMSHORT2();
void XMSHORT2(
const XMSHORT2 & unnamedParam1
);
XMSHORT2 & operator=(
const XMSHORT2 & unnamedParam1
);
void XMSHORT2(
XMSHORT2 && unnamedParam1
);
XMSHORT2 & operator=(
XMSHORT2 && unnamedParam1
);
void XMSHORT2(
uint32_t Packed
) noexcept;
void XMSHORT2(
int16_t _x,
int16_t _y
) noexcept;
void XMSHORT2(
const int16_t *pArray
) noexcept;
void XMSHORT2(
float _x,
float _y
) noexcept;
void XMSHORT2(
const float *pArray
) noexcept;
XMSHORT2 & operator=(
uint32_t Packed
) noexcept;
};
Member
x
Ganze Zahl mit Vorzeichen im Bereich [-32767, 32767], die die x-Koordinate des Vektors beschreibt.
y
Ganze Zahl mit Vorzeichen im Bereich [-32767, 32767], die die y-Koordinate des Vektors beschreibt.
v
Standardkonstruktor für XMSHORT2
.
Standardkonstruktor für XMSHORT2.
void XMSHORT2( const XMSHORT2 & unnamedParam1)
Ein Konstruktor für XMSHORT2
.
Ein Konstruktor für XMSHORT2.
XMSHORT2 & operator=( const XMSHORT2 & unnamedParam1)
Weist die Daten der Vektorkomponente aus einer instance von XMSHORT2
der aktuellen instance von zuXMSHORT2
.
Dieser Operator weist die Daten der Vektorkomponente aus einem instance von XMSHORT2 der aktuellen instance von XMSHORT2
zu.
void XMSHORT2( XMSHORT2 && unnamedParam1)
Ein Konstruktor für XMSHORT2
.
Ein Konstruktor für XMSHORT2.
XMSHORT2 & operator=( XMSHORT2 && unnamedParam1)
void XMSHORT2( uint32_t Packed) noexcept
Ein Konstruktor für XMSHORT2
.
Ein Konstruktor für XMSHORT2.
void XMSHORT2( int16_t _x, int16_t _y) noexcept
Initialisiert eine neue instance von XMSHORT2
aus zwei int16_t
Argumenten.
Dieser Konstruktor initialisiert eine neue instance von XMSHORT2 aus zwei int16_t
Argumenten.
void XMSHORT2( const int16_t *pArray) noexcept
Initialisiert eine neue instance von XMSHORT2 aus einem Argument mit zwei Elementarraysint16_t
.
Dieser Konstruktor initialisiert eine neue instance von XMSHORT2 aus einem Argument mit zwei Elementarraysint16_t
.
void XMSHORT2( float _x, float _y) noexcept
Initialisiert eine neue instance von XMSHORT2
aus zwei float
Argumenten.
Dieser Konstruktor initialisiert eine neue instance von XMSHORT2 aus zwei float
Argumenten.
void XMSHORT2( const float *pArray) noexcept
Initialisiert eine neue instance von XMSHORT2 aus einem Argument mit zwei Elementarraysfloat
.
Dieser Konstruktor initialisiert eine neue instance von XMSHORT2 aus einem Argument mit zwei Elementarraysfloat
.
XMSHORT2 & operator=( uint32_t Packed) noexcept
Hinweise
Die Komponenten werden normalisiert, wenn diese Struktur mithilfe von XMLoadShort2 in ein XMVECTOR geladen wird. Jede Komponente wird durch 32767.0f geteilt.
Namespace: Verwenden von DirectX::P ackedVector
Plattformanforderungen
Microsoft Visual Studio 2010 oder Microsoft Visual Studio 2012 mit dem Windows SDK für Windows 8. Unterstützt für Win32-Desktop-Apps, Windows Store-Apps und Windows Phone 8-Apps.Anforderungen
Anforderung | Wert |
---|---|
Header | directxpackedvector.h |