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

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

Issue 532703004: Remove legacy (and also broken) SkPicture constructor. (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
« no previous file with comments | « include/core/SkPicture.h ('k') | no next file » | 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 /* 2 /*
3 * Copyright 2007 The Android Open Source Project 3 * Copyright 2007 The Android Open Source Project
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 9
10 #include "SkPictureFlat.h" 10 #include "SkPictureFlat.h"
(...skipping 234 matching lines...) Expand 10 before | Expand all | Expand 10 after
245 >= kNumAAConcavePathsTol) 245 >= kNumAAConcavePathsTol)
246 *reason = "Too many anti-aliased concave paths."; 246 *reason = "Too many anti-aliased concave paths.";
247 else 247 else
248 *reason = "Unknown reason for GPU unsuitability."; 248 *reason = "Unknown reason for GPU unsuitability.";
249 } 249 }
250 return ret; 250 return ret;
251 } 251 }
252 252
253 /////////////////////////////////////////////////////////////////////////////// 253 ///////////////////////////////////////////////////////////////////////////////
254 254
255 #ifdef SK_SUPPORT_LEGACY_DEFAULT_PICTURE_CTOR
256 // fRecord OK
257 SkPicture::SkPicture()
258 : fWidth(0)
259 , fHeight(0) {
260 this->needsNewGenID();
261 }
262 #endif
263
264 // fRecord OK 255 // fRecord OK
265 SkPicture::SkPicture(SkScalar width, SkScalar height, 256 SkPicture::SkPicture(SkScalar width, SkScalar height,
266 const SkPictureRecord& record, 257 const SkPictureRecord& record,
267 bool deepCopyOps) 258 bool deepCopyOps)
268 : fCullWidth(width) 259 : fCullWidth(width)
269 , fCullHeight(height) 260 , fCullHeight(height)
270 , fAnalysis() { 261 , fAnalysis() {
271 this->needsNewGenID(); 262 this->needsNewGenID();
272 263
273 SkPictInfo info; 264 SkPictInfo info;
(...skipping 418 matching lines...) Expand 10 before | Expand all | Expand 10 after
692 int SkPicture::approximateOpCount() const { 683 int SkPicture::approximateOpCount() const {
693 SkASSERT(fRecord.get() || fData.get()); 684 SkASSERT(fRecord.get() || fData.get());
694 if (fRecord.get()) { 685 if (fRecord.get()) {
695 return fRecord->count(); 686 return fRecord->count();
696 } 687 }
697 if (fData.get()) { 688 if (fData.get()) {
698 return fData->opCount(); 689 return fData->opCount();
699 } 690 }
700 return 0; 691 return 0;
701 } 692 }
OLDNEW
« no previous file with comments | « include/core/SkPicture.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698