summaryrefslogtreecommitdiffstats
path: root/src/gui/vulkan
diff options
context:
space:
mode:
authorLaszlo Agocs <laszlo.agocs@qt.io>2017-03-24 14:16:32 +0100
committerLaszlo Agocs <laszlo.agocs@qt.io>2017-03-26 22:40:18 +0000
commitdfef2e3f3eb2ca51e47ac26ee58c5569892d0128 (patch)
tree4c059288d61d4681a8cf89e5f1d2865aa0c11c8a /src/gui/vulkan
parent92dce210a2ca97161b4fc9cb1991585816982ff7 (diff)
Clarify the front face winding order in the Vulkan examples
After applying the correction matrix the front face is CW, not CCW. The examples work either way but fix them up to avoid reader confusion. Change-Id: I491e6dc17c21897a59f36d32061e937f2b6c4c9d Reviewed-by: Andy Nichols <andy.nichols@qt.io>
Diffstat (limited to 'src/gui/vulkan')
-rw-r--r--src/gui/vulkan/qvulkanwindow.cpp4
1 files changed, 4 insertions, 0 deletions
diff --git a/src/gui/vulkan/qvulkanwindow.cpp b/src/gui/vulkan/qvulkanwindow.cpp
index d5af71cd4b..b158fa7e94 100644
--- a/src/gui/vulkan/qvulkanwindow.cpp
+++ b/src/gui/vulkan/qvulkanwindow.cpp
@@ -2692,6 +2692,10 @@ QImage QVulkanWindow::grab()
without any further corrections to the vertex Z positions, while using the
projection matrices retrieved from the QMatrix4x4 functions, such as
QMatrix4x4::perspective(), as-is.
+
+ \note With vertex data following the default OpenGL rules (that is, the
+ front face being CCW), the correct winding order in the rasterization state
+ after applying this matrix is clockwise (\c{VK_FRONT_FACE_CLOCKWISE}).
*/
const QMatrix4x4 *QVulkanWindow::clipCorrectionMatrix()
{