diff options
author | Brecht Van Lommel <brechtvanlommel@gmail.com> | 2019-01-09 18:57:01 +0300 |
---|---|---|
committer | Brecht Van Lommel <brechtvanlommel@gmail.com> | 2019-01-09 19:16:29 +0300 |
commit | 0bb0e07e6109fc474b8ff1a1d2422e40bd3bec40 (patch) | |
tree | 8aa7fc5e3813eda383ae3d6278b5d35190d6a2a4 /intern/cycles/blender | |
parent | b7fb3296c101bf408455352ec9784a8870672c81 (diff) |
Fix Cycles viewport render doing some unnecessary work at the start.
In some cases it would load adaptive kernels or even start rendering
twice because the first time the scene was not fully synced yet.
Diffstat (limited to 'intern/cycles/blender')
-rw-r--r-- | intern/cycles/blender/blender_session.cpp | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/intern/cycles/blender/blender_session.cpp b/intern/cycles/blender/blender_session.cpp index 30ae0bc813d..dfa92dd1bc7 100644 --- a/intern/cycles/blender/blender_session.cpp +++ b/intern/cycles/blender/blender_session.cpp @@ -110,9 +110,6 @@ BlenderSession::~BlenderSession() void BlenderSession::create() { create_session(); - - if(b_v3d) - session->start(); } void BlenderSession::create_session() @@ -784,7 +781,6 @@ void BlenderSession::synchronize() { free_session(); create_session(); - session->start(); return; } @@ -833,6 +829,10 @@ void BlenderSession::synchronize() /* reset time */ start_resize_time = 0.0; } + + /* Start rendering thread, if it's not running already. Do this + * after all scene data has been synced at least once. */ + session->start(); } bool BlenderSession::draw(int w, int h) |