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

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

Issue 1744103002: move annotations to canvas virtual (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: Created 4 years, 9 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/SkRecorder.h ('k') | src/core/SkRemote.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 2014 Google Inc. 2 * Copyright 2014 Google Inc.
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 "SkBigPicture.h" 8 #include "SkBigPicture.h"
9 #include "SkCanvasPriv.h" 9 #include "SkCanvasPriv.h"
10 #include "SkPatchUtils.h" 10 #include "SkPatchUtils.h"
(...skipping 314 matching lines...) Expand 10 before | Expand all | Expand 10 after
325 APPEND(DrawAtlas, this->copy(paint), 325 APPEND(DrawAtlas, this->copy(paint),
326 atlas, 326 atlas,
327 this->copy(xform, count), 327 this->copy(xform, count),
328 this->copy(tex, count), 328 this->copy(tex, count),
329 this->copy(colors, count), 329 this->copy(colors, count),
330 count, 330 count,
331 mode, 331 mode,
332 this->copy(cull)); 332 this->copy(cull));
333 } 333 }
334 334
335 void SkRecorder::onDrawAnnotation(const SkRect& rect, const char key[], SkData* value) {
336 APPEND(DrawAnnotation, rect, SkString(key), value);
337 }
338
335 void SkRecorder::willSave() { 339 void SkRecorder::willSave() {
336 APPEND(Save); 340 APPEND(Save);
337 } 341 }
338 342
339 SkCanvas::SaveLayerStrategy SkRecorder::getSaveLayerStrategy(const SaveLayerRec& rec) { 343 SkCanvas::SaveLayerStrategy SkRecorder::getSaveLayerStrategy(const SaveLayerRec& rec) {
340 APPEND(SaveLayer, 344 APPEND(SaveLayer,
341 this->copy(rec.fBounds), this->copy(rec.fPaint), rec.fBackdrop, rec.f SaveLayerFlags); 345 this->copy(rec.fBounds), this->copy(rec.fPaint), rec.fBackdrop, rec.f SaveLayerFlags);
342 return SkCanvas::kNoLayer_SaveLayerStrategy; 346 return SkCanvas::kNoLayer_SaveLayerStrategy;
343 } 347 }
344 348
(...skipping 25 matching lines...) Expand all
370 INHERITED(onClipPath, path, op, edgeStyle); 374 INHERITED(onClipPath, path, op, edgeStyle);
371 SkRecords::RegionOpAndAA opAA(op, kSoft_ClipEdgeStyle == edgeStyle); 375 SkRecords::RegionOpAndAA opAA(op, kSoft_ClipEdgeStyle == edgeStyle);
372 APPEND(ClipPath, this->devBounds(), path, opAA); 376 APPEND(ClipPath, this->devBounds(), path, opAA);
373 } 377 }
374 378
375 void SkRecorder::onClipRegion(const SkRegion& deviceRgn, SkRegion::Op op) { 379 void SkRecorder::onClipRegion(const SkRegion& deviceRgn, SkRegion::Op op) {
376 INHERITED(onClipRegion, deviceRgn, op); 380 INHERITED(onClipRegion, deviceRgn, op);
377 APPEND(ClipRegion, this->devBounds(), deviceRgn, op); 381 APPEND(ClipRegion, this->devBounds(), deviceRgn, op);
378 } 382 }
379 383
OLDNEW
« no previous file with comments | « src/core/SkRecorder.h ('k') | src/core/SkRemote.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698