evas/async_render: remove block/unblock of render thread.

This reverts commit 42a46214c4.
This commit is contained in:
Ulisses Furquim 2013-09-02 20:01:37 -03:00
parent 31b1cc6e3e
commit 063f076aed
3 changed files with 2 additions and 25 deletions

View File

@ -2251,7 +2251,6 @@ _canvas_render_dump(Eo *eo_e EINA_UNUSED, void *_pd, va_list *list EINA_UNUSED)
Evas_Layer *lay;
evas_render_rendering_wait(e);
evas_thread_queue_block();
evas_cache_async_freeze();
EINA_INLIST_FOREACH(e->layers, lay)
@ -2279,7 +2278,6 @@ _canvas_render_dump(Eo *eo_e EINA_UNUSED, void *_pd, va_list *list EINA_UNUSED)
GC_ALL(evas_object_image_load_opts_cow);
GC_ALL(evas_object_image_state_cow);
evas_cache_async_thaw();
evas_thread_queue_unblock();
}
void

View File

@ -4,7 +4,6 @@
static Eina_Thread evas_thread_worker;
static Eina_Condition evas_thread_queue_condition;
static Eina_Lock evas_thread_block_lock;
static Eina_Lock evas_thread_queue_lock;
static Eina_Bool evas_thread_queue_ready = EINA_FALSE;
static Eina_Inarray evas_thread_queue;
@ -56,19 +55,7 @@ evas_thread_queue_flush(Evas_Thread_Command_Cb cb, void *data)
evas_thread_queue_append(cb, data, EINA_TRUE);
}
EAPI void
evas_thread_queue_block(void)
{
eina_lock_take(&evas_thread_block_lock);
}
EAPI void
evas_thread_queue_unblock(void)
{
eina_lock_release(&evas_thread_block_lock);
}
static void *
static void*
evas_thread_worker_func(void *data EINA_UNUSED, Eina_Thread thread EINA_UNUSED)
{
while (1)
@ -96,8 +83,6 @@ evas_thread_worker_func(void *data EINA_UNUSED, Eina_Thread thread EINA_UNUSED)
continue;
}
eina_lock_take(&evas_thread_block_lock);
cmd = evas_thread_queue.members;
evas_thread_queue.members = evas_thread_queue_cache;
evas_thread_queue_cache = cmd;
@ -124,7 +109,6 @@ evas_thread_worker_func(void *data EINA_UNUSED, Eina_Thread thread EINA_UNUSED)
cmd++;
len--;
}
eina_lock_release(&evas_thread_block_lock);
}
out:
@ -144,8 +128,6 @@ evas_thread_init(void)
if (!eina_lock_new(&evas_thread_queue_lock))
CRIT("Could not create draw thread lock");
if (!eina_lock_new(&evas_thread_block_lock))
CRIT("Could not create draw thread block lock");
if (!eina_condition_new(&evas_thread_queue_condition, &evas_thread_queue_lock))
CRIT("Could not create draw thread condition");
if (!eina_thread_create(&evas_thread_worker, EINA_THREAD_NORMAL, 0,
@ -172,7 +154,6 @@ evas_thread_shutdown(void)
evas_async_events_process();
eina_thread_join(evas_thread_worker);
eina_lock_free(&evas_thread_block_lock);
eina_lock_free(&evas_thread_queue_lock);
eina_condition_free(&evas_thread_queue_condition);

View File

@ -1254,9 +1254,7 @@ void evas_thread_init(void);
void evas_thread_shutdown(void);
EAPI void evas_thread_cmd_enqueue(Evas_Thread_Command_Cb cb, void *data);
EAPI void evas_thread_queue_flush(Evas_Thread_Command_Cb cb, void *data);
EAPI void evas_thread_queue_block(void);
EAPI void evas_thread_queue_unblock(void);
typedef enum _Evas_Render_Mode
{
EVAS_RENDER_MODE_UNDEF,