diff options
author | Laszlo Agocs <laszlo.agocs@qt.io> | 2022-01-07 15:26:53 +0100 |
---|---|---|
committer | Laszlo Agocs <laszlo.agocs@qt.io> | 2022-01-12 20:37:20 +0100 |
commit | bfc713530a6354ce786d3f9bd0f4567844e7240f (patch) | |
tree | 5e760c6b936974046802f056c0dae1c71b987863 /src/gui/rhi/qrhimetal.mm | |
parent | 9d15854138b72be25f4584144eee8f4c0bf8117a (diff) |
rhi: Add queries for vertex input/output limits
Mainly because we do have legacy code in the Qt 5 graphical effects that
tries to dynamically determine the max number of varyings. Make it
easier to port such code.
Change-Id: I846cab2c2fe7b4cd473b5ced0146ca36f1c8169b
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
Reviewed-by: Christian Strømme <christian.stromme@qt.io>
Diffstat (limited to 'src/gui/rhi/qrhimetal.mm')
-rw-r--r-- | src/gui/rhi/qrhimetal.mm | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/src/gui/rhi/qrhimetal.mm b/src/gui/rhi/qrhimetal.mm index e825f56943..b52117c15c 100644 --- a/src/gui/rhi/qrhimetal.mm +++ b/src/gui/rhi/qrhimetal.mm @@ -654,6 +654,10 @@ int QRhiMetal::resourceLimit(QRhi::ResourceLimit limit) const return 2048; case QRhi::MaxUniformBufferRange: return 65536; + case QRhi::MaxVertexInputs: + return 31; + case QRhi::MaxVertexOutputs: + return 15; // use the minimum from MTLGPUFamily1/2/3 default: Q_UNREACHABLE(); return 0; |