6#include <QLoggingCategory>
1228#ifndef QT_NO_DEBUG_STREAM
1232 dbg.nospace() <<
"QRhiDepthStencilClearValue(depth-clear=" <<
v.depthClearValue()
1233 <<
" stencil-clear=" <<
v.stencilClearValue()
1287 : m_rect { {
x,
y,
w,
h } },
1288 m_minDepth(minDepth),
1289 m_maxDepth(maxDepth)
1348#ifndef QT_NO_DEBUG_STREAM
1352 const std::array<float, 4>
r =
v.viewport();
1353 dbg.nospace() <<
"QRhiViewport(bottom-left-x=" <<
r[0]
1354 <<
" bottom-left-y=" <<
r[1]
1355 <<
" width=" <<
r[2]
1356 <<
" height=" <<
r[3]
1357 <<
" minDepth=" <<
v.minDepth()
1358 <<
" maxDepth=" <<
v.maxDepth()
1404 : m_rect { {
x,
y,
w,
h } }
1441#ifndef QT_NO_DEBUG_STREAM
1445 const std::array<int, 4>
r =
s.scissor();
1446 dbg.nospace() <<
"QRhiScissor(bottom-left-x=" <<
r[0]
1447 <<
" bottom-left-y=" <<
r[1]
1448 <<
" width=" <<
r[2]
1449 <<
" height=" <<
r[3]
1538 m_classification(cls),
1539 m_instanceStepRate(stepRate)
1593#ifndef QT_NO_DEBUG_STREAM
1597 dbg.nospace() <<
"QRhiVertexInputBinding(stride=" <<
b.stride()
1598 <<
" cls=" <<
b.classification()
1599 <<
" step-rate=" <<
b.instanceStepRate()
1742 : m_binding(binding),
1746 m_matrixSlice(matrixSlice)
1831#ifndef QT_NO_DEBUG_STREAM
1835 dbg.nospace() <<
"QRhiVertexInputAttribute(binding=" <<
a.binding()
1836 <<
" location=" <<
a.location()
1837 <<
" format=" <<
a.format()
1838 <<
" offset=" <<
a.offset()
1892 return 4 *
sizeof(float);
1894 return 4 *
sizeof(float);
1896 return 2 *
sizeof(float);
1898 return sizeof(float);
1901 return 4 *
sizeof(
quint8);
1903 return 2 *
sizeof(
quint8);
1917 return 4 *
sizeof(
qint32);
1919 return 4 *
sizeof(
qint32);
1921 return 2 *
sizeof(
qint32);
1944 return 4 *
sizeof(
qint16);
1946 return 4 *
sizeof(
qint16);
1948 return 2 *
sizeof(
qint16);
1953 Q_UNREACHABLE_RETURN(1);
2074#ifndef QT_NO_DEBUG_STREAM
2078 dbg.nospace() <<
"QRhiVertexInputLayout(bindings=" <<
v.m_bindings
2079 <<
" attributes=" <<
v.m_attributes
2219#ifndef QT_NO_DEBUG_STREAM
2223 dbg.nospace() <<
"QRhiShaderStage(type=" <<
s.type()
2224 <<
" shader=" <<
s.shader()
2225 <<
" variant=" <<
s.shaderVariant()
2294 : m_renderBuffer(renderBuffer)
2596 m_colorAttachments.
append(colorAttachment);
2606 : m_depthStencilBuffer(depthStencilBuffer)
2608 m_colorAttachments.
append(colorAttachment);
2621 : m_depthTexture(depthTexture)
2623 m_colorAttachments.
append(colorAttachment);
3831 m_type(type_), m_usage(usage_), m_size(size_)
4060 int sampleCount_,
Flags flags_,
4063 m_type(type_), m_pixelSize(pixelSize_), m_sampleCount(sampleCount_), m_flags(flags_),
4064 m_backingFormatHint(backingFormatHint_)
4424 int arraySize_,
int sampleCount_,
Flags flags_)
4426 m_format(format_), m_pixelSize(pixelSize_), m_depth(depth_),
4427 m_arraySize(arraySize_), m_sampleCount(sampleCount_), m_flags(flags_)
4756 m_magFilter(magFilter_), m_minFilter(minFilter_), m_mipmapMode(mipmapMode_),
4757 m_addressU(u_), m_addressV(v_), m_addressW(w_),
5038 m_swapchain(swapchain_)
5391 auto layoutDescAppender = std::back_inserter(srb->
m_layoutDesc);
5395 ^
uint(
d->arraySize());
5396 layoutDescAppender =
d->serialize(layoutDescAppender);
5536 b.d.u.ubuf.buf =
buf;
5537 b.d.u.ubuf.offset = 0;
5538 b.d.u.ubuf.maybeSize = 0;
5539 b.d.u.ubuf.hasDynamicOffset =
false;
5574 b.d.u.ubuf.buf =
buf;
5576 b.d.u.ubuf.maybeSize =
size;
5577 b.d.u.ubuf.hasDynamicOffset =
false;
5611 b.d.u.ubuf.buf =
buf;
5612 b.d.u.ubuf.offset = 0;
5613 b.d.u.ubuf.maybeSize =
size;
5614 b.d.u.ubuf.hasDynamicOffset =
true;
5650 b.d.u.stex.count = 1;
5651 b.d.u.stex.texSamplers[0] = { tex,
sampler };
5697 b.d.u.stex.count =
count;
5700 b.d.u.stex.texSamplers[
i] = texSamplers[
i];
5702 b.d.u.stex.texSamplers[
i] = {
nullptr,
nullptr };
5742 b.d.u.stex.count = 1;
5743 b.d.u.stex.texSamplers[0] = { tex,
nullptr };
5774 b.d.u.stex.count =
count;
5777 b.d.u.stex.texSamplers[
i] = { tex[
i],
nullptr };
5779 b.d.u.stex.texSamplers[
i] = {
nullptr,
nullptr };
5818 b.d.u.stex.count = 1;
5819 b.d.u.stex.texSamplers[0] = {
nullptr,
sampler };
5853 b.d.u.simage.tex = tex;
5854 b.d.u.simage.level =
level;
5888 b.d.u.simage.tex = tex;
5889 b.d.u.simage.level =
level;
5923 b.d.u.simage.tex = tex;
5924 b.d.u.simage.level =
level;
5956 b.d.u.sbuf.buf =
buf;
5957 b.d.u.sbuf.offset = 0;
5958 b.d.u.sbuf.maybeSize = 0;
5992 b.d.u.sbuf.buf =
buf;
5994 b.d.u.sbuf.maybeSize =
size;
6026 b.d.u.sbuf.buf =
buf;
6027 b.d.u.sbuf.offset = 0;
6028 b.d.u.sbuf.maybeSize = 0;
6062 b.d.u.sbuf.buf =
buf;
6064 b.d.u.sbuf.maybeSize =
size;
6096 b.d.u.sbuf.buf =
buf;
6097 b.d.u.sbuf.offset = 0;
6098 b.d.u.sbuf.maybeSize = 0;
6132 b.d.u.sbuf.buf =
buf;
6134 b.d.u.sbuf.maybeSize =
size;
6157 if (da->binding !=
db->binding
6158 || da->stage !=
db->stage
6159 || da->type !=
db->type)
6166 if (da->u.ubuf.buf !=
db->u.ubuf.buf
6167 || da->u.ubuf.offset !=
db->u.ubuf.offset
6168 || da->u.ubuf.maybeSize !=
db->u.ubuf.maybeSize)
6174 if (da->u.stex.count !=
db->u.stex.count)
6176 for (
int i = 0;
i < da->u.stex.count; ++
i) {
6177 if (da->u.stex.texSamplers[
i].tex !=
db->u.stex.texSamplers[
i].tex
6178 || da->u.stex.texSamplers[
i].sampler !=
db->u.stex.texSamplers[
i].sampler)
6185 if (da->u.stex.count !=
db->u.stex.count)
6187 for (
int i = 0;
i < da->u.stex.count; ++
i) {
6188 if (da->u.stex.texSamplers[
i].tex !=
db->u.stex.texSamplers[
i].tex)
6193 if (da->u.stex.texSamplers[0].sampler !=
db->u.stex.texSamplers[0].sampler)
6199 if (da->u.simage.tex !=
db->u.simage.tex
6200 || da->u.simage.level !=
db->u.simage.level)
6208 if (da->u.sbuf.buf !=
db->u.sbuf.buf
6209 || da->u.sbuf.offset !=
db->u.sbuf.offset
6210 || da->u.sbuf.maybeSize !=
db->u.sbuf.maybeSize)
6216 Q_UNREACHABLE_RETURN(
false);
6273#ifndef QT_NO_DEBUG_STREAM
6278 dbg.nospace() <<
"QRhiShaderResourceBinding("
6279 <<
"binding=" <<
d->binding
6280 <<
" stage=" <<
d->stage
6281 <<
" type=" <<
d->type;
6284 dbg.nospace() <<
" UniformBuffer("
6285 <<
"buffer=" <<
d->u.ubuf.buf
6286 <<
" offset=" <<
d->u.ubuf.offset
6287 <<
" maybeSize=" <<
d->u.ubuf.maybeSize
6291 dbg.nospace() <<
" SampledTextures("
6292 <<
"count=" <<
d->u.stex.count;
6293 for (
int i = 0;
i <
d->u.stex.count; ++
i) {
6294 dbg.nospace() <<
" texture=" <<
d->u.stex.texSamplers[
i].tex
6295 <<
" sampler=" <<
d->u.stex.texSamplers[
i].sampler;
6297 dbg.nospace() <<
')';
6300 dbg.nospace() <<
" Textures("
6301 <<
"count=" <<
d->u.stex.count;
6302 for (
int i = 0;
i <
d->u.stex.count; ++
i)
6303 dbg.nospace() <<
" texture=" <<
d->u.stex.texSamplers[
i].tex;
6304 dbg.nospace() <<
')';
6307 dbg.nospace() <<
" Sampler("
6308 <<
" sampler=" <<
d->u.stex.texSamplers[0].sampler
6312 dbg.nospace() <<
" ImageLoad("
6313 <<
"texture=" <<
d->u.simage.tex
6314 <<
" level=" <<
d->u.simage.level
6318 dbg.nospace() <<
" ImageStore("
6319 <<
"texture=" <<
d->u.simage.tex
6320 <<
" level=" <<
d->u.simage.level
6324 dbg.nospace() <<
" ImageLoadStore("
6325 <<
"texture=" <<
d->u.simage.tex
6326 <<
" level=" <<
d->u.simage.level
6330 dbg.nospace() <<
" BufferLoad("
6331 <<
"buffer=" <<
d->u.sbuf.buf
6332 <<
" offset=" <<
d->u.sbuf.offset
6333 <<
" maybeSize=" <<
d->u.sbuf.maybeSize
6337 dbg.nospace() <<
" BufferStore("
6338 <<
"buffer=" <<
d->u.sbuf.buf
6339 <<
" offset=" <<
d->u.sbuf.offset
6340 <<
" maybeSize=" <<
d->u.sbuf.maybeSize
6344 dbg.nospace() <<
" BufferLoadStore("
6345 <<
"buffer=" <<
d->u.sbuf.buf
6346 <<
" offset=" <<
d->u.sbuf.offset
6347 <<
" maybeSize=" <<
d->u.sbuf.maybeSize
6351 dbg.nospace() <<
" UNKNOWN()";
6354 dbg.nospace() <<
')';
6359#ifndef QT_NO_DEBUG_STREAM
6363 dbg.nospace() <<
"QRhiShaderResourceBindings("
7804 info.limits.luminanceInNits.minLuminance = 0.0f;
7805 info.limits.luminanceInNits.maxLuminance = 1000.0f;
7807 info.sdrWhiteLevel = 200.0f;
7811#ifndef QT_NO_DEBUG_STREAM
7815 dbg.nospace() <<
"QRhiSwapChainHdrInfo(";
7816 switch (
info.limitsType) {
7818 dbg.nospace() <<
" minLuminance=" <<
info.limits.luminanceInNits.minLuminance
7819 <<
" maxLuminance=" <<
info.limits.luminanceInNits.maxLuminance;
7822 dbg.nospace() <<
" maxColorComponentValue=" <<
info.limits.colorComponentValue.maxColorComponentValue;
7823 dbg.nospace() <<
" maxPotentialColorComponentValue=" <<
info.limits.colorComponentValue.maxPotentialColorComponentValue;
7826 switch (
info.luminanceBehavior) {
7828 dbg.nospace() <<
" scene-referred, SDR white level=" <<
info.sdrWhiteLevel;
7831 dbg.nospace() <<
" display-referred";
7834 dbg.nospace() <<
')';
7997 switch (
res->resourceType()) {
8005 return "RenderBuffer";
8007 return "RenderPassDescriptor";
8009 return "SwapChainRenderTarget";
8011 return "TextureRenderTarget";
8013 return "ShaderResourceBindings";
8015 return "GraphicsPipeline";
8019 return "ComputePipeline";
8021 return "CommandBuffer";
8024 Q_UNREACHABLE_RETURN(
"");
8036 static bool leakCheck =
true;
8043 qWarning(
"QRhi %p going down with %d unreleased resources that own native graphics objects. This is not nice.",
8044 q,
int(resources.
size()));
8048 const bool ownsNativeResources =
it.value();
8049 if (leakCheck && ownsNativeResources)
8056 res->m_rhi =
nullptr;
8070 QSize *blockDim)
const
8183 *byteSize = wblocks * hblocks *
blockSize;
8185 *blockDim =
QSize(xdim, ydim);
8260 *bytesPerPixel = bpc;
8278 qWarning(
"Cannot build a graphics pipeline without any stages");
8282 bool hasVertexStage =
false;
8284 if (!
it->shader().isValid()) {
8285 qWarning(
"Empty shader passed to graphics pipeline");
8289 hasVertexStage =
true;
8291 if (!hasVertexStage) {
8292 qWarning(
"Cannot build a graphics pipeline without a vertex stage");
8297 qWarning(
"Cannot build a graphics pipeline without a QRhiRenderPassDescriptor");
8302 qWarning(
"Cannot build a graphics pipeline without QRhiShaderResourceBindings");
8312 bool bindingsOk =
true;
8313 const int CHECKED_BINDINGS_COUNT = 64;
8314 bool bindingSeen[CHECKED_BINDINGS_COUNT] = {};
8317 if (binding >= CHECKED_BINDINGS_COUNT)
8320 qWarning(
"Invalid binding number %d", binding);
8326 if (!bindingSeen[binding]) {
8327 bindingSeen[binding] =
true;
8329 qWarning(
"Uniform buffer duplicates an existing binding number %d", binding);
8334 if (!bindingSeen[binding]) {
8335 bindingSeen[binding] =
true;
8337 qWarning(
"Combined image sampler duplicates an existing binding number %d", binding);
8342 if (!bindingSeen[binding]) {
8343 bindingSeen[binding] =
true;
8345 qWarning(
"Texture duplicates an existing binding number %d", binding);
8350 if (!bindingSeen[binding]) {
8351 bindingSeen[binding] =
true;
8353 qWarning(
"Sampler duplicates an existing binding number %d", binding);
8360 if (!bindingSeen[binding]) {
8361 bindingSeen[binding] =
true;
8363 qWarning(
"Image duplicates an existing binding number %d", binding);
8370 if (!bindingSeen[binding]) {
8371 bindingSeen[binding] =
true;
8373 qWarning(
"Buffer duplicates an existing binding number %d", binding);
8397 const int s =
qBound(1, sampleCount, 64);
8411 for (
int i = 0, ie = supported.count();
i != ie; ++
i) {
8413 if (supported[
i] >=
s) {
8420 if (
result == 1 && !supported.isEmpty())
8421 result = supported.last();
8422 qCDebug(QRHI_LOG_INFO,
"Attempted to set unsupported sample count %d, using %d instead",
8447 d->pendingDeleteResources.
clear();
8501 std::unique_ptr<QRhi>
r(
new QRhi);
8508#if QT_CONFIG(vulkan)
8514 qWarning(
"This build of Qt has no Vulkan support");
8523 qWarning(
"This build of Qt has no OpenGL support");
8532 qWarning(
"This platform has no Direct3D 11 support");
8541 qWarning(
"This platform has no Metal support");
8546#ifdef QRHI_D3D12_AVAILABLE
8547 r->d =
new QRhiD3D12(
static_cast<QRhiD3D12InitParams *
>(
params),
8548 static_cast<QRhiD3D12NativeHandles *
>(importDevice));
8551 qWarning(
"Qt was built without Direct3D 12 support. "
8552 "This is likely due to having ancient SDK headers (such as d3d12.h) in the Qt build environment. "
8553 "Rebuild Qt with an SDK supporting D3D12 features introduced in Windows 10 version 1703, "
8554 "or use an MSVC build as those typically are built with more up-to-date SDKs.");
8558 qWarning(
"This platform has no Direct3D 12 support");
8564 r->d->prepareForCreate(
r.get(), impl,
flags);
8594 if (impl ==
Metal) {
8600 ok = rhi !=
nullptr;
8685 Q_UNREACHABLE_RETURN(
"Unknown");
8756#ifndef QT_NO_DEBUG_STREAM
8763 return "Integrated";
8774 Q_UNREACHABLE_RETURN(
nullptr);
8779 dbg.nospace() <<
"QRhiDriverInfo(deviceName=" <<
info.deviceName
8781 <<
" vendorId=0x" <<
info.vendorId
8802 return d->implThread;
8862 d->cleanupCallbacks.
clear();
8864 for (
auto it = d->keyedCleanupCallbacks.
cbegin(),
end = d->keyedCleanupCallbacks.
cend();
it !=
end; ++
it)
8867 d->keyedCleanupCallbacks.
clear();
9003 const int opListSize = d->
bufferOps.size();
9004 if (idx < opListSize)
9023 if (idx < d->bufferOps.size())
9038 if (
buf->size() > 0) {
9040 if (idx < d->bufferOps.size())
9074 if (idx < d->bufferOps.size())
9089 if (desc.cbeginEntries() != desc.cendEntries()) {
9091 if (idx < d->textureOps.size())
9127 if (idx < d->textureOps.size())
9197 if (idx < d->textureOps.size())
9221 if (idx < d->textureOps.size())
9280 if (!(d->resUpdPoolMap &
mask)) {
9281 d->resUpdPoolMap |=
mask;
9284 if (!preferMemoryOverPerformance)
9285 d->lastResUpdIdx =
i;
9291 for (
int i = d->lastResUpdIdx + 1;
i <
poolSize; ++
i) {
9295 for (
int i = 0;
i <= d->lastResUpdIdx; ++
i) {
9304 const int oldSize = d->resUpdPool.
size();
9305 const int newSize = oldSize +
qMin(4,
qMax(0, 64 - oldSize));
9306 d->resUpdPool.
resize(newSize);
9307 for (
int i = oldSize;
i < newSize; ++
i)
9309 u = nextFreeBatch();
9311 qWarning(
"Resource update batch pool exhausted (max is 64)");
9314 if (preferMemoryOverPerformance && u)
9394 if (resourceUpdates)
9452 const QColor &colorClearValue,
9455 BeginPassFlags
flags)
9457 m_rhi->
beginPass(
this, rt, colorClearValue, depthStencilClearValue, resourceUpdates,
flags);
9547 int dynamicOffsetCount,
9612 m_rhi->
setVertexInput(
this, startBinding, bindingCount, bindings, indexBuf, indexOffset, indexFormat);
10010 return (
v + byteAlign - 1) & ~(byteAlign - 1);
10027 const int w =
qMax(1, baseLevelSize.width() >> mipLevel);
10028 const int h =
qMax(1, baseLevelSize.height() >> mipLevel);
10188 if (u->d->poolIndex < 0)
10189 u->d->trimOpLists();
10404#ifndef QT_NO_DEBUG_STREAM
10408 dbg.nospace() <<
"QRhiStats("
10409 <<
"totalPipelineCreationTime=" <<
info.totalPipelineCreationTime
10410 <<
" blockCount=" <<
info.blockCount
10411 <<
" allocCount=" <<
info.allocCount
10412 <<
" usedBytes=" <<
info.usedBytes
10413 <<
" unusedBytes=" <<
info.unusedBytes
10414 <<
" totalUsageBytes=" <<
info.totalUsageBytes
10517 QRhiBuffer::UsageFlags
usage,
10544 const QSize &pixelSize,
10546 QRhiRenderBuffer::Flags
flags,
10571 const QSize &pixelSize,
10573 QRhiTexture::Flags
flags)
10575 if (pixelSize.
height() == 0)
10606 QRhiTexture::Flags
flags)
10646 const QSize &pixelSize,
10648 QRhiTexture::Flags
flags)
10652 if (pixelSize.
height() == 0)
10680 return d->
createSampler(magFilter, minFilter, mipmapMode, addressU, addressV, addressW);
10691 QRhiTextureRenderTarget::Flags
flags)
10756 qWarning(
"Attempted to call beginFrame() within a still active frame; ignored");
10791 qWarning(
"Attempted to call endFrame() without an active frame; ignored");
10798 d->pendingDeleteResources.
clear();
10904 qWarning(
"Attempted to call beginOffscreenFrame() within a still active frame; ignored");
10923 qWarning(
"Attempted to call endOffscreenFrame() without an active frame; ignored");
10928 d->pendingDeleteResources.
clear();
10985 return counter.fetchAndAddRelaxed(1) + 1;
10990 return m_buffers.isEmpty() && m_textures.isEmpty();
10996 m_textures.clear();
11008 auto it = m_buffers.find(
buf);
11009 if (
it != m_buffers.end()) {
11012 qWarning(
"Buffer %p (%s) used with different accesses within the same pass, this is not allowed.",
11016 if (
it->stage != *stage) {
11018 *stage =
it->stage;
11027 b.stateAtPassBegin =
state;
11028 m_buffers.insert(
buf,
b);
11047 auto it = m_textures.find(tex);
11048 if (
it != m_textures.end()) {
11059 qWarning(
"Texture %p (%s) used with different accesses within the same pass, this is not allowed.",
11060 tex,
name.constData());
11063 if (
it->stage != *stage) {
11065 *stage =
it->stage;
11073 t.stateAtPassBegin =
state;
11074 m_textures.insert(tex,
t);
The QColor class provides colors based on RGB, HSV or CMYK values.
const_iterator cbegin() const noexcept
qsizetype size() const noexcept
Returns the number of items in the hash.
const_iterator cend() const noexcept
void clear() noexcept(std::is_nothrow_destructible< Node >::value)
Removes all items from the hash and frees up all memory used by it.
bool isEmpty() const noexcept
Returns true if the hash contains no items; otherwise returns false.
The QMatrix4x4 class represents a 4x4 transformation matrix in 3D space.
virtual char * beginFullDynamicBufferUpdateForCurrentFrame()
QRhiResource::Type resourceType() const override
Type
Specifies storage type of buffer resource.
QRhiBuffer(QRhiImplementation *rhi, Type type_, UsageFlags usage_, quint32 size_)
\variable QRhiBuffer::NativeBuffer::objects
virtual void endFullDynamicBufferUpdateForCurrentFrame()
To be called when the entire contents of the buffer data has been updated in the memory block returne...
virtual NativeBuffer nativeBuffer()
QRhiColorAttachment()=default
Constructs an empty color attachment description.
void endPass(QRhiResourceUpdateBatch *resourceUpdates=nullptr)
Records ending the current render pass.
void debugMarkMsg(const QByteArray &msg)
Inserts a debug message msg into the command stream.
void draw(quint32 vertexCount, quint32 instanceCount=1, quint32 firstVertex=0, quint32 firstInstance=0)
Records a non-indexed draw.
void setBlendConstants(const QColor &c)
Records setting the active blend constants to c.
void endExternal()
To be called once the externally added commands are recorded to the command buffer or context.
void setScissor(const QRhiScissor &scissor)
Records setting the active scissor rectangle specified in scissor.
void beginComputePass(QRhiResourceUpdateBatch *resourceUpdates=nullptr, BeginPassFlags flags={})
Records starting a new compute pass.
void drawIndexed(quint32 indexCount, quint32 instanceCount=1, quint32 firstIndex=0, qint32 vertexOffset=0, quint32 firstInstance=0)
Records an indexed draw.
void setStencilRef(quint32 refValue)
Records setting the active stencil reference value to refValue.
const QRhiNativeHandles * nativeHandles()
QRhiCommandBuffer(QRhiImplementation *rhi)
void resourceUpdate(QRhiResourceUpdateBatch *resourceUpdates)
Sometimes committing resource updates is necessary or just more convenient without starting a render ...
void dispatch(int x, int y, int z)
Records dispatching compute work items, with x, y, and z specifying the number of local workgroups in...
void beginPass(QRhiRenderTarget *rt, const QColor &colorClearValue, const QRhiDepthStencilClearValue &depthStencilClearValue, QRhiResourceUpdateBatch *resourceUpdates=nullptr, BeginPassFlags flags={})
Records starting a new render pass targeting the render target rt.
double lastCompletedGpuTime()
void setShaderResources(QRhiShaderResourceBindings *srb=nullptr, int dynamicOffsetCount=0, const DynamicOffset *dynamicOffsets=nullptr)
Records binding a set of shader resources, such as, uniform buffers or textures, that are made visibl...
QPair< int, quint32 > DynamicOffset
Synonym for QPair<int, quint32>.
void beginExternal()
To be called when the application before the application is about to enqueue commands to the current ...
void debugMarkBegin(const QByteArray &name)
Records a named debug group on the command buffer with the specified name.
void setViewport(const QRhiViewport &viewport)
Records setting the active viewport rectangle specified in viewport.
QRhiResource::Type resourceType() const override
void debugMarkEnd()
Records the end of a debug group.
QPair< QRhiBuffer *, quint32 > VertexInput
Synonym for QPair<QRhiBuffer *, quint32>.
void endComputePass(QRhiResourceUpdateBatch *resourceUpdates=nullptr)
Records ending the current compute pass.
IndexFormat
Specifies the index data type.
void setComputePipeline(QRhiComputePipeline *ps)
Records setting a new compute pipeline ps.
void setVertexInput(int startBinding, int bindingCount, const VertexInput *bindings, QRhiBuffer *indexBuf=nullptr, quint32 indexOffset=0, IndexFormat indexFormat=IndexUInt16)
Records vertex input bindings.
void setGraphicsPipeline(QRhiGraphicsPipeline *ps)
Records setting a new graphics pipeline ps.
QRhiResource::Type resourceType() const override
QRhiComputePipeline(QRhiImplementation *rhi)
\variable QRhiD3D11InitParams::enableDebugLayer
\variable QRhiGles2InitParams::format
const QRhiShaderStage * cendShaderStages() const
QRhiShaderResourceBindings * shaderResourceBindings() const
QRhiRenderPassDescriptor * renderPassDescriptor() const
QRhiGraphicsPipeline(QRhiImplementation *rhi)
\variable QRhiGraphicsPipeline::StencilOpState::failOp
QRhiResource::Type resourceType() const override
const QRhiShaderStage * cbeginShaderStages() const
virtual bool isClipDepthZeroToOne() const =0
bool isStencilSupportingFormat(QRhiTexture::Format format) const
virtual void endExternal(QRhiCommandBuffer *cb)=0
virtual QRhiTextureRenderTarget * createTextureRenderTarget(const QRhiTextureRenderTargetDescription &desc, QRhiTextureRenderTarget::Flags flags)=0
virtual QRhiComputePipeline * createComputePipeline()=0
virtual QRhiGraphicsPipeline * createGraphicsPipeline()=0
virtual void beginPass(QRhiCommandBuffer *cb, QRhiRenderTarget *rt, const QColor &colorClearValue, const QRhiDepthStencilClearValue &depthStencilClearValue, QRhiResourceUpdateBatch *resourceUpdates, QRhiCommandBuffer::BeginPassFlags flags)=0
virtual void setComputePipeline(QRhiCommandBuffer *cb, QRhiComputePipeline *ps)=0
void removeCleanupCallback(const void *key)
virtual void releaseCachedResources()=0
int effectiveSampleCount(int sampleCount) const
virtual ~QRhiImplementation()
virtual bool isTextureFormatSupported(QRhiTexture::Format format, QRhiTexture::Flags flags) const =0
virtual QRhiDriverInfo driverInfo() const =0
bool isCompressedFormat(QRhiTexture::Format format) const
static const QRhiShaderResourceBinding::Data * shaderResourceBindingData(const QRhiShaderResourceBinding &binding)
void updateLayoutDesc(QRhiShaderResourceBindings *srb)
virtual QRhiSampler * createSampler(QRhiSampler::Filter magFilter, QRhiSampler::Filter minFilter, QRhiSampler::Filter mipmapMode, QRhiSampler::AddressMode u, QRhiSampler::AddressMode v, QRhiSampler::AddressMode w)=0
virtual QRhiTexture * createTexture(QRhiTexture::Format format, const QSize &pixelSize, int depth, int arraySize, int sampleCount, QRhiTexture::Flags flags)=0
virtual bool isYUpInFramebuffer() const =0
virtual QList< int > supportedSampleCounts() const =0
virtual void endPass(QRhiCommandBuffer *cb, QRhiResourceUpdateBatch *resourceUpdates)=0
virtual void debugMarkEnd(QRhiCommandBuffer *cb)=0
virtual QRhi::FrameOpResult finish()=0
virtual QRhi::FrameOpResult endFrame(QRhiSwapChain *swapChain, QRhi::EndFrameFlags flags)=0
virtual void endComputePass(QRhiCommandBuffer *cb, QRhiResourceUpdateBatch *resourceUpdates)=0
virtual int ubufAlignment() const =0
void compressedFormatInfo(QRhiTexture::Format format, const QSize &size, quint32 *bpl, quint32 *byteSize, QSize *blockDim) const
virtual QRhi::FrameOpResult endOffscreenFrame(QRhi::EndFrameFlags flags)=0
virtual void resourceUpdate(QRhiCommandBuffer *cb, QRhiResourceUpdateBatch *resourceUpdates)=0
bool sanityCheckShaderResourceBindings(QRhiShaderResourceBindings *srb)
virtual void beginComputePass(QRhiCommandBuffer *cb, QRhiResourceUpdateBatch *resourceUpdates, QRhiCommandBuffer::BeginPassFlags flags)=0
virtual void setBlendConstants(QRhiCommandBuffer *cb, const QColor &c)=0
virtual void debugMarkBegin(QRhiCommandBuffer *cb, const QByteArray &name)=0
virtual int resourceLimit(QRhi::ResourceLimit limit) const =0
virtual void setShaderResources(QRhiCommandBuffer *cb, QRhiShaderResourceBindings *srb, int dynamicOffsetCount, const QRhiCommandBuffer::DynamicOffset *dynamicOffsets)=0
virtual void setPipelineCacheData(const QByteArray &data)=0
virtual QRhiBuffer * createBuffer(QRhiBuffer::Type type, QRhiBuffer::UsageFlags usage, quint32 size)=0
void prepareForCreate(QRhi *rhi, QRhi::Implementation impl, QRhi::Flags flags)
virtual bool isDeviceLost() const =0
virtual const QRhiNativeHandles * nativeHandles(QRhiCommandBuffer *cb)=0
virtual void setViewport(QRhiCommandBuffer *cb, const QRhiViewport &viewport)=0
virtual void beginExternal(QRhiCommandBuffer *cb)=0
virtual QMatrix4x4 clipSpaceCorrMatrix() const =0
quint32 byteSizePerVertexForVertexInputFormat(QRhiVertexInputAttribute::Format format) const
virtual void dispatch(QRhiCommandBuffer *cb, int x, int y, int z)=0
virtual bool makeThreadLocalNativeContextCurrent()=0
void addDeleteLater(QRhiResource *res)
virtual void setVertexInput(QRhiCommandBuffer *cb, int startBinding, int bindingCount, const QRhiCommandBuffer::VertexInput *bindings, QRhiBuffer *indexBuf, quint32 indexOffset, QRhiCommandBuffer::IndexFormat indexFormat)=0
virtual QRhi::FrameOpResult beginFrame(QRhiSwapChain *swapChain, QRhi::BeginFrameFlags flags)=0
virtual void setStencilRef(QRhiCommandBuffer *cb, quint32 refValue)=0
bool sanityCheckGraphicsPipeline(QRhiGraphicsPipeline *ps)
virtual void debugMarkMsg(QRhiCommandBuffer *cb, const QByteArray &msg)=0
QRhiVertexInputAttribute::Format shaderDescVariableFormatToVertexInputFormat(QShaderDescription::VariableType type) const
virtual double lastCompletedGpuTime(QRhiCommandBuffer *cb)=0
virtual QRhiRenderBuffer * createRenderBuffer(QRhiRenderBuffer::Type type, const QSize &pixelSize, int sampleCount, QRhiRenderBuffer::Flags flags, QRhiTexture::Format backingFormatHint)=0
void addCleanupCallback(const QRhi::CleanupCallback &callback)
virtual bool isYUpInNDC() const =0
virtual void drawIndexed(QRhiCommandBuffer *cb, quint32 indexCount, quint32 instanceCount, quint32 firstIndex, qint32 vertexOffset, quint32 firstInstance)=0
virtual QRhiShaderResourceBindings * createShaderResourceBindings()=0
virtual bool isFeatureSupported(QRhi::Feature feature) const =0
virtual void setGraphicsPipeline(QRhiCommandBuffer *cb, QRhiGraphicsPipeline *ps)=0
void textureFormatInfo(QRhiTexture::Format format, const QSize &size, quint32 *bpl, quint32 *byteSize, quint32 *bytesPerPixel) const
virtual void draw(QRhiCommandBuffer *cb, quint32 vertexCount, quint32 instanceCount, quint32 firstVertex, quint32 firstInstance)=0
virtual QByteArray pipelineCacheData()=0
virtual QRhi::FrameOpResult beginOffscreenFrame(QRhiCommandBuffer **cb, QRhi::BeginFrameFlags flags)=0
virtual QRhiStats statistics()=0
virtual void setScissor(QRhiCommandBuffer *cb, const QRhiScissor &scissor)=0
virtual QRhiSwapChain * createSwapChain()=0
static TextureStage toPassTrackerTextureStage(QRhiShaderResourceBinding::StageFlags stages)
static BufferStage toPassTrackerBufferStage(QRhiShaderResourceBinding::StageFlags stages)
void registerBuffer(QRhiBuffer *buf, int slot, BufferAccess *access, BufferStage *stage, const UsageState &state)
void registerTexture(QRhiTexture *tex, TextureAccess *access, TextureStage *stage, const UsageState &state)
QRhiReadbackDescription()=default
Constructs an empty texture readback description.
QRhiRenderBuffer(QRhiImplementation *rhi, Type type_, const QSize &pixelSize_, int sampleCount_, Flags flags_, QRhiTexture::Format backingFormatHint_)
QRhiResource::Type resourceType() const override
Type
Specifies the type of the renderbuffer.
virtual bool createFrom(NativeRenderBuffer src)
Similar to create() except that no new native renderbuffer objects are created.
QRhiResource::Type resourceType() const override
virtual const QRhiNativeHandles * nativeHandles()
QRhiRenderPassDescriptor(QRhiImplementation *rhi)
QRhiRenderTarget(QRhiImplementation *rhi)
QVarLengthArray< BufferOp, BUFFER_OPS_STATIC_ALLOC > bufferOps
bool hasOptimalCapacity() const
QVarLengthArray< TextureOp, TEXTURE_OPS_STATIC_ALLOC > textureOps
static const int BUFFER_OPS_STATIC_ALLOC
static QRhiResourceUpdateBatchPrivate * get(QRhiResourceUpdateBatch *b)
void merge(QRhiResourceUpdateBatchPrivate *other)
static const int TEXTURE_OPS_STATIC_ALLOC
~QRhiResourceUpdateBatch()
void merge(QRhiResourceUpdateBatch *other)
Copies all queued operations from the other batch into this one.
void generateMips(QRhiTexture *tex)
Enqueues a mipmap generation operation for the specified texture tex.
void updateDynamicBuffer(QRhiBuffer *buf, quint32 offset, quint32 size, const void *data)
Enqueues updating a region of a QRhiBuffer buf created with the type QRhiBuffer::Dynamic.
void uploadStaticBuffer(QRhiBuffer *buf, quint32 offset, quint32 size, const void *data)
Enqueues updating a region of a QRhiBuffer buf created with the type QRhiBuffer::Immutable or QRhiBuf...
void uploadTexture(QRhiTexture *tex, const QRhiTextureUploadDescription &desc)
Enqueues uploading the image data for one or more mip levels in one or more layers of the texture tex...
void readBackTexture(const QRhiReadbackDescription &rb, QRhiReadbackResult *result)
Enqueues a texture-to-host copy operation as described by rb.
void readBackBuffer(QRhiBuffer *buf, quint32 offset, quint32 size, QRhiReadbackResult *result)
Enqueues reading back a region of the QRhiBuffer buf.
void copyTexture(QRhiTexture *dst, QRhiTexture *src, const QRhiTextureCopyDescription &desc=QRhiTextureCopyDescription())
Enqueues a texture-to-texture copy operation from src into dst as described by desc.
bool hasOptimalCapacity() const
QRhiResource(QRhiImplementation *rhi)
Type
Specifies type of the resource.
virtual ~QRhiResource()
Destructor.
quint64 globalResourceId() const
void setName(const QByteArray &name)
Sets a name for the object.
QRhiImplementation * m_rhi
void deleteLater()
When called without a frame being recorded, this function is equivalent to deleting the object.
Filter
Specifies the minification, magnification, or mipmap filtering.
QRhiResource::Type resourceType() const override
AddressMode
Specifies the addressing mode.
QRhiSampler(QRhiImplementation *rhi, Filter magFilter_, Filter minFilter_, Filter mipmapMode_, AddressMode u_, AddressMode v_, AddressMode w_)
QRhiScissor()=default
Constructs an empty scissor.
static QRhiShaderResourceBinding bufferStore(int binding, StageFlags stage, QRhiBuffer *buf)
static QRhiShaderResourceBinding imageLoadStore(int binding, StageFlags stage, QRhiTexture *tex, int level)
bool operator!=(const QRhiShaderResourceBinding &a, const QRhiShaderResourceBinding &b) noexcept
size_t qHash(const QRhiShaderResourceBinding &b, size_t seed) noexcept
bool isLayoutCompatible(const QRhiShaderResourceBinding &other) const
static QRhiShaderResourceBinding bufferLoad(int binding, StageFlags stage, QRhiBuffer *buf)
static QRhiShaderResourceBinding sampledTexture(int binding, StageFlags stage, QRhiTexture *tex, QRhiSampler *sampler)
static QRhiShaderResourceBinding imageLoad(int binding, StageFlags stage, QRhiTexture *tex, int level)
static QRhiShaderResourceBinding sampler(int binding, StageFlags stage, QRhiSampler *sampler)
static QRhiShaderResourceBinding texture(int binding, StageFlags stage, QRhiTexture *tex)
bool operator==(const QRhiShaderResourceBinding &a, const QRhiShaderResourceBinding &b) noexcept
static QRhiShaderResourceBinding textures(int binding, StageFlags stage, int count, QRhiTexture **tex)
static QRhiShaderResourceBinding bufferLoadStore(int binding, StageFlags stage, QRhiBuffer *buf)
static QRhiShaderResourceBinding imageStore(int binding, StageFlags stage, QRhiTexture *tex, int level)
@ TessellationEvaluationStage
@ TessellationControlStage
static constexpr int LAYOUT_DESC_ENTRIES_PER_BINDING
static QRhiShaderResourceBinding sampledTextures(int binding, StageFlags stage, int count, const TextureAndSampler *texSamplers)
static QRhiShaderResourceBinding uniformBufferWithDynamicOffset(int binding, StageFlags stage, QRhiBuffer *buf, quint32 size)
static QRhiShaderResourceBinding uniformBuffer(int binding, StageFlags stage, QRhiBuffer *buf)
bool isLayoutCompatible(const QRhiShaderResourceBindings *other) const
QVarLengthArray< QRhiShaderResourceBinding, BINDING_PREALLOC > m_bindings
QRhiShaderResourceBindings(QRhiImplementation *rhi)
const QRhiShaderResourceBinding * cbeginBindings() const
static constexpr int BINDING_PREALLOC
QVector< quint32 > m_layoutDesc
const QRhiShaderResourceBinding * cendBindings() const
QRhiResource::Type resourceType() const override
QRhiShaderStage()=default
Constructs a shader stage description for the vertex stage with an empty QShader.
QRhiResource::Type resourceType() const override
QRhiSwapChainRenderTarget(QRhiImplementation *rhi, QRhiSwapChain *swapchain_)
QRhiResource::Type resourceType() const override
virtual QRhiRenderTarget * currentFrameRenderTarget()=0
QRhiSwapChain(QRhiImplementation *rhi)
StereoTargetBuffer
Selects the backbuffer to use with a stereoscopic swapchain.
virtual QRhiSwapChainHdrInfo hdrInfo()
\variable QRhiSwapChainHdrInfo::limitsType
QRhiTextureRenderTargetDescription()=default
Constructs an empty texture render target description.
QRhiResource::Type resourceType() const override
QRhiTextureRenderTarget(QRhiImplementation *rhi, const QRhiTextureRenderTargetDescription &desc_, Flags flags_)
QRhiTextureSubresourceUploadDescription()=default
Constructs an empty subresource description.
QRhiTextureUploadDescription()=default
Constructs an empty texture upload description.
QRhiTextureUploadEntry()=default
Constructs an empty QRhiTextureUploadEntry targeting layer 0 and level 0.
QRhiTexture(QRhiImplementation *rhi, Format format_, const QSize &pixelSize_, int depth_, int arraySize_, int sampleCount_, Flags flags_)
\variable QRhiTexture::NativeTexture::object
QRhiResource::Type resourceType() const override
Format
Specifies the texture format.
virtual void setNativeLayout(int layout)
With some graphics APIs, such as Vulkan, integrating custom rendering code that uses the graphics API...
virtual bool createFrom(NativeTexture src)
Similar to create(), except that no new native textures are created.
virtual NativeTexture nativeTexture()
QRhiViewport()=default
Constructs a viewport description with an empty rectangle and a depth range of 0.0f - 1....
\variable QRhiVulkanInitParams::inst
\inmodule QtGuiPrivate \inheaderfile rhi/qrhi.h
QRhiBuffer * newBuffer(QRhiBuffer::Type type, QRhiBuffer::UsageFlags usage, quint32 size)
bool isClipDepthZeroToOne() const
FrameOpResult endOffscreenFrame(EndFrameFlags flags={})
Ends, submits, and waits for the offscreen frame.
bool makeThreadLocalNativeContextCurrent()
With OpenGL this makes the OpenGL context current on the current thread.
bool isTextureFormatSupported(QRhiTexture::Format format, QRhiTexture::Flags flags={}) const
int ubufAligned(int v) const
QRhiStats statistics() const
Gathers and returns statistics about the timings and allocations of graphics resources.
int resourceLimit(ResourceLimit limit) const
QRhiTexture * newTextureArray(QRhiTexture::Format format, int arraySize, const QSize &pixelSize, int sampleCount=1, QRhiTexture::Flags flags={})
QMatrix4x4 clipSpaceCorrMatrix() const
bool isYUpInFramebuffer() const
static QRhiSwapChainProxyData updateSwapChainProxyData(Implementation impl, QWindow *window)
Generates and returns a QRhiSwapChainProxyData struct containing opaque data specific to the backend ...
bool isFeatureSupported(QRhi::Feature feature) const
void runCleanup()
Invokes all registered cleanup functions.
QRhiShaderResourceBindings * newShaderResourceBindings()
QList< int > supportedSampleCounts() const
QRhiRenderBuffer * newRenderBuffer(QRhiRenderBuffer::Type type, const QSize &pixelSize, int sampleCount=1, QRhiRenderBuffer::Flags flags={}, QRhiTexture::Format backingFormatHint=QRhiTexture::UnknownFormat)
Implementation backend() const
Implementation
Describes which graphics API-specific backend gets used by a QRhi instance.
static int mipLevelsForSize(const QSize &size)
int currentFrameSlot() const
FrameOpResult beginFrame(QRhiSwapChain *swapChain, BeginFrameFlags flags={})
Starts a new frame targeting the next available buffer of swapChain.
QRhi::FrameOpResult finish()
Waits for any work on the graphics queue (where applicable) to complete, then executes all deferred o...
QRhiComputePipeline * newComputePipeline()
QRhiSwapChain * newSwapChain()
FrameOpResult beginOffscreenFrame(QRhiCommandBuffer **cb, BeginFrameFlags flags={})
Starts a new offscreen frame.
QRhiSampler * newSampler(QRhiSampler::Filter magFilter, QRhiSampler::Filter minFilter, QRhiSampler::Filter mipmapMode, QRhiSampler::AddressMode addressU, QRhiSampler::AddressMode addressV, QRhiSampler::AddressMode addressW=QRhiSampler::Repeat)
QRhiTextureRenderTarget * newTextureRenderTarget(const QRhiTextureRenderTargetDescription &desc, QRhiTextureRenderTarget::Flags flags={})
bool isRecordingFrame() const
void removeCleanupCallback(const void *key)
Deregisters the callback with key.
const char * backendName() const
QRhiGraphicsPipeline * newGraphicsPipeline()
static bool probe(Implementation impl, QRhiInitParams *params)
void addCleanupCallback(const CleanupCallback &callback)
Registers a callback that is invoked either when the QRhi is destroyed, or when runCleanup() is calle...
static QRhi * create(Implementation impl, QRhiInitParams *params, Flags flags={}, QRhiNativeHandles *importDevice=nullptr)
QByteArray pipelineCacheData()
FrameOpResult endFrame(QRhiSwapChain *swapChain, EndFrameFlags flags={})
Ends, commits, and presents a frame that was started in the last beginFrame() on swapChain.
ResourceLimit
Describes the resource limit to query.
QRhiTexture * newTexture(QRhiTexture::Format format, const QSize &pixelSize, int sampleCount=1, QRhiTexture::Flags flags={})
void setPipelineCacheData(const QByteArray &data)
Loads data into the pipeline cache, when applicable.
QRhiDriverInfo driverInfo() const
Feature
Flag values to indicate what features are supported by the backend currently in use.
const QRhiNativeHandles * nativeHandles()
QRhiResourceUpdateBatch * nextResourceUpdateBatch()
static QSize sizeForMipLevel(int mipLevel, const QSize &baseLevelSize)
int ubufAlignment() const
FrameOpResult
Describes the result of operations that can have a soft failure.
bool isDeviceLost() const
void releaseCachedResources()
Attempts to release resources in the backend's caches.
std::function< void(QRhi *)> CleanupCallback
VariableType
Represents the type of a variable or block member.
Variant
Describes what kind of shader code an entry contains.
constexpr int height() const noexcept
Returns the height.
static QThread * currentThread()
constexpr size_type size() const noexcept
void resize(qsizetype sz)
\keyword 16-bit Floating Point Support\inmodule QtCore \inheaderfile QFloat16
QHash< int, QWidget * > hash
[35multi]
qDeleteAll(list.begin(), list.end())
QSet< QString >::iterator it
Combined button and popup list for selecting options.
QTextStream & hex(QTextStream &stream)
Calls QTextStream::setIntegerBase(16) on stream and returns stream.
#define Q_BASIC_ATOMIC_INITIALIZER(a)
#define Q_LOGGING_CATEGORY(name,...)
#define qCDebug(category,...)
QT_BEGIN_NAMESPACE constexpr const T & qMin(const T &a, const T &b)
constexpr const T & qBound(const T &min, const T &val, const T &max)
constexpr const T & qMax(const T &a, const T &b)
GLboolean GLboolean GLboolean b
GLsizei const GLfloat * v
[13]
GLuint GLfloat GLfloat GLfloat GLfloat GLfloat z
GLint GLint GLint GLint GLint x
[0]
GLint GLenum GLsizei GLsizei GLsizei depth
GLenum GLuint GLint level
GLfloat GLfloat GLfloat w
[0]
GLint GLsizei GLsizei height
GLboolean GLboolean GLboolean GLboolean a
[7]
GLenum GLuint GLintptr GLsizeiptr size
[1]
GLenum GLenum GLsizei count
GLint GLsizei GLsizei GLenum GLenum GLsizei void * data
const void GLsizei GLsizei stride
GLenum GLuint GLenum GLsizei const GLchar * buf
GLenum GLuint GLintptr offset
GLint GLint GLint GLint GLint GLint GLint GLbitfield mask
GLint GLsizei GLsizei GLenum format
GLfloat GLfloat GLfloat GLfloat h
GLdouble GLdouble GLdouble GLdouble q
GLsizeiptr const void GLenum usage
static Q_CONSTINIT QBasicAtomicInteger< unsigned > seed
static const char * resourceTypeStr(const QRhiResource *res)
static QRhiPassResourceTracker::BufferStage earlierStage(QRhiPassResourceTracker::BufferStage a, QRhiPassResourceTracker::BufferStage b)
QDebug operator<<(QDebug dbg, const QRhiDepthStencilClearValue &v)
static bool isImageLoadStore(QRhiPassResourceTracker::TextureAccess access)
static const char * deviceTypeStr(QRhiDriverInfo::DeviceType type)
\variable QRhiDriverInfo::deviceName
SSL_CTX int(* cb)(SSL *ssl, unsigned char **out, unsigned char *outlen, const unsigned char *in, unsigned int inlen, void *arg)
static constexpr size_t poolSize
Q_CORE_EXPORT bool qEnvironmentVariableIsSet(const char *varName) noexcept
Q_CORE_EXPORT int qEnvironmentVariableIntValue(const char *varName, bool *ok=nullptr) noexcept
unsigned long long quint64
view viewport() -> scroll(dx, dy, deviceRect)
DeviceType
Specifies the graphics device's type, when the information is available.
\variable QRhiReadbackResult::completed
static void changeToStaticUpload(BufferOp *op, QRhiBuffer *buf, quint32 offset, quint32 size, const void *data)
static BufferOp staticUpload(QRhiBuffer *buf, quint32 offset, quint32 size, const void *data)
static BufferOp read(QRhiBuffer *buf, quint32 offset, quint32 size, QRhiReadbackResult *result)
static BufferOp dynamicUpdate(QRhiBuffer *buf, quint32 offset, quint32 size, const void *data)
static void changeToDynamicUpdate(BufferOp *op, QRhiBuffer *buf, quint32 offset, quint32 size, const void *data)
static TextureOp copy(QRhiTexture *dst, QRhiTexture *src, const QRhiTextureCopyDescription &desc)
static TextureOp upload(QRhiTexture *tex, const QRhiTextureUploadDescription &desc)
static TextureOp genMips(QRhiTexture *tex)
static TextureOp read(const QRhiReadbackDescription &rb, QRhiReadbackResult *result)
QRhiShaderResourceBinding::StageFlags stage
static constexpr int MAX_TEX_SAMPLER_ARRAY_SIZE
QRhiShaderResourceBinding::Type type