[cairo] fix for untransformed and transformed paths of extend_pad
Soeren Sandmann
sandmann at daimi.au.dk
Tue Mar 4 15:47:06 PST 2008
Antoine Azar <cairo at antoineazar.com> writes:
> here's a patch I discussed with Soeren that fixes some issues with
> extend_pad inside pixman. We're basically always going the transformed
> way even without a transformation to take advantage of the special
> code there to handle the padding. Additionally we make sure we don't
> take a fast path as this would not work. I've also fixed a typo to
> correctly disable maskRepeat if the mask had a transform.
Looks good to me, except that this bit:
@@ -3168,7 +3168,8 @@ PIXMAN_COMPOSITE_RECT_GENERAL (const FbComposeData *data,
fetchSrc = (scanFetchProc)fbFetchSolid;
srcClass = SOURCE_IMAGE_CLASS_HORIZONTAL;
}
- else if (!bits->common.transform && bits->common.filter != PIXMAN_FILTER_CONVOLUTION)
+ else if (!bits->common.transform && bits->common.filter != PIXMAN_FILTER_CONVOLUTION
+ && bits->common.repeat != PIXMAN_REPEAT_PAD)
{
fetchSrc = (scanFetchProc)fbFetch;
}
needs to be done for masks as well (in the next block of code).
Similarly, here:
@@ -1772,6 +1730,7 @@ pixman_image_composite (pixman_op_t op,
&& !srcTransform && !maskTransform
&& !maskAlphaMap && !srcAlphaMap && !dstAlphaMap
&& (pSrc->common.filter != PIXMAN_FILTER_CONVOLUTION)
+ && (pSrc->common.repeat != PIXMAN_REPEAT_PAD)
&& (!pMask || pMask->common.filter != PIXMAN_FILTER_CONVOLUTION)
&& !pSrc->common.read_func && !pSrc->common.write_func
&& !(pMask && pMask->common.read_func) && !(pMask && pMask->common.write_func)
we need a check that mask is not REPEAT_PAD as well.
Finally, this comment:
/* when using convolution filters one might get here without a transform */
in fbFetchTransformed() needs to be updated.
Other than those things, looks good to push.
Thanks,
Soren
More information about the cairo
mailing list