Diligent Engine
 
Loading...
Searching...
No Matches
Diligent::InstanceMatrix Struct Reference

Row-major 4x3 matrix. More...

#include <DeviceContext.h>

Public Member Functions

constexpr InstanceMatrix () noexcept
 Construct identity matrix.
 
InstanceMatrixSetTranslation (float x, float y, float z) noexcept
 Sets the translation part.
 
InstanceMatrixSetRotation (const float *pMatrix, Uint32 RowSize=3) noexcept
 Sets the rotation part.
 

Public Attributes

float data [3][4]
 Matrix data.
 

Detailed Description

Row-major 4x3 matrix.

Member Data Documentation

◆ data

float Diligent::InstanceMatrix::data[3][4]

Matrix data.

The matrix is stored in row-major order:

       rotation        translation
([0,0]  [0,1]  [0,2])   ([0,3])
([1,0]  [1,1]  [1,2])   ([1,3])
([2,0]  [2,1]  [2,2])   ([2,3])