Struct MappedResourceView<T>
- Namespace
- NeoVeldrid
- Assembly
- NeoVeldrid.dll
A typed view of a MappedResource. Provides by-reference structured access to individual elements in the mapped resource.
public struct MappedResourceView<T> where T : struct
Type Parameters
TThe blittable value type which mapped data is viewed as.
- Inherited Members
Constructors
MappedResourceView(MappedResource)
Constructs a new MappedResourceView which wraps the given MappedResource.
public MappedResourceView(MappedResource rawResource)
Parameters
rawResourceMappedResourceThe raw resource which has been mapped.
Fields
Count
The total number of structures that is contained in the resource. This is effectively the total number of bytes divided by the size of the structure type.
public readonly int Count
Field Value
MappedResource
The MappedResource that this instance views.
public readonly MappedResource MappedResource
Field Value
SizeInBytes
The total size in bytes of the mapped resource.
public readonly uint SizeInBytes
Field Value
Properties
this[int]
Gets a reference to the structure value at the given index.
public ref T this[int index] { get; }
Parameters
indexintThe index of the value.
Property Value
- T
A reference to the value at the given index.
this[int, int]
Gets a reference to the structure at the given 2-dimensional texture coordinates.
public ref T this[int x, int y] { get; }
Parameters
Property Value
- T
A reference to the value at the given coordinates.
this[int, int, int]
Gets a reference to the structure at the given 3-dimensional texture coordinates.
public ref T this[int x, int y, int z] { get; }
Parameters
Property Value
- T
A reference to the value at the given coordinates.
this[uint]
Gets a reference to the structure value at the given index.
public ref T this[uint index] { get; }
Parameters
indexuintThe index of the value.
Property Value
- T
A reference to the value at the given index.
this[uint, uint]
Gets a reference to the structure at the given 2-dimensional texture coordinates.
public ref T this[uint x, uint y] { get; }
Parameters
Property Value
- T
A reference to the value at the given coordinates.
this[uint, uint, uint]
Gets a reference to the structure at the given 3-dimensional texture coordinates.
public ref T this[uint x, uint y, uint z] { get; }
Parameters
Property Value
- T
A reference to the value at the given coordinates.