IBufferD3D12 struct
Exposes Direct3D12-specific functionality of a buffer object.
Contents
- Reference
Base classes
- struct IBuffer
- Buffer interface.
Public functions
- auto GetD3D12Buffer(Uint64& DataStartByteOffset, IDeviceContext* pContext) -> ID3D12Resource*METHOD() virtual
- Returns a pointer to the ID3D12Resource interface of the internal Direct3D12 object.
- auto SetD3D12ResourceState(D3D12_RESOURCE_STATES state) -> void METHOD() virtual
- Sets the buffer usage state.
- auto GetD3D12ResourceState() const -> D3D12_RESOURCE_STATES METHOD() virtual
- Returns current D3D12 buffer state. If the state is unknown to the engine (Diligent::
RESOURCE_STATE_UNKNOWN), returns D3D12_RESOURCE_STATE_COMMON (0).
Function documentation
ID3D12Resource*METHOD() Diligent:: IBufferD3D12:: GetD3D12Buffer(Uint64& DataStartByteOffset,
IDeviceContext* pContext) virtual
Returns a pointer to the ID3D12Resource interface of the internal Direct3D12 object.
| Parameters | |
|---|---|
| DataStartByteOffset in | - Offset from the beginning of the buffer to the start of the data. This parameter is required for dynamic buffers, which are suballocated in a dynamic upload heap |
| pContext in | - Device context within which address of the buffer is requested. |
The method does NOT call AddRef() on the returned interface, so Release() must not be called.
void METHOD() Diligent:: IBufferD3D12:: SetD3D12ResourceState(D3D12_RESOURCE_STATES state) virtual
Sets the buffer usage state.
| Parameters | |
|---|---|
| state in | - D3D12 resource state to be set for this buffer |