pack_matrix pragma Directive

Pragma directive that specifies packing alignment for matrices.

#pragma pack_matrix( alignment )

Parameters

Item Description
alignment
Alignment to set for matrices. This parameter can take one of the values listed in the following table.
Value Description
column_major Default. Sets the matrix packing alignment to column major.
row_major Sets the matrix packing alignment to row major.

Examples

The following example sets the matrix packing alignment to row major.

#pragma pack_matrix( row_major )

See also

Preprocessor Directives (DirectX HLSL)

#pragma Directive (DirectX HLSL)