|
Foundation
|
#include <Resource.hpp>
Public Member Functions | |
| RHIBuffer (RHIDevice const &device, RHIBufferDesc const &desc) | |
| virtual void * | Map ()=0 |
| Maps the entire buffer to the host memory. Alignment is implementation-defined. Implementations MUST guarantee consecutive calls to Map() return the same pointer, therefore it's not possible to map the same resource multiple times. For caching behaviours, RHIBufferDesc. | |
| virtual void | Flush (size_t offset=0, size_t size=kFullSize)=0 |
| Flushes the mapped region to the device. Depending on the implementation, this may be a no-op. | |
| virtual void | Unmap ()=0 |
| Releases or unmaps a previously mapped resource. Implementations MUST guarantee that Unmap() is called at destruction time if the resource is still mapped. | |
| template<typename T > | |
| Span< T > | MapSpan (size_t count=kFullSize) |
| Creates a span that maps a contiguous region of the buffer to the host memory. Behaviour of the memory access is defined by the resource itself. e.g. RO/RW. It is undefined behaviour to access the memory without regard to the resource's host access type. For detailed mapping behaviour, Map | |
| virtual RHIBufferScopedHandle< RHIBuffer > | CreateAliasedBuffer (RHIBufferDesc const &desc, size_t offset=0)=0 |
| virtual RHIBuffer * | GetAliasedBuffer (Handle handle) const =0 |
| virtual void | DestroyAliasedBuffer (Handle handle)=0 |
| virtual void | DebugSetObjectName (const char *name)=0 |
Public Member Functions inherited from Foundation::RHI::RHIObject | |
| RHIObject ()=default | |
| RHIObject (RHIObject const &)=delete | |
| RHIObject & | operator= (const RHIObject &)=delete |
| RHIObject (RHIObject &&)=delete | |
| RHIObject & | operator= (RHIObject &&)=delete |
| virtual | ~RHIObject ()=default |
Public Attributes | |
| const RHIBufferDesc | mDesc |
Protected Attributes | |
| const RHIDevice & | mDevice |
|
inline |
|
pure virtual |
Implemented in Foundation::RHI::VulkanBuffer.
Implemented in Foundation::RHI::VulkanBuffer.
Implemented in Foundation::RHI::VulkanBuffer.
|
pure virtual |
Flushes the mapped region to the device. Depending on the implementation, this may be a no-op.
Implemented in Foundation::RHI::VulkanBuffer.
|
pure virtual |
Implemented in Foundation::RHI::VulkanBuffer.
Maps the entire buffer to the host memory. Alignment is implementation-defined. Implementations MUST guarantee consecutive calls to Map() return the same pointer, therefore it's not possible to map the same resource multiple times. For caching behaviours, RHIBufferDesc.
Implemented in Foundation::RHI::VulkanBuffer.
Creates a span that maps a contiguous region of the buffer to the host memory. Behaviour of the memory access is defined by the resource itself. e.g. RO/RW. It is undefined behaviour to access the memory without regard to the resource's host access type. For detailed mapping behaviour, Map
| count | count of elements |
Releases or unmaps a previously mapped resource. Implementations MUST guarantee that Unmap() is called at destruction time if the resource is still mapped.
Implemented in Foundation::RHI::VulkanBuffer.
| const RHIBufferDesc Foundation::RHI::RHIBuffer::mDesc |