![]() |
Qt 6.x
The Qt SDK
|
#include <qrhivulkan_p.h>
Public Member Functions | |
QVkComputePipeline (QRhiImplementation *rhi) | |
~QVkComputePipeline () | |
void | destroy () override |
Releases (or requests deferred releasing of) the underlying native graphics resources. | |
bool | create () override |
![]() | |
QRhiResource::Type | resourceType () const override |
virtual bool | create ()=0 |
Flags | flags () const |
void | setFlags (Flags f) |
Sets the flags f. | |
QRhiShaderStage | shaderStage () const |
void | setShaderStage (const QRhiShaderStage &stage) |
Sets the shader to use. | |
QRhiShaderResourceBindings * | shaderResourceBindings () const |
void | setShaderResourceBindings (QRhiShaderResourceBindings *srb) |
Associates with srb describing the resource binding layout and the resources (QRhiBuffer, QRhiTexture) themselves. | |
![]() | |
virtual | ~QRhiResource () |
Destructor. | |
virtual Type | resourceType () const =0 |
virtual void | destroy ()=0 |
Releases (or requests deferred releasing of) the underlying native graphics resources. | |
void | deleteLater () |
When called without a frame being recorded, this function is equivalent to deleting the object. | |
QByteArray | name () const |
void | setName (const QByteArray &name) |
Sets a name for the object. | |
quint64 | globalResourceId () const |
QRhi * | rhi () const |
Public Attributes | |
VkPipelineLayout | layout = VK_NULL_HANDLE |
VkPipeline | pipeline = VK_NULL_HANDLE |
int | lastActiveFrameSlot = -1 |
uint | generation = 0 |
Friends | |
class | QRhiVulkan |
Additional Inherited Members | |
![]() | |
enum | Flag { CompileShadersWithDebugInfo = 1 << 0 } |
Flag values for describing pipeline options. More... | |
![]() | |
enum | Type { Buffer , Texture , Sampler , RenderBuffer , RenderPassDescriptor , SwapChainRenderTarget , TextureRenderTarget , ShaderResourceBindings , GraphicsPipeline , SwapChain , ComputePipeline , CommandBuffer } |
Specifies type of the resource. More... | |
![]() | |
QRhiComputePipeline (QRhiImplementation *rhi) | |
![]() | |
QRhiResource (QRhiImplementation *rhi) | |
![]() | |
Flags | m_flags |
QRhiShaderStage | m_shaderStage |
QRhiShaderResourceBindings * | m_shaderResourceBindings = nullptr |
![]() | |
QRhiImplementation * | m_rhi = nullptr |
quint64 | m_id |
QByteArray | m_objectName |
Definition at line 290 of file qrhivulkan_p.h.
QVkComputePipeline::QVkComputePipeline | ( | QRhiImplementation * | rhi | ) |
Definition at line 7316 of file qrhivulkan.cpp.
QVkComputePipeline::~QVkComputePipeline | ( | ) |
Definition at line 7321 of file qrhivulkan.cpp.
References destroy().
|
overridevirtual |
Implements QRhiComputePipeline.
Definition at line 7348 of file qrhivulkan.cpp.
References QRhiShaderStage::Compute, QShader::ComputeStage, QByteArray::constData(), destroy(), QShaderCode::entryPoint(), generation, QByteArray::isEmpty(), lastActiveFrameSlot, QVkShaderResourceBindings::layout, layout, QRhiComputePipeline::m_shaderResourceBindings, QRhiComputePipeline::m_shaderStage, pipeline, Q_ASSERT, QRHI_RES, QRHI_RES_RHI, qWarning, QRhiShaderStage::shader(), QShaderCode::shader(), QShader::shader(), QRhiShaderStage::shaderVariant(), QShader::SpirvShader, QShader::stage(), and QRhiShaderStage::type().
|
overridevirtual |
Releases (or requests deferred releasing of) the underlying native graphics resources.
Safe to call multiple times, subsequent invocations will be a no-op then.
Once destroy() is called, the QRhiResource instance can be reused, by calling create()
again. That will then result in creating new native graphics resources underneath.
The QRhiResource destructor also performs the same task, so calling this function is not necessary before deleting a QRhiResource.
Implements QRhiResource.
Definition at line 7326 of file qrhivulkan.cpp.
References e, lastActiveFrameSlot, layout, pipeline, QRhiVulkan::DeferredReleaseEntry::Pipeline, and QRHI_RES_RHI.
Referenced by ~QVkComputePipeline(), and create().
|
friend |
Definition at line 301 of file qrhivulkan_p.h.
uint QVkComputePipeline::generation = 0 |
Definition at line 300 of file qrhivulkan_p.h.
Referenced by create(), and QRhiVulkan::setComputePipeline().
int QVkComputePipeline::lastActiveFrameSlot = -1 |
Definition at line 299 of file qrhivulkan_p.h.
Referenced by create(), destroy(), and QRhiVulkan::setComputePipeline().
VkPipelineLayout QVkComputePipeline::layout = VK_NULL_HANDLE |
Definition at line 297 of file qrhivulkan_p.h.
Referenced by create(), destroy(), and QRhiVulkan::setShaderResources().
VkPipeline QVkComputePipeline::pipeline = VK_NULL_HANDLE |
Definition at line 298 of file qrhivulkan_p.h.
Referenced by create(), destroy(), and QRhiVulkan::setComputePipeline().