diff options
author | Sergey Sharybin <sergey.vfx@gmail.com> | 2013-01-01 20:15:13 +0400 |
---|---|---|
committer | Sergey Sharybin <sergey.vfx@gmail.com> | 2013-01-01 20:15:13 +0400 |
commit | 2e0e2cb17056892cefeefeef9e0fd693084ef71f (patch) | |
tree | d5ff4c0b5d135cd3c3240efa6b167eed7b351e6a /intern/cycles/render/session.cpp | |
parent | b88836a45ba03d97c23bda95ca4ead6b5f8f2637 (diff) |
Highlight currently rendering tiles
This commit implements highlight of tiles which are being currently
rendered for both Blender Internal and Cycles (and should be possible
to use it for other external engines as well).
Couple of implementation details:
- Added one extra boolean flag to render engine which should be set
to truth if render engine wants to highlight tiles. If so, property
use_highlight_tiles should be set to True.
- Render Part's ready boolena was changed by status enum, which could
be NONE, IN_PROGRESS and READY. All render part with IN_PROGRESS
status will be highlighted in image editor.
- For external engines render part's status is filling in automatically.
Initially all render parts has got NONE status, then one external
engine acquire render result, corresponding part will change status
to IN_PROGRESS. As soon as render result is finished, corresponding
render part will change status to FINISHED
This should make it easy to highlight tiles for other engines as well.
Diffstat (limited to 'intern/cycles/render/session.cpp')
-rw-r--r-- | intern/cycles/render/session.cpp | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/intern/cycles/render/session.cpp b/intern/cycles/render/session.cpp index 1d1a3d54893..36948adce17 100644 --- a/intern/cycles/render/session.cpp +++ b/intern/cycles/render/session.cpp @@ -357,7 +357,7 @@ bool Session::acquire_tile(Device *tile_device, RenderTile& rtile) tile_lock.unlock(); - /* in case of a permant buffer, return it, otherwise we will allocate + /* in case of a permanent buffer, return it, otherwise we will allocate * a new temporary buffer */ if(!params.background) { tile_manager.state.buffer.get_offset_stride(rtile.offset, rtile.stride); @@ -411,6 +411,12 @@ bool Session::acquire_tile(Device *tile_device, RenderTile& rtile) rtile.rgba = 0; rtile.buffers = tilebuffers; + /* this will tag tile as IN PROGRESS in blender-side render pipeline, + * which is needed to highlight currently rendering tile before first + * sample was processed for it + */ + update_tile_sample(rtile); + return true; } |