Class DX12Helpers
A set of helper functions for DirectX 12.
Namespace: Evergine.DirectX12
Assembly: Evergine.DirectX12.dll
Syntax
public static class DX12Helpers
Methods
EnsureArraySize<T>(ref T[], int)
Ensures the array size.
Declaration
public static void EnsureArraySize<T>(ref T[] array, int size)
Parameters
| Type | Name | Description |
|---|---|---|
| T[] | array | The array object. |
| int | size | The array size to check. |
Type Parameters
| Name | Description |
|---|---|
| T | The array type. |
Log2Ceil(uint)
Calculates the smallest integer exponent 'n' such that 2^n >= value. This is the number of bits required to represent the value (or the next power of 2).
Declaration
public static uint Log2Ceil(uint value)
Parameters
| Type | Name | Description |
|---|---|---|
| uint | value | The non-negative integer input. |
Returns
| Type | Description |
|---|---|
| uint | The ceiling of Log base 2 of the value. |
ToMatrix3x4(Matrix4x4)
Converts from Matrix4x4 to Matrix3x4.
Declaration
public static Matrix3x4 ToMatrix3x4(this Matrix4x4 m)
Parameters
| Type | Name | Description |
|---|---|---|
| Matrix4x4 | m | Evergine Matrix4x4. |
Returns
| Type | Description |
|---|---|
| Matrix3x4 | DX12 Matrix3x4. |