IResource
Description
- Derived from
- Extended by
-
IGeometryBuffer
IGpuBuffer
IPipelineObject
IRenderTarget
ITexture
ResourceBase abstract
Base interface for classes that wrap GPU resources.
The amount of memory reported by IMemoryConsumption.MemoryConsumption is interpreted as the estimated amount of GPU memory that is consumed by this resource. It may be used to make large-scale resource decisions but must not be used to decide upfront whether a resource creation attempt will succeed or fail.
Passing an invalid resource object (see LifecycleState) to the graphics API will result in an TinmanException to be thrown.
Disposing a resource object while Binding1 returns true
is invalid. An error log message will be generated in this case and the subsequent behaviour of the graphics API is implementation-specific and may even be undefined.
Disposing a resource object after all graphics API bindings have been nullified is valid, as the graphics API implementation is responsible for keeping native GPU resources alive until all pending GPU work has finished.