Index: src/utils/SkDeferredCanvas.cpp |
diff --git a/src/utils/SkDeferredCanvas.cpp b/src/utils/SkDeferredCanvas.cpp |
index 5b6a06863a0faa1df1f697b7374c1f0f5b6f8b28..ccf0b012b12d29323df2e621800872b37cdaa669 100644 |
--- a/src/utils/SkDeferredCanvas.cpp |
+++ b/src/utils/SkDeferredCanvas.cpp |
@@ -251,6 +251,10 @@ protected: |
const SkPoint texCoords[4], SkXfermode* xmode, |
const SkPaint& paint) override |
{SkASSERT(0);} |
+ void drawAtlas(const SkDraw&, const SkImage* atlas, const SkRSXform[], const SkRect[], |
+ const SkColor[], int count, SkXfermode::Mode, const SkPaint&) override |
+ {SkASSERT(0);} |
+ |
void drawDevice(const SkDraw&, SkBaseDevice*, int x, int y, |
const SkPaint&) override |
{SkASSERT(0);} |
@@ -356,8 +360,7 @@ bool SkDeferredDevice::hasPendingCommands() { |
return fPipeController.hasPendingCommands(); |
} |
-void SkDeferredDevice::aboutToDraw() |
-{ |
+void SkDeferredDevice::aboutToDraw() { |
if (fNotificationClient) { |
fNotificationClient->prepareForDraw(); |
} |
@@ -989,6 +992,15 @@ void SkDeferredCanvas::onDrawPatch(const SkPoint cubics[12], const SkColor color |
this->recordedDrawCommand(); |
} |
+void SkDeferredCanvas::onDrawAtlas(const SkImage* atlas, const SkRSXform xform[], |
+ const SkRect tex[], const SkColor colors[], int count, |
+ SkXfermode::Mode mode, const SkRect* cullRect, |
+ const SkPaint* paint) { |
+ AutoImmediateDrawIfNeeded autoDraw(*this, paint); |
+ this->drawingCanvas()->drawAtlas(atlas, xform, tex, colors, count, mode, cullRect, paint); |
+ this->recordedDrawCommand(); |
+} |
+ |
SkDrawFilter* SkDeferredCanvas::setDrawFilter(SkDrawFilter* filter) { |
this->drawingCanvas()->setDrawFilter(filter); |
this->INHERITED::setDrawFilter(filter); |