Index: src/pdf/SkPDFDevice.cpp |
=================================================================== |
--- src/pdf/SkPDFDevice.cpp (revision 11417) |
+++ src/pdf/SkPDFDevice.cpp (working copy) |
@@ -959,16 +959,16 @@ |
} |
#ifdef SK_PDF_USE_PATHOPS |
- if (handleInversePath(d, origPath, paint, pathIsMutable)) { |
+ if (handleInversePath(d, origPath, paint, pathIsMutable, &matrix)) { |
return; |
} |
#endif |
- if (handleRectAnnotation(pathPtr->getBounds(), *d.fMatrix, paint)) { |
+ if (handleRectAnnotation(pathPtr->getBounds(), matrix, paint)) { |
return; |
} |
- ScopedContentEntry content(this, d, paint); |
+ ScopedContentEntry content(this, d.fClipStack, *d.fClip, matrix, paint); |
if (!content.entry()) { |
return; |
} |
@@ -1365,7 +1365,8 @@ |
* in the first place. |
*/ |
bool SkPDFDevice::handleInversePath(const SkDraw& d, const SkPath& origPath, |
- const SkPaint& paint, bool pathIsMutable) { |
+ const SkPaint& paint, bool pathIsMutable, |
+ const SkMatrix* matrix) { |
if (!origPath.isInverseFillType()) { |
return false; |
} |
@@ -1399,7 +1400,8 @@ |
// (clip bounds are given in device space). |
SkRect bounds; |
SkMatrix transformInverse; |
- if (!d.fMatrix->invert(&transformInverse)) { |
+ const SkMatrix matrixToUse = matrix ? *matrix : *d.fMatrix; |
+ if (!matrixToUse.invert(&transformInverse)) { |
return false; |
} |
bounds.set(d.fClip->getBounds()); |
@@ -1414,7 +1416,7 @@ |
return false; |
} |
- drawPath(d, modifiedPath, noInversePaint, NULL, true); |
+ drawPath(d, modifiedPath, noInversePaint, matrix, true); |
vandebo (ex-Chrome)
2013/09/20 18:57:56
This isn't the prePathMatrix, this is the total ma
|
return true; |
} |
#endif |