Eina_Bool window_manager_video = EINA_FALSE;
int _emotion_gstreamer_log_domain = -1;
Eina_Bool debug_fps = EINA_FALSE;
+Eina_Bool _ecore_x_available = EINA_FALSE;
/* Callbacks to get the eos */
static void _for_each_tag (GstTagList const* list, gchar const* tag, void *data);
eina_threads_init();
#ifdef HAVE_ECORE_X
+ if (ecore_x_init(NULL) > 0)
+ {
+ _ecore_x_available = EINA_TRUE;
+ }
+
/* Check if the window manager is able to handle our special Xv window. */
- roots = ecore_x_window_root_list(&num);
+ roots = _ecore_x_available ? ecore_x_window_root_list(&num) : NULL;
if (roots && num > 0)
{
Ecore_X_Window win, twin;
{
em_module.shutdown(video);
+#ifdef HAVE_ECORE_X
+ if (_ecore_x_available)
+ {
+ ecore_x_shutdown();
+ }
+#endif
+
eina_threads_shutdown();
}
extern Eina_Bool window_manager_video;
extern Eina_Bool debug_fps;
extern int _emotion_gstreamer_log_domain;
+extern Eina_Bool _ecore_x_available;
#define DBG(...) EINA_LOG_DOM_DBG(_emotion_gstreamer_log_domain, __VA_ARGS__)
#define INF(...) EINA_LOG_DOM_INFO(_emotion_gstreamer_log_domain, __VA_ARGS__)
#define WRN(...) EINA_LOG_DOM_WARN(_emotion_gstreamer_log_domain, __VA_ARGS__)