umm... handle rgba dest properly...

SVN revision: 21090
This commit is contained in:
Carsten Haitzler 2006-03-08 08:02:34 +00:00
parent f08d9c94e1
commit f8a6f603f5
3 changed files with 38 additions and 23 deletions

View File

@ -235,17 +235,29 @@ eng_setup(Evas *e, void *in)
if (!e->engine.data.output)
e->engine.data.output =
eng_output_setup(e->output.w,
e->output.h,
info->info.display,
info->info.drawable,
info->info.visual,
info->info.colormap,
info->info.depth);
e->output.h,
info->info.display,
info->info.drawable,
info->info.visual,
info->info.colormap,
info->info.depth);
else
{
re = e->engine.data.output;
eng_window_free(re->win);
re->win = eng_window_new(info->info.display,
info->info.drawable,
0,/* FIXME: screen 0 assumption */
info->info.visual,
info->info.colormap,
info->info.depth,
e->output.w,
e->output.h);
}
if (!e->engine.data.output) return;
if (!e->engine.data.context)
e->engine.data.context =
e->engine.func->context_new(e->engine.data.output);
re = e->engine.data.output;
}
static void *
@ -258,8 +270,8 @@ eng_output_setup(int w, int h, Display *disp, Drawable draw, Visual *vis, Colorm
re = calloc(1, sizeof(Render_Engine));
re->win = eng_window_new(disp, draw,
0 /* FIXME: screen 0 assumption */,
vis, cmap, depth, w, h);
0 /* FIXME: screen 0 assumption */,
vis, cmap, depth, w, h);
if (!re->win)
{
free(re);

View File

@ -25,13 +25,13 @@ Colormap _evas_gl_x11_cmap = 0;
Evas_GL_X11_Window *
eng_window_new(Display *disp,
Window win,
int screen,
Visual *vis,
Colormap cmap,
int depth,
int w,
int h)
Window win,
int screen,
Visual *vis,
Colormap cmap,
int depth,
int w,
int h)
{
Evas_GL_X11_Window *gw;

View File

@ -147,14 +147,17 @@ eng_setup(Evas *e, void *in)
re->xinf = _xr_image_info_get(re->disp, re->win, re->vis);
if (re->output) _xr_render_surface_free(re->output);
re->output = _xr_render_surface_adopt(re->xinf, re->win, e->output.w, e->output.h, 0);
if (re->mask_output) _xr_render_surface_free(re->mask_output);
if (!re->mask)
re->output = _xr_render_surface_adopt(re->xinf, re->win, e->output.w, e->output.h, re->destination_alpha);
else
re->output = _xr_render_surface_adopt(re->xinf, re->win, e->output.w, e->output.h, 0);
if (re->mask)
{
if (re->mask_output) _xr_render_surface_free(re->mask_output);
re->mask_output = _xr_render_surface_format_adopt(re->xinf, re->mask,
e->output.w, e->output.h,
re->xinf->fmt1, 1);
}
re->mask_output = _xr_render_surface_format_adopt(re->xinf, re->mask,
e->output.w, e->output.h,
re->xinf->fmt1, 1);
else
re->mask_output = NULL;
}
static void