summaryrefslogtreecommitdiffstats
path: root/src/render/frontend/qrendercapabilities.cpp
diff options
context:
space:
mode:
authorMike Krus <mike.krus@kdab.com>2020-03-10 11:10:50 +0000
committerMike Krus <mike.krus@kdab.com>2020-03-10 17:35:32 +0000
commit707cfb5884b0a2dacde9b3a7ce47707a5c09744b (patch)
tree12b58311c0d4a8a79e86eb9d33d55d4839cbdb91 /src/render/frontend/qrendercapabilities.cpp
parentbcc3de5bff2bae188a970c0e9572fb3f78c5bfeb (diff)
Add missing documentation
Change-Id: I68d386671c271462a4b156ba9e0f61222a9c79c3 Reviewed-by: Paul Lemire <paul.lemire@kdab.com>
Diffstat (limited to 'src/render/frontend/qrendercapabilities.cpp')
-rw-r--r--src/render/frontend/qrendercapabilities.cpp450
1 files changed, 448 insertions, 2 deletions
diff --git a/src/render/frontend/qrendercapabilities.cpp b/src/render/frontend/qrendercapabilities.cpp
index f614a528c..885c43bc2 100644
--- a/src/render/frontend/qrendercapabilities.cpp
+++ b/src/render/frontend/qrendercapabilities.cpp
@@ -107,7 +107,13 @@ namespace Qt3DRender {
/*!
\class Qt3DRender::QRenderCapabilities
\brief The QRenderCapabilities class holds settings related to available rendering engines
- */
+
+QRenderCapabilities provides details of graphical features that are available at runtime.
+It can be used to decide which code path to use for some algorithms, for example, depending
+on whether compute shaders are available or not.
+
+\since 5.15
+*/
/*!
\qmltype RenderCapabilities
@@ -115,7 +121,13 @@ namespace Qt3DRender {
\since 5.15
\inqmlmodule Qt3D.Render
\instantiates Qt3DRender::QRenderCapabilities
- */
+
+RenderCapabilities provides details of graphical features that are available at runtime.
+It can be used to decide which code path to use for some algorithms, for example, depending
+on whether compute shaders are available or not.
+
+\since 5.15
+*/
/*! \internal */
@@ -240,186 +252,620 @@ QRenderCapabilities::~QRenderCapabilities()
}
+/*!
+\qmlproperty bool RenderCapabilities::valid
+
+true if the data is valid, otherwise Qt 3D failed to query the available hardware.
+
+\readonly
+*/
+/*!
+\property QRenderCapabilities::valid
+
+true if the data is valid, otherwise Qt 3D failed to query the available hardware.
+
+\readonly
+*/
bool QRenderCapabilities::isValid() const
{
Q_D(const QRenderCapabilities);
return d->m_valid;
}
+/*!
+\qmlproperty QRenderCapabilities::API RenderCapabilities::api
+
+Returns which API is currently in use.
+
+\readonly
+*/
+/*!
+\property QRenderCapabilities::api
+
+Returns which API is currently in use.
+
+\readonly
+*/
QRenderCapabilities::API QRenderCapabilities::api() const
{
Q_D(const QRenderCapabilities);
return d->m_api;
}
+/*!
+\qmlproperty bool RenderCapabilities::profile
+
+Returns which profile (if applicable) is currently in use.
+
+\readonly
+*/
+/*!
+\property QRenderCapabilities::profile
+
+Returns which profile (if applicable) is currently in use.
+
+\readonly
+*/
QRenderCapabilities::Profile QRenderCapabilities::profile() const
{
Q_D(const QRenderCapabilities);
return d->m_profile;
}
+/*!
+\qmlproperty int RenderCapabilities::majorVersion
+
+Returns the major version number currently in use.
+
+\readonly
+*/
+/*!
+\property QRenderCapabilities::majorVersion
+
+Returns the major version number currently in use.
+
+\readonly
+*/
int QRenderCapabilities::majorVersion() const
{
Q_D(const QRenderCapabilities);
return d->m_majorVersion;
}
+/*!
+\qmlproperty int RenderCapabilities::minorVersion
+
+Returns the minor version number currently in use.
+
+\readonly
+*/
+/*!
+\property QRenderCapabilities::minorVersion
+
+Returns the minor version number currently in use.
+
+\readonly
+*/
int QRenderCapabilities::minorVersion() const
{
Q_D(const QRenderCapabilities);
return d->m_minorVersion;
}
+/*!
+\qmlproperty QStringList RenderCapabilities::extensions
+
+Returns the list of extensions currently available.
+
+\readonly
+*/
+/*!
+\property QRenderCapabilities::extensions
+
+Returns the list of extensions currently available.
+
+\readonly
+*/
QStringList QRenderCapabilities::extensions() const
{
Q_D(const QRenderCapabilities);
return d->m_extensions;
}
+/*!
+\qmlproperty QString RenderCapabilities::vendor
+
+Returns the vendor identification string.
+
+\readonly
+*/
+/*!
+\property QRenderCapabilities::vendor
+
+Returns the vendor identification string.
+
+\readonly
+*/
QString QRenderCapabilities::vendor() const
{
Q_D(const QRenderCapabilities);
return d->m_vendor;
}
+/*!
+\qmlproperty QString RenderCapabilities::renderer
+
+Returns the device identification string.
+
+\readonly
+*/
+/*!
+\property QRenderCapabilities::renderer
+
+Returns the device identification string.
+
+\readonly
+*/
QString QRenderCapabilities::renderer() const
{
Q_D(const QRenderCapabilities);
return d->m_renderer;
}
+/*!
+\qmlproperty QString RenderCapabilities::driverVersion
+
+Returns the driver version string.
+
+\readonly
+*/
+/*!
+\property QRenderCapabilities::driverVersion
+
+Returns the driver version string.
+
+\readonly
+*/
QString QRenderCapabilities::driverVersion() const
{
Q_D(const QRenderCapabilities);
return d->m_version;
}
+/*!
+\qmlproperty QString RenderCapabilities::glslVersion
+
+Returns the GLSL version string.
+
+\readonly
+*/
+/*!
+\property QRenderCapabilities::glslVersion
+
+Returns the GLSL version string.
+
+\readonly
+*/
QString QRenderCapabilities::glslVersion() const
{
Q_D(const QRenderCapabilities);
return d->m_glslVersion;
}
+/*!
+\qmlproperty int RenderCapabilities::maxSamples
+
+Returns the maximum number of samples available for MSAA.
+
+\readonly
+*/
+/*!
+\property QRenderCapabilities::maxSamples
+
+Returns the maximum number of samples available for MSAA.
+
+\readonly
+*/
int QRenderCapabilities::maxSamples() const
{
Q_D(const QRenderCapabilities);
return d->m_maxSamples;
}
+/*!
+\qmlproperty int RenderCapabilities::maxTextureSize
+
+Returns the maximum size of textures.
+
+\readonly
+*/
+/*!
+\property QRenderCapabilities::maxTextureSize
+
+Returns the maximum size of textures.
+
+\readonly
+*/
int QRenderCapabilities::maxTextureSize() const
{
Q_D(const QRenderCapabilities);
return d->m_maxTextureSize;
}
+/*!
+\qmlproperty int RenderCapabilities::maxTextureUnits
+
+Returns the number of available texture units.
+
+\readonly
+*/
+/*!
+\property QRenderCapabilities::maxTextureUnits
+
+Returns the number of available texture units.
+
+\readonly
+*/
int QRenderCapabilities::maxTextureUnits() const
{
Q_D(const QRenderCapabilities);
return d->m_maxTextureUnits;
}
+/*!
+\qmlproperty int RenderCapabilities::maxTextureLayers
+
+Returns the number of available texture layers.
+
+\readonly
+*/
+/*!
+\property QRenderCapabilities::maxTextureLayers
+
+Returns the number of available texture layers.
+
+\readonly
+*/
int QRenderCapabilities::maxTextureLayers() const
{
Q_D(const QRenderCapabilities);
return d->m_maxTextureLayers;
}
+/*!
+\qmlproperty bool RenderCapabilities::supportsUBO
+
+Returns true if UBOs are supported.
+
+\readonly
+*/
+/*!
+\property QRenderCapabilities::supportsUBO
+
+Returns true if UBOs are supported.
+
+\readonly
+*/
bool QRenderCapabilities::supportsUBO() const
{
Q_D(const QRenderCapabilities);
return d->m_supportsUBO;
}
+/*!
+\qmlproperty int RenderCapabilities::maxUBOSize
+
+Returns the maximum size of UBOs, if supported.
+
+\readonly
+*/
+/*!
+\property QRenderCapabilities::maxUBOSize
+
+Returns the maximum size of UBOs, if supported.
+
+\readonly
+*/
int QRenderCapabilities::maxUBOSize() const
{
Q_D(const QRenderCapabilities);
return d->m_maxUBOSize;
}
+/*!
+\qmlproperty int RenderCapabilities::maxUBOBindings
+
+Returns the maximum number of available UBO binding points, if supported.
+
+\readonly
+*/
+/*!
+\property QRenderCapabilities::maxUBOBindings
+
+Returns the maximum number of available UBO binding points, if supported.
+
+\readonly
+*/
int QRenderCapabilities::maxUBOBindings() const
{
Q_D(const QRenderCapabilities);
return d->m_maxUBOBindings;
}
+/*!
+\qmlproperty bool RenderCapabilities::supportsSSBO
+
+Returns true if SSBOs are supported.
+
+\readonly
+*/
+/*!
+\property QRenderCapabilities::supportsSSBO
+
+Returns true if SSBOs are supported.
+
+\readonly
+*/
bool QRenderCapabilities::supportsSSBO() const
{
Q_D(const QRenderCapabilities);
return d->m_supportsSSBO;
}
+/*!
+\qmlproperty int RenderCapabilities::maxSSBOSize
+
+Returns the maximum size of SSBOs, if available.
+
+\readonly
+*/
+/*!
+\property QRenderCapabilities::maxSSBOSize
+
+Returns the maximum size of SSBOs, if available.
+
+\readonly
+*/
int QRenderCapabilities::maxSSBOSize() const
{
Q_D(const QRenderCapabilities);
return d->m_maxSSBOSize;
}
+/*!
+\qmlproperty int RenderCapabilities::maxSSBOBindings
+
+Returns the maximum number of available SSBO binding points, if supported.
+
+\readonly
+*/
+/*!
+\property QRenderCapabilities::maxSSBOBindings
+
+Returns the maximum number of available SSBO binding points, if supported.
+
+\readonly
+*/
int QRenderCapabilities::maxSSBOBindings() const
{
Q_D(const QRenderCapabilities);
return d->m_maxSSBOBindings;
}
+/*!
+\qmlproperty bool RenderCapabilities::supportsImageStore
+
+Returns true if Image Store operations are supported.
+
+\readonly
+*/
+/*!
+\property QRenderCapabilities::supportsImageStore
+
+Returns true if Image Store operations are supported.
+
+\readonly
+*/
bool QRenderCapabilities::supportsImageStore() const
{
Q_D(const QRenderCapabilities);
return d->m_supportsImageStore;
}
+/*!
+\qmlproperty int RenderCapabilities::maxImageUnits
+
+Returns the maximum number of available image units.
+
+\readonly
+*/
+/*!
+\property QRenderCapabilities::maxImageUnits
+
+Returns the maximum number of available image units.
+
+\readonly
+*/
int QRenderCapabilities::maxImageUnits() const
{
Q_D(const QRenderCapabilities);
return d->m_maxImageUnits;
}
+/*!
+\qmlproperty bool RenderCapabilities::supportsCompute
+
+Returns true if Compute Shaders are supported.
+
+\readonly
+*/
+/*!
+\property QRenderCapabilities::supportsCompute
+
+Returns true if Compute Shaders are supported.
+
+\readonly
+*/
bool QRenderCapabilities::supportsCompute() const
{
Q_D(const QRenderCapabilities);
return d->m_supportCompute;
}
+/*!
+\qmlproperty int RenderCapabilities::maxWorkGroupCountX
+
+Returns the maximum number of available Compute Shader workgroups in the X axis.
+
+\readonly
+*/
+/*!
+\property QRenderCapabilities::maxWorkGroupCountX
+
+Returns the maximum number of available Compute Shader workgroups in the X axis.
+
+\readonly
+*/
int QRenderCapabilities::maxWorkGroupCountX() const
{
Q_D(const QRenderCapabilities);
return d->m_maxWorkGroupCount[0];
}
+/*!
+\qmlproperty int RenderCapabilities::maxWorkGroupCountY
+
+Returns the maximum number of available Compute Shader workgroups in the Y axis.
+
+\readonly
+*/
+/*!
+\property QRenderCapabilities::maxWorkGroupCountY
+
+Returns the maximum number of available Compute Shader workgroups in the Y axis.
+
+\readonly
+*/
int QRenderCapabilities::maxWorkGroupCountY() const
{
Q_D(const QRenderCapabilities);
return d->m_maxWorkGroupCount[1];
}
+/*!
+\qmlproperty int RenderCapabilities::maxWorkGroupCountZ
+
+Returns the maximum number of available Compute Shader workgroups in the Z axis.
+
+\readonly
+*/
+/*!
+\property QRenderCapabilities::maxWorkGroupCountZ
+
+Returns the maximum number of available Compute Shader workgroups in the Z axis.
+
+\readonly
+*/
int QRenderCapabilities::maxWorkGroupCountZ() const
{
Q_D(const QRenderCapabilities);
return d->m_maxWorkGroupCount[2];
}
+/*!
+\qmlproperty int RenderCapabilities::maxWorkGroupSizeX
+
+Returns the maximum size of Compute Shader local workgroups in the X axis.
+
+\readonly
+*/
+/*!
+\property QRenderCapabilities::maxWorkGroupSizeX
+
+Returns the maximum size of Compute Shader local workgroups in the X axis.
+
+\readonly
+*/
int QRenderCapabilities::maxWorkGroupSizeX() const
{
Q_D(const QRenderCapabilities);
return d->m_maxWorkGroupSize[0];
}
+/*!
+\qmlproperty int RenderCapabilities::maxWorkGroupSizeY
+
+Returns the maximum size of Compute Shader local workgroups in the Y axis.
+
+\readonly
+*/
+/*!
+\property QRenderCapabilities::maxWorkGroupSizeY
+
+Returns the maximum size of Compute Shader local workgroups in the Y axis.
+
+\readonly
+*/
int QRenderCapabilities::maxWorkGroupSizeY() const
{
Q_D(const QRenderCapabilities);
return d->m_maxWorkGroupSize[1];
}
+/*!
+\qmlproperty int RenderCapabilities::maxWorkGroupSizeZ
+
+Returns the maximum size of Compute Shader local workgroups in the Z axis.
+
+\readonly
+*/
+/*!
+\property QRenderCapabilities::maxWorkGroupSizeZ
+
+Returns the maximum size of Compute Shader local workgroups in the Z axis.
+
+\readonly
+*/
int QRenderCapabilities::maxWorkGroupSizeZ() const
{
Q_D(const QRenderCapabilities);
return d->m_maxWorkGroupSize[2];
}
+/*!
+\qmlproperty int RenderCapabilities::maxComputeInvocations
+
+Returns the maximum number of Compute Shaders available.
+
+\readonly
+*/
+/*!
+\property QRenderCapabilities::maxComputeInvocations
+
+Returns the maximum number of Compute Shaders available.
+
+\readonly
+*/
int QRenderCapabilities::maxComputeInvocations() const
{
Q_D(const QRenderCapabilities);
return d->m_maxComputeInvocations;
}
+/*!
+\qmlproperty int RenderCapabilities::maxComputeSharedMemorySize
+
+Returns the maximum amount of shared memory available for Compute Shaders.
+
+\readonly
+*/
+/*!
+\property QRenderCapabilities::maxComputeSharedMemorySize
+
+Returns the maximum amount of shared memory available for Compute Shaders.
+
+\readonly
+*/
int QRenderCapabilities::maxComputeSharedMemorySize() const
{
Q_D(const QRenderCapabilities);