summaryrefslogtreecommitdiffstats
path: root/examples/vulkan/doc/src/hellovulkanwindow.qdoc
diff options
context:
space:
mode:
authorLaszlo Agocs <laszlo.agocs@qt.io>2023-03-22 16:26:16 +0100
committerLaszlo Agocs <laszlo.agocs@qt.io>2023-03-22 23:17:55 +0100
commit0e8d347c6a99c2729eb5d32cfc70f4fb2755f940 (patch)
tree047457c6f76124620ae853f0eaa4ecb17ea8c2c2 /examples/vulkan/doc/src/hellovulkanwindow.qdoc
parentb5b954fac12414c315369344b1664bf220a59dad (diff)
Remove hellovulkanwindow example
The idea being that hellovulkantriangle demonstrates the same things. As a getting started tutorial hellovulkanwindow is the ideal example, but then again QVulkanWindow is not something we want to promote much in Qt 6. Some of the docs are moved to hellovulkantriangle. Pick-to: 6.5 Change-Id: Icbfff70b4a4c7e4c0863a937f3c16038c0b03fbe Reviewed-by: Christian Strømme <christian.stromme@qt.io>
Diffstat (limited to 'examples/vulkan/doc/src/hellovulkanwindow.qdoc')
-rw-r--r--examples/vulkan/doc/src/hellovulkanwindow.qdoc78
1 files changed, 0 insertions, 78 deletions
diff --git a/examples/vulkan/doc/src/hellovulkanwindow.qdoc b/examples/vulkan/doc/src/hellovulkanwindow.qdoc
deleted file mode 100644
index 4b94457265..0000000000
--- a/examples/vulkan/doc/src/hellovulkanwindow.qdoc
+++ /dev/null
@@ -1,78 +0,0 @@
-// Copyright (C) 2017 The Qt Company Ltd.
-// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GFDL-1.3-no-invariants-only
-
-/*!
- \example hellovulkanwindow
- \meta installpath vulkan
- \title Hello Vulkan Window Example
- \ingroup examples-vulkan
- \brief Shows the basics of using QVulkanWindow.
-
- The \e{Hello Vulkan Window Example} shows the basics of using QVulkanWindow
- in order to display rendering with the Vulkan graphics API on systems that
- support this.
-
- \image hellovulkanwindow.png
-
- In this example there will be no actual rendering: it simply begins and
- ends a render pass, which results in clearing the buffers to a fixed value.
- The color buffer clear value changes on every frame.
-
- \section1 Startup
-
- Each Qt application using Vulkan will have to have a \c{Vulkan instance}
- which encapsulates application-level state and initializes a Vulkan library.
-
- A QVulkanWindow must always be associated with a QVulkanInstance and hence
- the example performs instance creation before the window. The
- QVulkanInstance object must also outlive the window.
-
- \snippet hellovulkanwindow/main.cpp 0
-
- The example enables validation layers, when supported. When the requested
- layers are not present, the request will be ignored. Additional layers and
- extensions can be enabled in a similar manner.
-
- \snippet hellovulkanwindow/main.cpp 1
-
- Once the instance is ready, it is time to create a window. Note that \c w
- lives on the stack and is declared after \c inst.
-
- \section1 The QVulkanWindow Subclass
-
- To add custom functionality to a QVulkanWindow, subclassing is used. This
- follows the existing patterns from QOpenGLWindow and QOpenGLWidget.
- However, QVulkanWindow utilizes a separate QVulkanWindowRenderer object.
- This resembles QQuickFramebufferObject, and allows better separation of the
- functions that are supposed to be reimplemented.
-
- \snippet hellovulkanwindow/hellovulkanwindow.h 0
-
- The QVulkanWindow subclass reimplements the factory function
- QVulkanWindow::createRenderer(). This simply returns a new instance of the
- QVulkanWindowRenderer subclass. In order to be able to access various
- Vulkan resources via the window object, a pointer to the window is passed
- and stored via the constructor.
-
- \snippet hellovulkanwindow/hellovulkanwindow.cpp 0
-
- Graphics resource creation and destruction is typically done in one of the
- init - resource functions.
-
- \snippet hellovulkanwindow/hellovulkanwindow.cpp 1
-
- \section1 The Actual Rendering
-
- QVulkanWindow subclasses queue their draw calls in their reimplementation
- of QVulkanWindowRenderer::startNextFrame(). Once done, they are required to
- call back QVulkanWindow::frameReady(). The example has no asynchronous
- command generation, so the frameReady() call is made directly from
- startNextFrame().
-
- \snippet hellovulkanwindow/hellovulkanwindow.cpp 2
-
- To get continuous updates, the example simply invokes
- QWindow::requestUpdate() in order to schedule a repaint.
-
- \include examples-run.qdocinc
-*/