class Buffer
The FidelityFX Cauldron Framework
api/platform-agnostic representation of a buffer gpu resource.
File location: framework/cauldron/framework/inc/render/buffer.h
Typedefs
Type |
Description |
---|---|
typedef void |
(*ResizeFunction )( BufferDesc &, uint32_t, uint32_t, uint32_t, uint32_t )
Function signature for buffer ResizeFunction (when needed).
|
Methods
Return type |
Description |
---|---|
const BufferDesc & |
GetDesc () const
Gets a constant view on the buffer’s “BufferDesc“ description.
|
const GPUResource * |
GetResource () const
Gets a constant pointer to the buffer’s underlaying “GPUResource“.
|
GetResource ()
Gets a modifiable pointer to the buffer’s underlaying “GPUResource“.
|
|
void |
CopyData (const void* pData, size_t size) = 0
Copy callback used when loading buffer data. Implemented internally per api/platform.
|
void |
CopyData ( const void* pData, size_t size, UploadContext * pUploadCtx, ResourceState postCopyState ) = 0
|
GetAddressInfo () const = 0
Gets the buffer’s “BufferAddressInfo“ for resource binding. Implemented internally per api/platform.
|
|
void |
OnRenderingResolutionResize ( uint32_t outputWidth, uint32_t outputHeight, uint32_t renderingWidth, uint32_t renderingHeight )
Callback function executed on a buffer with resizing support to handle resourc recreation when size changes are needed.
|
static Buffer* |
CreateBufferResource ( const BufferDesc * pDesc, ResourceState initialState, ResizeFunction fn = nullptr, void* customOwner = nullptr )
Buffer instance creation function. Implemented per api/platform to return the correct internal resource type.
|
Detailed description
The FidelityFX Cauldron Framework
api/platform-agnostic representation of a buffer gpu resource.
The FidelityFX Cauldron Framework
api/platform-agnostic representation of a dynamic buffer pool.
The dynamic resource pool is the allocation construct used to back all resource creation in FidelityFX Cauldron Framework
.
Typedefs
ResizeFunction
Function signature for buffer ResizeFunction (when needed).
Methods
GetDesc
const BufferDesc & GetDesc () const
Gets a constant view on the buffer’s BufferDesc
description.
GetResource
const GPUResource * GetResource () const
Gets a constant pointer to the buffer’s underlaying GPUResource
.
GetResource
GPUResource * GetResource ()
Gets a modifiable pointer to the buffer’s underlaying GPUResource
.
CopyData
Copy callback used when loading buffer data. Implemented internally per api/platform.
GetAddressInfo
virtual BufferAddressInfo GetAddressInfo () const = 0
Gets the buffer’s BufferAddressInfo
for resource binding. Implemented internally per api/platform.
OnRenderingResolutionResize
Callback function executed on a buffer with resizing support to handle resourc recreation when size changes are needed.
CreateBufferResource
static Buffer* CreateBufferResource (
const BufferDesc * pDesc,
ResourceState initialState,
ResizeFunction fn = nullptr,
void* customOwner = nullptr
)
Buffer instance creation function. Implemented per api/platform to return the correct internal resource type.