[UTC][Player][Non-ACR][call elm api to use gl]
authorEunhae Choi <eunhae1.choi@samsung.com>
Fri, 28 Sep 2018 05:03:00 +0000 (14:03 +0900)
committerEunhae Choi <eunhae1.choi@samsung.com>
Fri, 28 Sep 2018 05:03:00 +0000 (14:03 +0900)
Change-Id: I665d0f37c40f59401bc7afd45e6dcf2ed8c7bbc2

src/utc/player/utc-media-player-display.c

index a6791fd91c8d80f496619ee15d73fee4fc965972..077b67a5820e7f33c53f78c56fe5e8b5e380d9a2 100644 (file)
@@ -91,40 +91,41 @@ static void destroy_window()
 
 void create_evas_window()
 {
-    destroy_window();  /* destroy window in case the clean_up is not called */
-
-    Evas *evas = NULL;
-    int w = 0;
-    int h = 0;
-
-    /* create window */
-    g_win = elm_win_util_standard_add("player_tc", "player_tc");
-    if (g_win)
-    {
-        elm_win_borderless_set(g_win, EINA_TRUE);
-        evas_object_smart_callback_add(g_win, "delete, request", win_del, NULL);
-        elm_win_screen_size_get(g_win, NULL, NULL, &w, &h);
-        evas_object_resize(g_win, w, h);
-        elm_win_autodel_set(g_win, EINA_TRUE);
-    } else {
-        PRINT_UTC_LOG("[Line : %d][%s] fail to create window\\n", __LINE__, API_NAMESPACE);
-    }
+       destroy_window();       /* destroy window in case the clean_up is not called */
+
+       Evas *evas = NULL;
+       int w = 0;
+       int h = 0;
+
+       /* use gl backend */
+       elm_config_accel_preference_set("3d");
+
+       /* create window */
+       g_win = elm_win_util_standard_add("player_tc", "player_tc");
+       if (g_win) {
+               elm_win_borderless_set(g_win, EINA_TRUE);
+               evas_object_smart_callback_add(g_win, "delete, request", win_del, NULL);
+               elm_win_screen_size_get(g_win, NULL, NULL, &w, &h);
+               evas_object_resize(g_win, w, h);
+               elm_win_autodel_set(g_win, EINA_TRUE);
+       } else {
+               PRINT_UTC_LOG("[Line : %d][%s] fail to create window\\n", __LINE__, API_NAMESPACE);
+       }
 
-    evas = evas_object_evas_get(g_win);
-    if (!evas)
-    {
-        FPRINTF("[Line: %d][%s] fail to get evas", __LINE__, API_NAMESPACE);
-        return;
-    }
+       evas = evas_object_evas_get(g_win);
+       if (!evas) {
+               FPRINTF("[Line: %d][%s] fail to get evas", __LINE__, API_NAMESPACE);
+               return;
+       }
 
-    g_eo = evas_object_image_add(evas);
+       g_eo = evas_object_image_add(evas);
 
-    evas_object_image_size_set(g_eo, 500, 500);
-    evas_object_image_fill_set(g_eo, 0, 0, 500, 500);
-    evas_object_resize(g_eo, 500, 500);
+       evas_object_image_size_set(g_eo, 500, 500);
+       evas_object_image_fill_set(g_eo, 0, 0, 500, 500);
+       evas_object_resize(g_eo, 500, 500);
 
-    elm_win_activate(g_win);
-    evas_object_show(g_win);
+       elm_win_activate(g_win);
+       evas_object_show(g_win);
 }
 
 static void create_window()