Apply translate param to path bounds when computing ssaa bounds

Review URL: http://codereview.appspot.com/4591044/



git-svn-id: http://skia.googlecode.com/svn/trunk@1532 2bbb7eff-a529-9590-31e7-b0007b416f81
This commit is contained in:
bsalomon@google.com 2011-06-07 18:46:50 +00:00
parent 4c0e88e202
commit 7ca72f3355

View File

@ -1192,6 +1192,9 @@ void GrContext::drawPath(const GrPaint& paint, const GrPath& path,
GrRect pathBounds = path.getBounds();
GrIRect pathIBounds;
if (!pathBounds.isEmpty()) {
if (NULL != translate) {
pathBounds.offset(*translate);
}
target->getViewMatrix().mapRect(&pathBounds, pathBounds);
pathBounds.roundOut(&pathIBounds);
if (!bound.intersect(pathIBounds)) {