Enlightenment CVS committal Author : tilman Project : e17 Module : libs/evas
Dir : e17/libs/evas/src/modules/engines/xrender_x11 Modified Files: evas_engine_xrender.c Log Message: xrender's filters also kick in if we don't specify a transformation matrix (that's _not_ a bug), so only specify a filter if we're scaling the image =================================================================== RCS file: /cvs/e/e17/libs/evas/src/modules/engines/xrender_x11/evas_engine_xrender.c,v retrieving revision 1.21 retrieving revision 1.22 diff -u -3 -r1.21 -r1.22 --- evas_engine_xrender.c 13 Sep 2006 10:28:22 -0000 1.21 +++ evas_engine_xrender.c 16 Sep 2006 14:59:28 -0000 1.22 @@ -369,13 +369,12 @@ XRenderPictureAttributes att; Picture mask; int r, g, b, a, op; - int e; + int e, is_scaling; if ((sw <= 0) || (sh <= 0) || (w <= 0) || (h <= 0)) return; - e = 0; - if ((sw != w) || (sh != h)) - e = 1; + is_scaling = (sw != w) || (sh != h); + e = is_scaling ? 0 : 1; att.clip_mask = None; XRenderChangePicture(srs->xinf->disp, srs->pic, CPClipMask, &att); @@ -446,7 +445,9 @@ _xr_render_surface_clips_set(drs, dc, x, y, w, h); if (trs) { - XRenderSetPictureFilter(trs->xinf->disp, trs->pic, get_filter(smooth), NULL, 0); + if (is_scaling) + XRenderSetPictureFilter(trs->xinf->disp, trs->pic, get_filter(smooth), NULL, 0); + XRenderSetPictureTransform(trs->xinf->disp, trs->pic, &xf); XRenderComposite(trs->xinf->disp, op, trs->pic, mask, drs->pic, @@ -455,7 +456,7 @@ } else { - if (srs->bordered && e) + if (srs->bordered && is_scaling) { trs = _xr_render_surface_new(srs->xinf, sw + 1, sh + 1, srs->fmt, srs->alpha); @@ -479,7 +480,8 @@ } else { - XRenderSetPictureFilter(srs->xinf->disp, srs->pic, get_filter(smooth), NULL, 0); + if (is_scaling) + XRenderSetPictureFilter(srs->xinf->disp, srs->pic, get_filter(smooth), NULL, 0); XRenderSetPictureTransform(srs->xinf->disp, srs->pic, &xf); XRenderComposite(srs->xinf->disp, op, srs->pic, mask, drs->pic, @@ -513,7 +515,6 @@ att.clip_mask = None; XRenderChangePicture(srs->xinf->disp, srs->pic, CPClipMask, &att); XRenderChangePicture(srs->xinf->disp, drs->pic, CPClipMask, &att); - XRenderSetPictureFilter(srs->xinf->disp, srs->pic, FilterNearest, NULL, 0); XRenderComposite(srs->xinf->disp, PictOpSrc, srs->pic, None, drs->pic, sx, sy, 0, 0, x, y, w, h); ------------------------------------------------------------------------- Using Tomcat but need to do more? Need to support web services, security? Get stuff done quickly with pre-integrated technology to make your job easier Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642 _______________________________________________ enlightenment-cvs mailing list enlightenment-cvs@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/enlightenment-cvs