evas software x11 - set merge mode explicitly to smart or env var

this allows merge mode for software-x11 to be set too like for gl.

@feature
This commit is contained in:
Carsten Haitzler 2015-10-05 18:36:18 +09:00
parent c603f25139
commit 966b3c8f23
1 changed files with 17 additions and 0 deletions

View File

@ -140,6 +140,8 @@ _output_xlib_setup(int w, int h, int rot, Display *disp, Drawable draw,
{
Render_Engine *re;
Outbuf *ob;
Render_Engine_Merge_Mode merge_mode = MERGE_SMART;
const char *s;
if (!(re = calloc(1, sizeof(Render_Engine)))) return NULL;
@ -178,6 +180,21 @@ _output_xlib_setup(int w, int h, int rot, Display *disp, Drawable draw,
w, h))
goto on_error;
if ((s = getenv("EVAS_SOFTWARE_PARTIAL_MERGE")))
{
if ((!strcmp(s, "bounding")) ||
(!strcmp(s, "b")))
merge_mode = MERGE_BOUNDING;
else if ((!strcmp(s, "full")) ||
(!strcmp(s, "f")))
merge_mode = MERGE_FULL;
else if ((!strcmp(s, "smart")) ||
(!strcmp(s, "s")))
merge_mode = MERGE_SMART;
}
evas_render_engine_software_generic_merge_mode_set(&re->generic, merge_mode);
return re;
on_error: