An area of GPU memory to store shader constants (in other words, material parameters).
More...
An area of GPU memory to store shader constants (in other words, material parameters).
◆ ConstantBuffer()
Creates a new instance of the ConstantBuffer class.
- Parameters
-
| name | The name of the constant buffer. Should match what's in the shader code. |
| size | The size, in bytes, of the buffer. |
| usage | A BufferUsage value indicating how the graphics backend should treat this buffer. |
◆ Dispose()
| override void Dispose |
( |
bool | disposing | ) |
|
|
inlineprotectedvirtual |
Called when it's time to throw out the trash.
- Parameters
-
| disposing | If true, please throw away your trash. Skunks! |
Called when it's time to throw out the trash.
- Parameters
-
| disposing | If true, please throw away your trash. Skunks! |
Reimplemented from GraphicsObject.
◆ SetData()
| void SetData |
( |
in ReadOnlySpan< byte > | data | ) |
|
|
inline |
Upload new data to this constant buffer.
- Parameters
-
| data | A slice of memory to copy into the buffer. Must be the same size as the buffer itself. |
The documentation for this class was generated from the following file:
- /builds/universe/graphics/src/Inertia.Platform/ConstantBuffer.cs