LiteFX::Rendering::GraphicsFactory::createBuffer¶
createBuffer overloads
Synopses¶
Declared in <litefx/rendering.hpp>
Creates a buffer of type type.
virtual SharedPtr<TBuffer> createBuffer(
BufferType type,
ResourceHeap heap,
size_t elementSize,
UInt32 elements = 1,
ResourceUsage usage = ResourceUsage::Default,
AllocationBehavior allocationBehavior = AllocationBehavior::Default) const = 0;
Creates a buffer that can be bound to a specific descriptor.
[[dllimport, dllexport]] SharedPtr<IBuffer> createBuffer(
IDescriptorSetLayout const& descriptorSet,
UInt32 binding,
ResourceHeap heap,
UInt32 elements = 1,
ResourceUsage usage = ResourceUsage::Default,
AllocationBehavior allocationBehavior = AllocationBehavior::Default) const;
Creates a buffer that can be bound to a specific descriptor.
[[dllimport, dllexport]] SharedPtr<IBuffer> createBuffer(
IDescriptorSetLayout const& descriptorSet,
UInt32 binding,
ResourceHeap heap,
UInt32 elementSize,
UInt32 elements,
ResourceUsage usage = ResourceUsage::Default,
AllocationBehavior allocationBehavior = AllocationBehavior::Default) const;
Creates a buffer that can be bound to a descriptor of a specific descriptor set.
[[dllimport, dllexport]] SharedPtr<IBuffer> createBuffer(
IPipeline const& pipeline,
UInt32 space,
UInt32 binding,
ResourceHeap heap,
UInt32 elements = 1,
ResourceUsage usage = ResourceUsage::Default,
AllocationBehavior allocationBehavior = AllocationBehavior::Default) const;
Creates a buffer of type type.
[[dllimport, dllexport]] SharedPtr<IBuffer> createBuffer(
String const& name,
BufferType type,
ResourceHeap heap,
size_t elementSize,
UInt32 elements,
ResourceUsage usage = ResourceUsage::Default,
AllocationBehavior allocationBehavior = AllocationBehavior::Default) const;
Creates a buffer of type type.
virtual SharedPtr<TBuffer> createBuffer(
String const& name,
BufferType type,
ResourceHeap heap,
size_t elementSize,
UInt32 elements = 1,
ResourceUsage usage = ResourceUsage::Default,
AllocationBehavior allocationBehavior = AllocationBehavior::Default) const = 0;
Creates a buffer that can be bound to a specific descriptor.
[[dllimport, dllexport]] SharedPtr<IBuffer> createBuffer(
String const& name,
IDescriptorSetLayout const& descriptorSet,
UInt32 binding,
ResourceHeap heap,
UInt32 elements = 1,
ResourceUsage usage = ResourceUsage::Default,
AllocationBehavior allocationBehavior = AllocationBehavior::Default) const;
Creates a buffer that can be bound to a descriptor of a specific descriptor set.
[[dllimport, dllexport]] SharedPtr<IBuffer> createBuffer(
IPipeline const& pipeline,
UInt32 space,
UInt32 binding,
ResourceHeap heap,
UInt32 elementSize,
UInt32 elements,
ResourceUsage usage = ResourceUsage::Default,
AllocationBehavior allocationBehavior = AllocationBehavior::Default) const;
Creates a buffer that can be bound to a specific descriptor.
[[dllimport, dllexport]] SharedPtr<IBuffer> createBuffer(
String const& name,
IDescriptorSetLayout const& descriptorSet,
UInt32 binding,
ResourceHeap heap,
size_t elementSize,
UInt32 elements,
ResourceUsage usage = ResourceUsage::Default,
AllocationBehavior allocationBehavior = AllocationBehavior::Default) const;
Creates a buffer that can be bound to a descriptor of a specific descriptor set.
[[dllimport, dllexport]] SharedPtr<IBuffer> createBuffer(
String const& name,
IPipeline const& pipeline,
UInt32 space,
UInt32 binding,
ResourceHeap heap,
UInt32 elements = 1,
ResourceUsage usage = ResourceUsage::Default,
AllocationBehavior allocationBehavior = AllocationBehavior::Default) const;
Creates a buffer that can be bound to a descriptor of a specific descriptor set.
[[dllimport, dllexport]] SharedPtr<IBuffer> createBuffer(
String const& name,
IPipeline const& pipeline,
UInt32 space,
UInt32 binding,
ResourceHeap heap,
size_t elementSize,
UInt32 elements = 1,
ResourceUsage usage = ResourceUsage::Default,
AllocationBehavior allocationBehavior = AllocationBehavior::Default) const;
Return Value¶
The instance of the buffer.
Parameters¶
| Name | Description |
|---|---|
| type | The type of the buffer. |
| heap | The heap to allocate the buffer on. |
| elementSize | The size of an element in the buffer (in bytes). |
| elements | The number of elements in the buffer (in case the buffer is an array). |
| usage | The intended usage for the buffer. |
| allocationBehavior | The behavior controlling what happens if currently there is not enough memory available for the resource. |
| descriptorSet | The layout of the descriptors parent descriptor set. |
| binding | The binding point of the descriptor within the parent descriptor set. |
| pipeline | The pipeline that provides the descriptor set. |
| space | The space, the descriptor set is bound to. |
| name | The name of the buffer. |