Export (0) Print
Expand All

XMSHORT2 structure

Describes a 2D vector consisting of 16-bit signed and normalized integer components.

For a list of additional functionality such as constructors and operators that are available using XMSHORT2 when you are programming in C++, see XMSHORT2 Extensions.

Note   See DirectXMath Library Type Equivalences for information about equivalent D3DDECLTYPE, D3DFORMAT, and DXGI_FORMAT objects.

Syntax


struct XMSHORT2 {
  int16_t x;
  int16_t y;
};

Members

x

Signed integer in the range [-32767, 32767] describing the x-coordinate of the vector.

y

Signed integer in the range [-32767, 32767] describing the y-coordinate of the vector.

Remarks

The components are normalized when this structure is loaded into an XMVECTOR using XMLoadShort2. Each component will be divided by 32767.0f.

Namespace: Use DirectX::PackedVector

Platform Requirements

Microsoft Visual Studio 2010 or Microsoft Visual Studio 2012 with the Windows SDK for Windows 8. Supported for Win32 desktop apps, Windows Store apps, and Windows Phone 8 apps.

Requirements

Header

DirectXPackedVector.h

See also

XMSHORT2 Extensions

 

 

Community Additions

ADD
Show:
© 2015 Microsoft