Warnings in the before/afterRender docs
authorGunnar Sletta <gunnar.sletta@nokia.com>
Mon, 6 Feb 2012 15:40:55 +0000 (16:40 +0100)
committerQt by Nokia <qt-info@nokia.com>
Mon, 6 Feb 2012 19:16:20 +0000 (20:16 +0100)
Change-Id: I2311e574b45d518893ef868fdcf51053dc43bb13
Reviewed-by: Kim M. Kalland <kim.kalland@nokia.com>
src/quick/items/qquickcanvas.cpp

index 72300f9..660d7df 100644 (file)
@@ -1891,9 +1891,12 @@ QDeclarativeIncubationController *QQuickCanvas::incubationController() const
     The GL context used for rendering the scene graph will be bound
     at this point.
 
-    Since this signal is emitted from the scene graph rendering thread, the receiver should
-    be on the scene graph thread or the connection should be Qt::DirectConnection.
+    \warning Since this signal is emitted from the scene graph rendering thread, the
+    receiver should be on the scene graph thread or the connection should be Qt::DirectConnection.
 
+    \warning Make very sure that a signal handler for beforeRendering leaves the GL
+    context in the same state as it was when the signal handler was entered. Failing to
+    do so can result in the scene not rendering properly.
 */
 
 /*!
@@ -1906,8 +1909,12 @@ QDeclarativeIncubationController *QQuickCanvas::incubationController() const
 
     The GL context used for rendering the scene graph will be bound at this point.
 
-    Since this signal is emitted from the scene graph rendering thread, the receiver should
-    be on the scene graph thread or the connection should be Qt::DirectConnection.
+    \warning Since this signal is emitted from the scene graph rendering thread, the
+    receiver should be on the scene graph thread or the connection should be Qt::DirectConnection.
+
+    \warning Make very sure that a signal handler for afterRendering() leaves the GL
+    context in the same state as it was when the signal handler was entered. Failing to
+    do so can result in the scene not rendering properly.
  */