Share via


XMStoreDecN4 関数 (directxpackedvector.h)

XMVECTORXMDECN4 に格納します。

構文

void XM_DEPRECATED XM_CALLCONV XMStoreDecN4(
  [out] XMDECN4   *pDestination,
  [in]  FXMVECTOR V
) noexcept;

パラメーター

[out] pDestination

データを格納するアドレス。

[in] V

格納するデータを含むベクター。

戻り値

[なし] :

解説

次の擬似コードは、 関数の操作を示しています。

XMVECTOR N;	
static const XMVECTOR  Scale = {511.0f, 511.0f, 511.0f, 1.0f};

N = XMVectorClamp(V, g_XMNegativeOne, g_XMOne);
N = XMVectorMultiply(N, Scale);

pDestination->v = ((int32_t)N.v[3] << 30) |
                  (((int32_t)N.v[2] & 0x3FF) << 20) |
                  (((int32_t)N.v[1] & 0x3FF) << 10) |
                  (((int32_t)N.v[0] & 0x3FF));

プラットフォームの要件

Windows 8 用 Windows SDK を使用した Microsoft Visual Studio 2010 または Microsoft Visual Studio 2012。 Win32 デスクトップ アプリ、Windows ストア アプリ、Windows Phone 8 アプリでサポートされます。

要件

   
対象プラットフォーム Windows
ヘッダー directxpackedvector.h (DirectXPackedVector.h を含む)

関連項目

DirectXMath ライブラリ ベクター ストア関数