Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(7)

Side by Side Diff: src/utils/SkDeferredCanvas.cpp

Issue 424663006: SkCanvas interface for drawing a patch. (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: Fixed implicit casting in patch.cpp Created 6 years, 4 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « src/core/SkPatch.cpp ('k') | src/utils/SkPatchUtils.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 1
2 /* 2 /*
3 * Copyright 2013 Google Inc. 3 * Copyright 2013 Google Inc.
4 * 4 *
5 * Use of this source code is governed by a BSD-style license that can be 5 * Use of this source code is governed by a BSD-style license that can be
6 * found in the LICENSE file. 6 * found in the LICENSE file.
7 */ 7 */
8 8
9 #include "SkDeferredCanvas.h" 9 #include "SkDeferredCanvas.h"
10 10
(...skipping 206 matching lines...) Expand 10 before | Expand all | Expand 10 after
217 size_t len, const SkPath& path, 217 size_t len, const SkPath& path,
218 const SkMatrix* matrix, 218 const SkMatrix* matrix,
219 const SkPaint& paint) SK_OVERRIDE 219 const SkPaint& paint) SK_OVERRIDE
220 {SkASSERT(0);} 220 {SkASSERT(0);}
221 virtual void drawVertices(const SkDraw&, SkCanvas::VertexMode, 221 virtual void drawVertices(const SkDraw&, SkCanvas::VertexMode,
222 int vertexCount, const SkPoint verts[], 222 int vertexCount, const SkPoint verts[],
223 const SkPoint texs[], const SkColor colors[], 223 const SkPoint texs[], const SkColor colors[],
224 SkXfermode* xmode, const uint16_t indices[], 224 SkXfermode* xmode, const uint16_t indices[],
225 int indexCount, const SkPaint& paint) SK_OVERRID E 225 int indexCount, const SkPaint& paint) SK_OVERRID E
226 {SkASSERT(0);} 226 {SkASSERT(0);}
227 virtual void drawPatch(const SkDraw&, const SkPatch& patch, const SkPaint& p aint) SK_OVERRIDE
228 {SkASSERT(0);}
227 virtual void drawDevice(const SkDraw&, SkBaseDevice*, int x, int y, 229 virtual void drawDevice(const SkDraw&, SkBaseDevice*, int x, int y,
228 const SkPaint&) SK_OVERRIDE 230 const SkPaint&) SK_OVERRIDE
229 {SkASSERT(0);} 231 {SkASSERT(0);}
230 232
231 virtual void lockPixels() SK_OVERRIDE {} 233 virtual void lockPixels() SK_OVERRIDE {}
232 virtual void unlockPixels() SK_OVERRIDE {} 234 virtual void unlockPixels() SK_OVERRIDE {}
233 235
234 virtual bool allowImageFilter(const SkImageFilter*) SK_OVERRIDE { 236 virtual bool allowImageFilter(const SkImageFilter*) SK_OVERRIDE {
235 return false; 237 return false;
236 } 238 }
(...skipping 670 matching lines...) Expand 10 before | Expand all | Expand 10 after
907 const SkPoint texs[], 909 const SkPoint texs[],
908 const SkColor colors[], SkXfermode* xmode, 910 const SkColor colors[], SkXfermode* xmode,
909 const uint16_t indices[], int indexCount, 911 const uint16_t indices[], int indexCount,
910 const SkPaint& paint) { 912 const SkPaint& paint) {
911 AutoImmediateDrawIfNeeded autoDraw(*this, &paint); 913 AutoImmediateDrawIfNeeded autoDraw(*this, &paint);
912 this->drawingCanvas()->drawVertices(vmode, vertexCount, vertices, texs, colo rs, xmode, 914 this->drawingCanvas()->drawVertices(vmode, vertexCount, vertices, texs, colo rs, xmode,
913 indices, indexCount, paint); 915 indices, indexCount, paint);
914 this->recordedDrawCommand(); 916 this->recordedDrawCommand();
915 } 917 }
916 918
919 void SkDeferredCanvas::drawPatch(const SkPatch& patch, const SkPaint& paint) {
920 //TODO
921 }
922
917 SkDrawFilter* SkDeferredCanvas::setDrawFilter(SkDrawFilter* filter) { 923 SkDrawFilter* SkDeferredCanvas::setDrawFilter(SkDrawFilter* filter) {
918 this->drawingCanvas()->setDrawFilter(filter); 924 this->drawingCanvas()->setDrawFilter(filter);
919 this->INHERITED::setDrawFilter(filter); 925 this->INHERITED::setDrawFilter(filter);
920 this->recordedDrawCommand(); 926 this->recordedDrawCommand();
921 return filter; 927 return filter;
922 } 928 }
923 929
924 SkCanvas* SkDeferredCanvas::canvasForDrawIter() { 930 SkCanvas* SkDeferredCanvas::canvasForDrawIter() {
925 return this->drawingCanvas(); 931 return this->drawingCanvas();
926 } 932 }
OLDNEW
« no previous file with comments | « src/core/SkPatch.cpp ('k') | src/utils/SkPatchUtils.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698