Debian Codegraph @

tests/manual/widgets-scene3d/doc/src/widgets-scene3d.qdoc

raw
1 // Copyright (C) 2016 The Qt Company Ltd.
2 // SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GFDL-1.3-no-invariants-only
3
4 /*!
5 \example widgets-scene3d
6 \title Qt 3D: Scene3D QML with Widgets Example
7 \ingroup qt3d-examples-qml
8 \brief A QWidget-based application with a QML scene containing a 3D scene.
9
10 \image widgets-scene3d.png
11
12 \e {widgets-scene3D} demonstrates visualizing a 3D scene from a
13 QWidget-based application using QQuickWidget.
14
15 The actual 3D scene is the same as in the \e {scene3d} example.
16
17 This approach is different from the one based on
18 QWidget::createWindowContainer() demonstrated in \e {basicshapes-cpp}
19 because it does not create a native window for the Qt 3D content. Rather,
20 it uses QQuickWidget, a genuine QWidget subclass to compose the Qt Quick
21 and Qt 3D content together with the traditional widgets.
22
23 \note Be aware of the performance implications. While this approach is very
24 flexible in the sense that it allows mixing QML and Qt 3D with widgets
25 without clipping or stacking issues, using Scene3D in a QQuickWidget
26 involves rendering to offscreen render targets (via framebuffer objects)
27 twice. This is not always desirable for more complex scenes. For those the
28 native window based approach shown in \e {basicshapes-cpp} will likely be a
29 better choice.
30
31 \include examples-run.qdocinc
32 */