XMStoreFloat4x3 함수(directxmath.h)

XMFLOAT4X3XMMATRIX를 저장합니다.

구문

void XM_CALLCONV XMStoreFloat4x3(
  [out] XMFLOAT4X3 *pDestination,
  [in]  FXMMATRIX  M
) noexcept;

매개 변수

[out] pDestination

데이터를 저장할 주소입니다.

[in] M

저장할 데이터를 포함하는 행렬입니다.

반환 값

없음

설명

XMFLOAT4X3 은 행 중심 행렬 형식입니다. 이 함수는 마지막 열이 0 0 0 1이라고 가정하므로 열 주 데이터를 작성하는 데 사용할 수 없습니다.

이 함수는 행렬을 사용하고 지정된 주소에서 12개의 단정밀도 부동 소수점 값에 구성 요소를 씁니다. 첫 번째 행 벡터의 가장 중요한 구성 요소는 주소의 처음 4바이트에 기록되고 첫 번째 행의 두 번째로 중요한 구성 요소와 첫 번째 행의 세 번째 가장 중요한 구성 요소에 기록됩니다. 그런 다음 두 번째 행의 가장 중요한 세 가지 구성 요소는 바이트 12에서 시작하여 세 번째 행부터 메모리까지의 세 번째 행이 바이트 24부터 시작하여 마지막으로 4번째 행에서 메모리까지 바이트 36부터 시작하는 메모리와 같은 방식으로 작성됩니다.

다음 의사 코드는 함수의 작업을 보여 줍니다.

pDestination->_11 = M[0].x; // 4 bytes to address (uint8_t*)pDestination
pDestination->_12 = M[0].y; // 4 bytes to address (uint8_t*)pDestination + 4
pDestination->_13 = M[0].z; // 4 bytes to address (uint8_t*)pDestination + 8

pDestination->_21 = M[1].x; // 4 bytes to address (uint8_t*)pDestination + 12
pDestination->_22 = M[1].y; // 4 bytes to address (uint8_t*)pDestination + 16
pDestination->_23 = M[1].z; // 4 bytes to address (uint8_t*)pDestination + 20

pDestination->_31 = M[2].x; // 4 bytes to address (uint8_t*)pDestination + 24
pDestination->_32 = M[2].y; // 4 bytes to address (uint8_t*)pDestination + 28
pDestination->_33 = M[2].z; // 4 bytes to address (uint8_t*)pDestination + 32

pDestination->_41 = M[3].x; // 4 bytes to address (uint8_t*)pDestination + 36
pDestination->_42 = M[3].y; // 4 bytes to address (uint8_t*)pDestination + 40
pDestination->_43 = M[3].z; // 4 bytes to address (uint8_t*)pDestination + 44

플랫폼 요구 사항

Windows 8용 Windows SDK를 사용하는 Microsoft Visual Studio 2010 또는 Microsoft Visual Studio 2012. Win32 데스크톱 앱, Windows 스토어 앱 및 Windows Phone 8개 앱에서 지원됩니다.

요구 사항

   
대상 플랫폼 Windows
헤더 directxmath.h

추가 정보

DirectXMath 라이브러리 벡터 저장소 함수