Method GetUntypedBufferAccessorReinterpret
GetUntypedBufferAccessorReinterpret<T>(ref DynamicComponentTypeHandle, int)
Construct a typed BufferAccessor view of a chunk's buffer component data from an untyped component handle.
Declaration
public readonly BufferAccessor<T> GetUntypedBufferAccessorReinterpret<T>(ref DynamicComponentTypeHandle typeHandle, int expectedElementTypeSize) where T : unmanaged, IBufferElementData
Parameters
| Type | Name | Description |
|---|---|---|
| DynamicComponentTypeHandle | typeHandle | Buffer type handle for the target component type |
| int | expectedElementTypeSize | The expected size (in bytes) of the target buffer component type. It is an error to pass a size that does not match the target type's actual size. |
Returns
| Type | Description |
|---|---|
| BufferAccessor<T> | A BufferAccessor<T> which aliases the chunk's component value array for type |
Type Parameters
| Name | Description |
|---|---|
| T | The target buffer component type |
Exceptions
| Type | Condition |
|---|---|
| ArgumentException | Thrown if |
| InvalidOperationException | Thrown if |