summaryrefslogtreecommitdiffstats
path: root/src/api/studio3d/doc/src/module.qdoc
blob: 98b134ed571dd5ce6bb444664398f057cd95af8e (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
/****************************************************************************
**
** Copyright (C) 2019 The Qt Company Ltd.
** Contact: https://www.qt.io/licensing/
**
** This file is part of Qt 3D Studio.
**
** $QT_BEGIN_LICENSE:FDL$
** Commercial License Usage
** Licensees holding valid commercial Qt licenses may use this file in
** accordance with the commercial license agreement provided with the
** Software or, alternatively, in accordance with the terms contained in
** a written agreement between you and The Qt Company. For licensing terms
** and conditions see https://www.qt.io/terms-conditions. For further
** information use the contact form at https://www.qt.io/contact-us.
**
** GNU Free Documentation License Usage
** Alternatively, this file may be used under the terms of the GNU Free
** Documentation License version 1.3 as published by the Free Software
** Foundation and appearing in the file included in the packaging of
** this file. Please review the following information to ensure
** the GNU Free Documentation License version 1.3 requirements
** will be met: https://www.gnu.org/licenses/fdl-1.3.html.
** $QT_END_LICENSE$
**
****************************************************************************/

/*!
    \module OpenGLRuntime
    \title \RUNTIME C++ Classes
    \ingroup modules

    \brief The \RUNTIME provides a number of C++ classes to
    integrate and control Qt 3D Studio presentations in Qt applications.

    To include the definitions of the module's classes, use the following directive:

    \code
    #include <QtStudio3D>
    \endcode

    To link against the module, add this line to your \l qmake \c .pro file:

    \badcode
    QT += studio3d
    \endcode

    \section1 Integrating

    The main class is \l Q3DSSurfaceViewer. Q3DSSurfaceViewer allows targeting a QWindow or an
    offscreen render target (an OpenGL texture).

    \note Qt applications based on QML and Qt Quick will rather want to use the
    \l Studio3D type from \l {\RUNTIME QML Types}.

    \section1 Controlling

    Each \l Q3DSSurfaceViewer instance exposes a \l
    Q3DSPresentation. This, possibly in combination with \l Q3DSDataInput or
    \l Q3DSElement objects, allows:

    \list

    \li changing scene object properties (for example, the transform of a
    model, colors and other settings of a material, etc.),

    \li changing slides (thus starting the relevant animations and applying the
    scene object property changes associated with the new slide),

    \li and controlling the timeline (the current playback position for the
    key-frame based animations) both on the main scene and on individual
    Component nodes.

    \endlist

    \section1 Classes
*/

/*!
    \qmlmodule QtStudio3D.OpenGL \QtVer
    \title \RUNTIME QML Types
    \ingroup qmlmodules

    \brief QML Types for the \RUNTIME module.

    The \RUNTIME provides a number of QML types to integrate and
    control Qt 3D Studio presentations in Qt Quick applications. These types
    can be imported into your application using the following import statement
    in your \c{.qml} file:

    \qml \QtVer
    import QtStudio3D.OpenGL \1
    \endqml

    The main type for embedding a Qt 3D Studio presentations into a Qt Quick
    scene is \l Studio3D. Many of the other types correspond to a C++ class in
    the API offered to non-QML based applications, providing the same level of
    control described in \l{\RUNTIME C++ Classes}{the C++ reference}.

    There are also QML types that offer functionality not available via the C++
    classes. The \l SubPresentationSettings type allows defining \c{QML
    sub-presentations} (live Qt Quick scenes composed into the 3D scene either
    as Qt 3D Studio layers or as texture maps) in-line, inside a Studio3D
    element, without having to deploy them as separate \c .qml files.

    \note the \l Behavior type is to be used by \c{behavior scripts} (\c .qml
    snippets associated with scene objects during the design phase in Qt 3D
    Studio) and is not available in the main application code.

    \section1 QML Types
*/