diff options
author | Laszlo Agocs <laszlo.agocs@qt.io> | 2020-11-01 14:57:50 +0100 |
---|---|---|
committer | Laszlo Agocs <laszlo.agocs@qt.io> | 2020-11-02 13:48:09 +0100 |
commit | 2b99430671e37427a990973df37e62ad8cdebe8b (patch) | |
tree | 85ea4654d2aec23b1e60c85e6562333cede95b9f /src/quick/doc | |
parent | 4391ddd0015db183ea103e4587653793485dea9d (diff) |
sg docs: Add a note about direct graphics API usage
Change-Id: I7edc83cc945a1e11d0b1197fa0b26e10b69a99c8
Reviewed-by: Andy Nichols <andy.nichols@qt.io>
Diffstat (limited to 'src/quick/doc')
-rw-r--r-- | src/quick/doc/src/concepts/visualcanvas/scenegraph.qdoc | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/src/quick/doc/src/concepts/visualcanvas/scenegraph.qdoc b/src/quick/doc/src/concepts/visualcanvas/scenegraph.qdoc index 7cffd8408f..691988999b 100644 --- a/src/quick/doc/src/concepts/visualcanvas/scenegraph.qdoc +++ b/src/quick/doc/src/concepts/visualcanvas/scenegraph.qdoc @@ -358,6 +358,15 @@ this resource in a Qt Quick scene in a custom QQuickItem, is demonstrated in the \l {Scene Graph - Metal Texture Import} example. That example uses Metal, the concepts however apply to all other graphics APIs as well. +\warning Starting with Qt 6.0, direct usage of the underlying graphics API must +be enclosed by a call to \l QQuickWindow::beginExternalCommands() and \l +QQuickWindow::endExternalCommands(). This concept may be familiar from \l +QPainter::beginNativePainting(), and serves a similar purpose: it allows the Qt +Quick Scene Graph to recognize that any cached state and assumptions about the +state within the currently recorded render pass, if there is one, are now +invalid, because the application code may have altered it by working directly +with the underlying graphics API. + \warning When mixing OpenGL content with scene graph rendering, it is important the application does not leave the OpenGL context in a state with buffers bound, attributes enabled, special values in the z-buffer |