![]() |
UDocumentation UE5.7 10.02.2026 (Source)
API documentation for Unreal Engine 5.7
|
#include <FloatArrayMath.h>
FContiguousSparse2DKernelTransform
FContiguousSparse2DKernelTransform applies a matrix transformation to an input array. [OutArray] = [[Kernal]][InView]
It provides some optimization by exploit the contiguous and sparse qualities of the kernel rows, which allows it to skip multiplications with the number zero.
It works with non-sparse and non-contiguous kernels as well, but will be more computationally expensive than a naive implementation. Also, only takes advantage of sparse contiguous rows, not columns.
|
delete |
|
delete |
| Audio::FContiguousSparse2DKernelTransform::FContiguousSparse2DKernelTransform | ( | const int32 | NumInElements, |
| const int32 | NumOutElements | ||
| ) |
NumInElements sets the expected number of input array elements as well as the number of elements in a row. NumOutElements sets the number of output array elements as well as the number or rows.
|
virtual |
| int32 Audio::FContiguousSparse2DKernelTransform::GetNumInElements | ( | ) | const |
Returns the required size of the input array
| int32 Audio::FContiguousSparse2DKernelTransform::GetNumOutElements | ( | ) | const |
Returns the size of the output array
|
delete |
| void Audio::FContiguousSparse2DKernelTransform::SetRow | ( | const int32 | RowIndex, |
| const int32 | StartIndex, | ||
| TArrayView< const float > | OffsetValues | ||
| ) |
Set the kernel values for an individual row.
RowIndex determines which row is being set. StartIndex denotes the offset into the row where the OffsetValues will be inserted. OffsetValues contains the contiguous chunk of values which represent all the nonzero elements in the row.
| void Audio::FContiguousSparse2DKernelTransform::TransformArray | ( | const float * | InArray, |
| float * | OutArray | ||
| ) | const |
Transforms the input array given the kernel.
InArray is the array to be transformed. It must have NumInElements number of elements. OutArray is the transformed array. It must be allocated to hold at least NumOutElements.
| void Audio::FContiguousSparse2DKernelTransform::TransformArray | ( | TArrayView< const float > | InView, |
| FAlignedFloatBuffer & | OutArray | ||
| ) | const |
Transforms the input array given the kernel.
InView is the array to be transformed. It must have NumInElements number of elements. OutArray is the transformed array. It will have NumOutElements number of elements.
| void Audio::FContiguousSparse2DKernelTransform::TransformArray | ( | TArrayView< const float > | InView, |
| TArray< float > & | OutArray | ||
| ) | const |
Transforms the input array given the kernel.
InView is the array to be transformed. It must have NumInElements number of elements. OutArray is the transformed array. It will have NumOutElements number of elements.