vkswapper: always match lock/unlock of the render lock
If a draw event comes from the winsys before we've rendered a buffer we were deadlocking.
This commit is contained in:
parent
a4e82bcef7
commit
8819319ad1
@ -1058,8 +1058,10 @@ _on_window_draw (GstVulkanWindow * window, GstVulkanSwapper * swapper)
|
||||
GError *error = NULL;
|
||||
|
||||
RENDER_LOCK (swapper);
|
||||
if (!swapper->current_buffer)
|
||||
if (!swapper->current_buffer) {
|
||||
RENDER_UNLOCK (swapper);
|
||||
return;
|
||||
}
|
||||
|
||||
/* TODO: perform some rate limiting of the number of redraw events */
|
||||
if (!_render_buffer_unlocked (swapper, swapper->current_buffer, &error))
|
||||
|
Loading…
x
Reference in New Issue
Block a user