UnsafeUtility.AlignOf

Declaration

public static int AlignOf();

Returns

int A memory pointer.

Description

Gets the minimum alignment of a struct.

Set the type parameter to the type of the struct:
int align = UnsafeUtility.AlignOf<MyStruct>();.


Did you find this page useful? Please give it a rating: