summaryrefslogtreecommitdiffstats
path: root/tests/manual/rhi/triquadcube
diff options
context:
space:
mode:
authorLaszlo Agocs <laszlo.agocs@qt.io>2019-06-24 10:22:50 +0200
committerLaszlo Agocs <laszlo.agocs@qt.io>2019-07-01 17:34:29 +0200
commit854ddb0301ae677a31286da4476318f4e6b74e3f (patch)
tree9e9cdaa09a3d6f12f7636abdec0de15ed694e8a2 /tests/manual/rhi/triquadcube
parent56fb2266f2d224ba58d262640f318a0439a9fa32 (diff)
rhi: Enhance line width and point size support
...but this will vary between backends, or in some cases even between implementations of the same API. Point size is settable only via the vertex shader (gl_PointSize). It is silently ignored with D3D and HLSL. Line widths other than 1 are supported only on OpenGL and Vulkan. (but this is in fact deprecated with GL and optional with Vulkan) Add QRhi::Feature values for both. The line width is now settable on QRhiGraphicsPipeline. It is not a dynamic state since the static, per-pipeline width is good enough for most cases. (and the feature is not supported on half of the backends anyways so it will get limited use in practice). Change-Id: I6d3a32269527c452b794b2cb8b0f03101eab40b2 Reviewed-by: Lars Knoll <lars.knoll@qt.io>
Diffstat (limited to 'tests/manual/rhi/triquadcube')
-rw-r--r--tests/manual/rhi/triquadcube/triquadcube.cpp2
1 files changed, 2 insertions, 0 deletions
diff --git a/tests/manual/rhi/triquadcube/triquadcube.cpp b/tests/manual/rhi/triquadcube/triquadcube.cpp
index 8c7f5db042..1b390c34ed 100644
--- a/tests/manual/rhi/triquadcube/triquadcube.cpp
+++ b/tests/manual/rhi/triquadcube/triquadcube.cpp
@@ -172,6 +172,8 @@ void Window::customInit()
qDebug("isFeatureSupported(RedOrAlpha8IsRed): %d", m_r->isFeatureSupported(QRhi::RedOrAlpha8IsRed));
qDebug("isFeatureSupported(ElementIndexUint): %d", m_r->isFeatureSupported(QRhi::ElementIndexUint));
qDebug("isFeatureSupported(Compute): %d", m_r->isFeatureSupported(QRhi::Compute));
+ qDebug("isFeatureSupported(WideLines): %d", m_r->isFeatureSupported(QRhi::WideLines));
+ qDebug("isFeatureSupported(VertexShaderPointSize): %d", m_r->isFeatureSupported(QRhi::VertexShaderPointSize));
qDebug("Min 2D texture width/height: %d", m_r->resourceLimit(QRhi::TextureSizeMin));
qDebug("Max 2D texture width/height: %d", m_r->resourceLimit(QRhi::TextureSizeMax));
qDebug("Max color attachment count: %d", m_r->resourceLimit(QRhi::MaxColorAttachments));