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

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

Issue 1272713005: flag to use const& instead of const* for src-rect (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: Created 5 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
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 "SkLayerInfo.h" 8 #include "SkLayerInfo.h"
9 #include "SkRecordDraw.h" 9 #include "SkRecordDraw.h"
10 #include "SkPatchUtils.h" 10 #include "SkPatchUtils.h"
(...skipping 71 matching lines...) Expand 10 before | Expand all | Expand 10 after
82 DRAW(SetMatrix, setMatrix(SkMatrix::Concat(fInitialCTM, r.matrix))); 82 DRAW(SetMatrix, setMatrix(SkMatrix::Concat(fInitialCTM, r.matrix)));
83 83
84 DRAW(ClipPath, clipPath(r.path, r.opAA.op, r.opAA.aa)); 84 DRAW(ClipPath, clipPath(r.path, r.opAA.op, r.opAA.aa));
85 DRAW(ClipRRect, clipRRect(r.rrect, r.opAA.op, r.opAA.aa)); 85 DRAW(ClipRRect, clipRRect(r.rrect, r.opAA.op, r.opAA.aa));
86 DRAW(ClipRect, clipRect(r.rect, r.opAA.op, r.opAA.aa)); 86 DRAW(ClipRect, clipRect(r.rect, r.opAA.op, r.opAA.aa));
87 DRAW(ClipRegion, clipRegion(r.region, r.op)); 87 DRAW(ClipRegion, clipRegion(r.region, r.op));
88 88
89 DRAW(DrawBitmap, drawBitmap(r.bitmap.shallowCopy(), r.left, r.top, r.paint)); 89 DRAW(DrawBitmap, drawBitmap(r.bitmap.shallowCopy(), r.left, r.top, r.paint));
90 DRAW(DrawBitmapNine, drawBitmapNine(r.bitmap.shallowCopy(), r.center, r.dst, r.p aint)); 90 DRAW(DrawBitmapNine, drawBitmapNine(r.bitmap.shallowCopy(), r.center, r.dst, r.p aint));
91 DRAW(DrawBitmapRect, 91 DRAW(DrawBitmapRect,
92 drawBitmapRect(r.bitmap.shallowCopy(), r.src, r.dst, r.paint, 92 legacy_drawBitmapRect(r.bitmap.shallowCopy(), r.src, r.dst, r.paint,
93 SkCanvas::kStrict_SrcRectConstraint)); 93 SkCanvas::kStrict_SrcRectConstraint));
94 DRAW(DrawBitmapRectFast, 94 DRAW(DrawBitmapRectFast,
95 drawBitmapRect(r.bitmap.shallowCopy(), r.src, r.dst, r.paint, 95 legacy_drawBitmapRect(r.bitmap.shallowCopy(), r.src, r.dst, r.paint,
96 SkCanvas::kFast_SrcRectConstraint)); 96 SkCanvas::kFast_SrcRectConstraint));
97 DRAW(DrawBitmapRectFixedSize, 97 DRAW(DrawBitmapRectFixedSize,
98 drawBitmapRect(r.bitmap.shallowCopy(), &r.src, r.dst, &r.paint, r.constr aint)); 98 legacy_drawBitmapRect(r.bitmap.shallowCopy(), &r.src, r.dst, &r.paint, r .constraint));
99 DRAW(DrawDRRect, drawDRRect(r.outer, r.inner, r.paint)); 99 DRAW(DrawDRRect, drawDRRect(r.outer, r.inner, r.paint));
100 DRAW(DrawImage, drawImage(r.image, r.left, r.top, r.paint)); 100 DRAW(DrawImage, drawImage(r.image, r.left, r.top, r.paint));
101 DRAW(DrawImageRect, drawImageRect(r.image, r.src, r.dst, r.paint, r.constraint)) ; 101 DRAW(DrawImageRect, legacy_drawImageRect(r.image, r.src, r.dst, r.paint, r.const raint));
102 DRAW(DrawImageNine, drawImageNine(r.image, r.center, r.dst, r.paint)); 102 DRAW(DrawImageNine, drawImageNine(r.image, r.center, r.dst, r.paint));
103 DRAW(DrawOval, drawOval(r.oval, r.paint)); 103 DRAW(DrawOval, drawOval(r.oval, r.paint));
104 DRAW(DrawPaint, drawPaint(r.paint)); 104 DRAW(DrawPaint, drawPaint(r.paint));
105 DRAW(DrawPath, drawPath(r.path, r.paint)); 105 DRAW(DrawPath, drawPath(r.path, r.paint));
106 DRAW(DrawPatch, drawPatch(r.cubics, r.colors, r.texCoords, r.xmode, r.paint)); 106 DRAW(DrawPatch, drawPatch(r.cubics, r.colors, r.texCoords, r.xmode, r.paint));
107 DRAW(DrawPicture, drawPicture(r.picture, &r.matrix, r.paint)); 107 DRAW(DrawPicture, drawPicture(r.picture, &r.matrix, r.paint));
108 DRAW(DrawPoints, drawPoints(r.mode, r.count, r.pts, r.paint)); 108 DRAW(DrawPoints, drawPoints(r.mode, r.count, r.pts, r.paint));
109 DRAW(DrawPosText, drawPosText(r.text, r.byteLength, r.pos, r.paint)); 109 DRAW(DrawPosText, drawPosText(r.text, r.byteLength, r.pos, r.paint));
110 DRAW(DrawPosTextH, drawPosTextH(r.text, r.byteLength, r.xpos, r.y, r.paint)); 110 DRAW(DrawPosTextH, drawPosTextH(r.text, r.byteLength, r.xpos, r.y, r.paint));
111 DRAW(DrawRRect, drawRRect(r.rrect, r.paint)); 111 DRAW(DrawRRect, drawRRect(r.rrect, r.paint));
(...skipping 697 matching lines...) Expand 10 before | Expand all | Expand 10 after
809 SkRecords::CollectLayers visitor(cullRect, record, pictList, data); 809 SkRecords::CollectLayers visitor(cullRect, record, pictList, data);
810 810
811 for (unsigned curOp = 0; curOp < record.count(); curOp++) { 811 for (unsigned curOp = 0; curOp < record.count(); curOp++) {
812 visitor.setCurrentOp(curOp); 812 visitor.setCurrentOp(curOp);
813 record.visit<void>(curOp, visitor); 813 record.visit<void>(curOp, visitor);
814 } 814 }
815 815
816 visitor.cleanUp(bbh); 816 visitor.cleanUp(bbh);
817 } 817 }
818 818
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698