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

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

Issue 1168303006: Revert[2] SkDraw and all Blitters to use pixmap instead of bitmapi (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: add dox to new test Created 5 years, 6 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/SkBlitter_RGB16.cpp ('k') | src/core/SkCoreBlitters.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 * 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 #include "SkCanvas.h" 8 #include "SkCanvas.h"
9 #include "SkCanvasPriv.h" 9 #include "SkCanvasPriv.h"
10 #include "SkBitmapDevice.h" 10 #include "SkBitmapDevice.h"
(...skipping 252 matching lines...) Expand 10 before | Expand all | Expand 10 after
263 } 263 }
264 } 264 }
265 265
266 const DeviceCM* rec = fCurrLayer; 266 const DeviceCM* rec = fCurrLayer;
267 if (rec && rec->fDevice) { 267 if (rec && rec->fDevice) {
268 268
269 fMatrix = rec->fMatrix; 269 fMatrix = rec->fMatrix;
270 fClip = &((SkRasterClip*)&rec->fClip)->forceGetBW(); 270 fClip = &((SkRasterClip*)&rec->fClip)->forceGetBW();
271 fRC = &rec->fClip; 271 fRC = &rec->fClip;
272 fDevice = rec->fDevice; 272 fDevice = rec->fDevice;
273 fBitmap = &fDevice->accessBitmap(true); 273 if (!fDevice->accessPixels(&fDst)) {
274 fDst.reset(fDevice->imageInfo(), NULL, 0);
275 }
274 fPaint = rec->fPaint; 276 fPaint = rec->fPaint;
275 SkDEBUGCODE(this->validate();) 277 SkDEBUGCODE(this->validate();)
276 278
277 fCurrLayer = rec->fNext; 279 fCurrLayer = rec->fNext;
278 // fCurrLayer may be NULL now 280 // fCurrLayer may be NULL now
279 281
280 return true; 282 return true;
281 } 283 }
282 return false; 284 return false;
283 } 285 }
(...skipping 2426 matching lines...) Expand 10 before | Expand all | Expand 10 after
2710 } 2712 }
2711 2713
2712 if (matrix) { 2714 if (matrix) {
2713 canvas->concat(*matrix); 2715 canvas->concat(*matrix);
2714 } 2716 }
2715 } 2717 }
2716 2718
2717 SkAutoCanvasMatrixPaint::~SkAutoCanvasMatrixPaint() { 2719 SkAutoCanvasMatrixPaint::~SkAutoCanvasMatrixPaint() {
2718 fCanvas->restoreToCount(fSaveCount); 2720 fCanvas->restoreToCount(fSaveCount);
2719 } 2721 }
OLDNEW
« no previous file with comments | « src/core/SkBlitter_RGB16.cpp ('k') | src/core/SkCoreBlitters.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698