diff options
author | Nicolas Aguirre <aguirre.nicolas@gmail.com> | 2015-11-03 00:13:20 +0100 |
---|---|---|
committer | Nicolas Aguirre <aguirre.nicolas@gmail.com> | 2015-11-03 00:15:09 +0100 |
commit | 0d6aedbf44e5c371bddfa2b6b61c9409ed2184e3 (patch) | |
tree | 334d2134fd3487cd8e78d2268a71692b6dd4c1fe | |
parent | 3e29939dba0698d7729c85ae4c53f798e44c3239 (diff) | |
download | elementary-0d6aedbf44e5c371bddfa2b6b61c9409ed2184e3.tar.gz |
elm: Add eglfs backend support.
-rw-r--r-- | configure.ac | 1 | ||||
-rw-r--r-- | src/lib/elm_config.c | 3 | ||||
-rw-r--r-- | src/lib/elm_priv.h | 1 | ||||
-rw-r--r-- | src/lib/elm_win.c | 15 | ||||
-rw-r--r-- | src/lib/elm_win.h | 2 |
5 files changed, 18 insertions, 4 deletions
diff --git a/configure.ac b/configure.ac index 9c1a32afe..5eb6739e4 100644 --- a/configure.ac +++ b/configure.ac @@ -543,6 +543,7 @@ echo echo " Engines:" echo " X11....................: ${have_elementary_x}" echo " Framebuffer............: ${have_elementary_fb}" +echo " Eglfs..................: ${have_elementary_eglfs}" echo " DRM....................: ${have_elementary_drm}" echo " PSL1GHT................: ${have_elementary_psl1ght}" echo " SDL....................: ${have_elementary_sdl}" diff --git a/src/lib/elm_config.c b/src/lib/elm_config.c index 29ef12de6..3e552517a 100644 --- a/src/lib/elm_config.c +++ b/src/lib/elm_config.c @@ -34,6 +34,7 @@ Eina_Hash *_elm_key_bindings = NULL; const char *_elm_engines[] = { "software_x11", "fb", + "eglfs", "opengl_x11", "software_gdi", "sdl", @@ -1864,6 +1865,8 @@ _env_get(void) eina_stringshare_replace(&_elm_config->engine, ELM_WAYLAND_EGL); else if ((!strcasecmp(s, "drm"))) eina_stringshare_replace(&_elm_config->engine, ELM_DRM); + else if ((!strcasecmp(s, "eglfs"))) + eina_stringshare_replace(&_elm_config->engine, ELM_EGLFS); else if ((!strcasecmp(s, "ddraw"))) eina_stringshare_replace(&_elm_config->engine, ELM_SOFTWARE_DDRAW); else diff --git a/src/lib/elm_priv.h b/src/lib/elm_priv.h index be92f1513..4b258a61a 100644 --- a/src/lib/elm_priv.h +++ b/src/lib/elm_priv.h @@ -148,6 +148,7 @@ extern const char *_elm_engines[]; #define ELM_WAYLAND_EGL (_elm_engines[11]) #define ELM_DRM (_elm_engines[12]) #define ELM_SOFTWARE_DDRAW (_elm_engines[13]) +#define ELM_EGLFS (_elm_engines[14]) #define ELM_FONT_TOKEN_STYLE ":style=" diff --git a/src/lib/elm_win.c b/src/lib/elm_win.c index f9d3e8428..3a573423a 100644 --- a/src/lib/elm_win.c +++ b/src/lib/elm_win.c @@ -3446,6 +3446,7 @@ _elm_win_finalize_internal(Eo *obj, Elm_Win_Data *sd, const char *name, Elm_Win_ #endif #ifdef HAVE_ELEMENTARY_FB enginelist[p++] = ELM_SOFTWARE_FB; + enginelist[p++] = ELM_EGLFS; #endif } #endif @@ -3506,6 +3507,7 @@ _elm_win_finalize_internal(Eo *obj, Elm_Win_Data *sd, const char *name, Elm_Win_ enginelist[p++] = ELM_DRM; #endif #ifdef HAVE_ELEMENTARY_FB + enginelist[p++] = ELM_EGLFS; enginelist[p++] = ELM_SOFTWARE_FB; #endif #ifdef HAVE_ELEMENTARY_COCOA @@ -3551,6 +3553,7 @@ _elm_win_finalize_internal(Eo *obj, Elm_Win_Data *sd, const char *name, Elm_Win_ enginelist[p++] = ELM_DRM; #endif #ifdef HAVE_ELEMENTARY_FB + enginelist[p++] = ELM_EGLFS; enginelist[p++] = ELM_SOFTWARE_FB; #endif #ifdef HAVE_ELEMENTARY_COCOA @@ -3634,6 +3637,8 @@ _elm_win_finalize_internal(Eo *obj, Elm_Win_Data *sd, const char *name, Elm_Win_ tmp_sd.ee = ecore_evas_ews_new(0, 0, 1, 1); else if (!strcmp(enginelist[i], ELM_SOFTWARE_FB)) tmp_sd.ee = ecore_evas_fb_new(NULL, 0, 1, 1); + else if (!strcmp(enginelist[i], ELM_EGLFS)) + tmp_sd.ee = ecore_evas_eglfs_new(NULL, 0, 1, 1); else if (!strcmp(enginelist[i], ELM_BUFFER)) tmp_sd.ee = ecore_evas_buffer_new(1, 1); else if (!strcmp(enginelist[i], ELM_SOFTWARE_PSL1GHT)) @@ -3810,7 +3815,7 @@ _elm_win_finalize_internal(Eo *obj, Elm_Win_Data *sd, const char *name, Elm_Win_ _elm_win_list = eina_list_append(_elm_win_list, obj); _elm_win_count++; - if ((engine) && ((!strcmp(engine, ELM_SOFTWARE_FB)) || (!strcmp(engine, ELM_DRM)))) + if ((engine) && ((!strcmp(engine, ELM_SOFTWARE_FB)) || (!strcmp(engine, ELM_DRM) || (!strcmp(engine, ELM_EGLFS)))) { TRAP(sd, fullscreen_set, 1); } @@ -3842,7 +3847,7 @@ _elm_win_finalize_internal(Eo *obj, Elm_Win_Data *sd, const char *name, Elm_Win_ if ((_elm_config->softcursor_mode == ELM_SOFTCURSOR_MODE_ON) || ((_elm_config->softcursor_mode == ELM_SOFTCURSOR_MODE_AUTO) && ((engine) && - ((!strcmp(engine, ELM_SOFTWARE_FB)) || (!strcmp(engine, ELM_DRM)))))) + ((!strcmp(engine, ELM_SOFTWARE_FB)) || (!strcmp(engine, ELM_DRM) || (!strcmp(engine, ELM_EGLFS)))))) { Evas_Object *o; Evas_Coord mw = 1, mh = 1, hx = 0, hy = 0; @@ -4267,7 +4272,8 @@ _elm_win_fullscreen_set(Eo *obj EINA_UNUSED, Elm_Win_Data *sd, Eina_Bool fullscr // YYY: handle if sd->img_obj if (engine_name && ((!strcmp(engine_name, ELM_SOFTWARE_FB)) || - (!strcmp(engine_name, ELM_DRM)))) + (!strcmp(engine_name, ELM_DRM)) || + (!strcmp(engine_name, ELM_EGLFS)))) { // these engines... can ONLY be fullscreen return; @@ -4312,7 +4318,8 @@ _elm_win_fullscreen_get(Eo *obj EINA_UNUSED, Elm_Win_Data *sd) if (engine_name && ((!strcmp(engine_name, ELM_SOFTWARE_FB)) || - (!strcmp(engine_name, ELM_DRM)))) + (!strcmp(engine_name, ELM_DRM)) || + (!strcmp(engine_name, ELM_EGLFS)))) { // these engines... can ONLY be fullscreen return EINA_TRUE; diff --git a/src/lib/elm_win.h b/src/lib/elm_win.h index 28f4c09b1..b186f31d4 100644 --- a/src/lib/elm_win.h +++ b/src/lib/elm_win.h @@ -31,6 +31,8 @@ * exits) * @li "fb", "software-fb", "software_fb" (Linux framebuffer direct software * rendering) + * @li "fb", "software-fb", "software_fb" (Linux framebuffer accelerated + * rendering) * @li "sdl", "software-sdl", "software_sdl" (SDL software rendering to SDL * buffer) * @li "gl-sdl", "gl_sdl", "opengl-sdl", "opengl_sdl" (OpenGL or OpenGL-ES2 |