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

Side by Side Diff: src/core/SkCanvas.cpp

Issue 540963002: Change SkPicture::draw to playback (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: Created 6 years, 3 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
OLDNEW
1 /* 1 /*
2 * Copyright 2008 The Android Open Source Project 2 * Copyright 2008 The Android Open Source Project
3 * 3 *
4 * Use of this source code is governed by a BSD-style license that can be 4 * Use of this source code is governed by a BSD-style license that can be
5 * found in the LICENSE file. 5 * found in the LICENSE file.
6 */ 6 */
7 7
8 8
9 #include "SkCanvas.h" 9 #include "SkCanvas.h"
10 #include "SkCanvasPriv.h" 10 #include "SkCanvasPriv.h"
(...skipping 2437 matching lines...) Expand 10 before | Expand all | Expand 10 after
2448 if (NULL != device) { 2448 if (NULL != device) {
2449 // Canvas has to first give the device the opportunity to render 2449 // Canvas has to first give the device the opportunity to render
2450 // the picture itself. 2450 // the picture itself.
2451 if (device->EXPERIMENTAL_drawPicture(this, picture, matrix, paint)) { 2451 if (device->EXPERIMENTAL_drawPicture(this, picture, matrix, paint)) {
2452 return; // the device has rendered the entire picture 2452 return; // the device has rendered the entire picture
2453 } 2453 }
2454 } 2454 }
2455 2455
2456 SkAutoCanvasMatrixPaint acmp(this, matrix, paint, picture->cullRect()); 2456 SkAutoCanvasMatrixPaint acmp(this, matrix, paint, picture->cullRect());
2457 2457
2458 picture->draw(this); 2458 picture->playback(this);
2459 } 2459 }
2460 2460
2461 /////////////////////////////////////////////////////////////////////////////// 2461 ///////////////////////////////////////////////////////////////////////////////
2462 /////////////////////////////////////////////////////////////////////////////// 2462 ///////////////////////////////////////////////////////////////////////////////
2463 2463
2464 SkCanvas::LayerIter::LayerIter(SkCanvas* canvas, bool skipEmptyClips) { 2464 SkCanvas::LayerIter::LayerIter(SkCanvas* canvas, bool skipEmptyClips) {
2465 SK_COMPILE_ASSERT(sizeof(fStorage) >= sizeof(SkDrawIter), fStorage_too_small ); 2465 SK_COMPILE_ASSERT(sizeof(fStorage) >= sizeof(SkDrawIter), fStorage_too_small );
2466 2466
2467 SkASSERT(canvas); 2467 SkASSERT(canvas);
2468 2468
(...skipping 103 matching lines...) Expand 10 before | Expand all | Expand 10 after
2572 } 2572 }
2573 2573
2574 if (NULL != matrix) { 2574 if (NULL != matrix) {
2575 canvas->concat(*matrix); 2575 canvas->concat(*matrix);
2576 } 2576 }
2577 } 2577 }
2578 2578
2579 SkAutoCanvasMatrixPaint::~SkAutoCanvasMatrixPaint() { 2579 SkAutoCanvasMatrixPaint::~SkAutoCanvasMatrixPaint() {
2580 fCanvas->restoreToCount(fSaveCount); 2580 fCanvas->restoreToCount(fSaveCount);
2581 } 2581 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698