OLD | NEW |
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 899 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
910 const SkColor colors[], SkXfermode* xmode, | 910 const SkColor colors[], SkXfermode* xmode, |
911 const uint16_t indices[], int indexCount, | 911 const uint16_t indices[], int indexCount, |
912 const SkPaint& paint) { | 912 const SkPaint& paint) { |
913 AutoImmediateDrawIfNeeded autoDraw(*this, &paint); | 913 AutoImmediateDrawIfNeeded autoDraw(*this, &paint); |
914 this->drawingCanvas()->drawVertices(vmode, vertexCount, vertices, texs, colo
rs, xmode, | 914 this->drawingCanvas()->drawVertices(vmode, vertexCount, vertices, texs, colo
rs, xmode, |
915 indices, indexCount, paint); | 915 indices, indexCount, paint); |
916 this->recordedDrawCommand(); | 916 this->recordedDrawCommand(); |
917 } | 917 } |
918 | 918 |
919 void SkDeferredCanvas::drawPatch(const SkPatch& patch, const SkPaint& paint) { | 919 void SkDeferredCanvas::drawPatch(const SkPatch& patch, const SkPaint& paint) { |
920 //TODO | 920 AutoImmediateDrawIfNeeded autoDraw(*this, &paint); |
| 921 this->drawingCanvas()->drawPatch(patch, paint); |
| 922 this->recordedDrawCommand(); |
921 } | 923 } |
922 | 924 |
923 SkDrawFilter* SkDeferredCanvas::setDrawFilter(SkDrawFilter* filter) { | 925 SkDrawFilter* SkDeferredCanvas::setDrawFilter(SkDrawFilter* filter) { |
924 this->drawingCanvas()->setDrawFilter(filter); | 926 this->drawingCanvas()->setDrawFilter(filter); |
925 this->INHERITED::setDrawFilter(filter); | 927 this->INHERITED::setDrawFilter(filter); |
926 this->recordedDrawCommand(); | 928 this->recordedDrawCommand(); |
927 return filter; | 929 return filter; |
928 } | 930 } |
929 | 931 |
930 SkCanvas* SkDeferredCanvas::canvasForDrawIter() { | 932 SkCanvas* SkDeferredCanvas::canvasForDrawIter() { |
931 return this->drawingCanvas(); | 933 return this->drawingCanvas(); |
932 } | 934 } |
OLD | NEW |