diff options
author | Paul Lemire <paul.lemire@kdab.com> | 2017-12-22 14:06:04 +0100 |
---|---|---|
committer | Paul Lemire <paul.lemire@kdab.com> | 2018-01-16 07:46:01 +0000 |
commit | 907869e8f87bab55671bfabf29f773cc01f40b68 (patch) | |
tree | 6cd673235d34fd13cd33fb66df9b1d939c729e3c /tests/auto/render/commons | |
parent | 855a19b41237711037f85ae671d7999021b4cc4e (diff) |
Scene3D: allow to force blocking rendering
When using Scene3D, when the jobs preparing the render commands for the 3D
scene take too long (more than the QtQuick refresh rate), the Scene3D wouldn't
render anything when QtQuick requested it to. Then, the next time
it would be asked to render (next QtQuick frame), if the jobs have finished by
then, it will render. If the jobs are still not ready, then the above process
is repeated.
This patch introduces an environment variable SCENE3D_BLOCKING_RENDERMODE which
can be set to force Scene3D to wait (for at most 10ms) instead of returning
immediately for the jobs being ready.
Change-Id: I2db10e622570a7bc8a2e2cbaff113c110135cd3e
Reviewed-by: Sean Harmer <sean.harmer@kdab.com>
Diffstat (limited to 'tests/auto/render/commons')
-rw-r--r-- | tests/auto/render/commons/testrenderer.h | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/tests/auto/render/commons/testrenderer.h b/tests/auto/render/commons/testrenderer.h index 74f529fa0..269eebbe9 100644 --- a/tests/auto/render/commons/testrenderer.h +++ b/tests/auto/render/commons/testrenderer.h @@ -52,7 +52,7 @@ public: void shutdown() Q_DECL_OVERRIDE {} void releaseGraphicsResources() Q_DECL_OVERRIDE {} void render() Q_DECL_OVERRIDE {} - void doRender() Q_DECL_OVERRIDE {} + void doRender(bool scene3dBlocking = false) Q_DECL_OVERRIDE { Q_UNUSED(scene3dBlocking); } void cleanGraphicsResources() Q_DECL_OVERRIDE {} bool isRunning() const Q_DECL_OVERRIDE { return true; } bool shouldRender() Q_DECL_OVERRIDE { return true; } |