From 440ef7356aa45f908b755489423d06209514f875 Mon Sep 17 00:00:00 2001 From: Sergey Sharybin Date: Tue, 15 Jan 2013 07:56:38 +0000 Subject: Two threading issues: - Drawing masks in image editor requires LOCK_DRAW_IMAGE around ED_space_image_get* functions since they'll acquire image buffer. Lock is needed because viewers will be modified directly in compositor (see commend in draw_image_main) - Seems that was wrong order of invalidating render result and viewer image invalidation happened in Composite node, which could easily lead to thread lock. --- source/blender/compositor/operations/COM_CompositorOperation.cpp | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'source/blender/compositor/operations') diff --git a/source/blender/compositor/operations/COM_CompositorOperation.cpp b/source/blender/compositor/operations/COM_CompositorOperation.cpp index 141d071dddc..e6a49082a71 100644 --- a/source/blender/compositor/operations/COM_CompositorOperation.cpp +++ b/source/blender/compositor/operations/COM_CompositorOperation.cpp @@ -91,14 +91,14 @@ void CompositorOperation::deinitExecution() } } - BLI_lock_thread(LOCK_DRAW_IMAGE); - BKE_image_signal(BKE_image_verify_viewer(IMA_TYPE_R_RESULT, "Render Result"), NULL, IMA_SIGNAL_FREE); - BLI_unlock_thread(LOCK_DRAW_IMAGE); - if (re) { RE_ReleaseResult(re); re = NULL; } + + BLI_lock_thread(LOCK_DRAW_IMAGE); + BKE_image_signal(BKE_image_verify_viewer(IMA_TYPE_R_RESULT, "Render Result"), NULL, IMA_SIGNAL_FREE); + BLI_unlock_thread(LOCK_DRAW_IMAGE); } else { if (this->m_outputBuffer) { -- cgit v1.2.3