DirectXMath Library structures

Describes the DirectXMath Library types and structures.

The DirectXMath Library provides a number of structures and defined types to encapsulate data to support ease of use, optimization, and portability. The following list includes structures currently part of the DirectXMath Library. They are available through DirectXMath.h.

In this section

Topic Description
XMBYTE2 A 2D vector where each component is a signed integer, 8-bits (1 byte) in length.
XMBYTE4 A 4D vector where each component is a signed integer, 8-bits (1 byte) in length.
XMBYTEN2 A 2D vector for storing signed, normalized values as signed 8-bits (1 byte) integers.
XMBYTEN4 A 3D vector for storing signed, normalized values as signed 8-bits (1 byte) integers.
XMCOLOR A 32-bit Alpha Red Green Blue (ARGB) color vector, where each color channel is specified as an unsigned 8 bit integer.
XMDEC4 A 4D vector with x-,y-, and z- components represented as 10 bit signed integer values, and the w-component as a 2 bit signed integer value.
XMDECN4 A 4D vector for storing signed, normalized values as 10 bit signed x-,y-, and z- components and a 2 bit signed w-component.
XMFLOAT2 A 2D vector consisting of two single-precision floating-point values.
XMFLOAT2A Describes an XMFLOAT2 structure aligned on a 16-byte boundary.
XMFLOAT3 Describes a 3D vector consisting of three single-precision floating-point values.
XMFLOAT3A Describes an XMFLOAT3 structure aligned on a 16-byte boundary.
XMFLOAT3PK Describes a 3D vector with X and Y components stored as 11 bit floating point number, and Z component stored as a 10 bit floating-point value.
XMFLOAT3SE Describes a 3D vector of three floating-point components with 9 bit mantissas, each sharing the same 5-bit exponent.
XMFLOAT3X3 A 3x3 floating point matrix.
XMFLOAT3X4 A 3x4 column-major matrix containing 32-bit floating-point components.
XMFLOAT3X4A A 3x4 column-major matrix containing 32-bit floating-point components aligned on a 16-byte boundary.
XMFLOAT4 Describes a 4D vector consisting of four single-precision floating-point values.
XMFLOAT4A Describes an XMFLOAT4 structure aligned on a 16-byte boundary.
XMFLOAT4X3 A 4x3 floating point matrix.
XMFLOAT4X3A Describes an XMFLOAT4X3 structure aligned on a 16-byte boundary.
XMFLOAT4X4 A 4x4 floating point matrix.
XMFLOAT4X4A Describes an XMFLOAT4X4 structure aligned on a 16-byte boundary.
XMHALF2 A 2D vector consisting of two half-precision (16bit) floating-point values.
XMHALF4 Describes a 4D vector consisting of four half-precision (16-bit) floating-point values.
XMINT2 A 2D vector where each component is a signed integer.
XMINT3 A 3D vector where each component is a signed integer.
XMINT4 A 4D vector where each component is a signed integer.
XMMATRIX Describes a 4x4 matrix aligned on a 16-byte boundary that maps to four hardware vector registers.
XMSHORT2 Describes a 2D vector consisting of 16-bit signed and normalized integer components.
XMSHORT4 A 4D vector consisting of 16-bit signed integer components.
XMSHORTN2 A 2D vector for storing signed, normalized values as signed 16-bit integers (type int16_t).
XMSHORTN4 A 4D vector for storing signed, normalized values as signed 16-bit integers, (type int16_t).
XMU555 A 4D vector with x-,y-, and z- components represented as 5 bit unsigned integer values, and the w-component as a 1 bit integer value.
XMU565 A 3D vector with x- and z- components represented as 5-bit unsigned integer values, and the y- component as a 6-bit unsigned integer value.
XMUBYTE2 Describes a 2D vector where each component is a unsigned integer, 8-bits (1 byte) in length.
XMUBYTE4 Describes a 4D vector where each component is a unsigned integer, 8-bits (1 byte) in length.
XMUBYTEN2 A 2D vector for storing unsigned, normalized values as signed 8-bits (1 byte) integers.
XMUBYTEN4 A 3D vector for storing unsigned, normalized values as signed 8-bits (1 byte) integers.
XMUDEC4 A 4D vector with x-,y-, and z- components represented as 10 bit unsigned integer values, and the w-component as a 2 bit unsigned integer value.
XMUDECN4 A 4D vector for storing unsigned, normalized integer values as 10 bit unsigned x-, y-, and z-components and a 2-bit unsigned w-component.
XMUINT2 A 2D vector where each component is an unsigned integer.
XMUINT3 A 3D vector where each component is an unsigned integer.
XMUINT4 A 4D vector where each component is an unsigned integer.
XMUNIBBLE4 A 4D vector with four unsigned 4-bit integer components.
XMUSHORT2 Describes a 2D vector consisting of 16-bit unsigned integer components.
XMUSHORT4 A 4D vector consisting of 16-bit unsigned integer components.
XMUSHORTN2 A 2D vector for storing unsigned, normalized values as unsigned 16-bit integers, (type uint16_t).
XMUSHORTN4 A 4D vector for storing unsigned, normalized values as signed 16-bit integers (type uint16_t).
XMXDEC4 A 4D vector with x-,y-, and z- components represented as 10 bit signed integer values, and the w-component as a 2 bit unsigned integer value.
XMXDECN4 A 4D vector for storing signed, normalized values as 10 bit signed x-,y-, and z- components and an unsigned, normalized value as 2 bit unsigned w-component.

DirectXMath Programming Reference