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

Side by Side Diff: include/core/SkPathRef.h

Issue 159653004: SkBitmap now really stores SkImageInfo -- config is just a ruse (Closed) Base URL: https://skia.googlecode.com/svn/trunk
Patch Set: Created 6 years, 10 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 | Annotate | Revision Log
« no previous file with comments | « include/core/SkImageInfo.h ('k') | src/core/SkBitmap.cpp » ('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 /* 2 /*
3 * Copyright 2012 Google Inc. 3 * Copyright 2012 Google Inc.
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 #ifndef SkPathRef_DEFINED 9 #ifndef SkPathRef_DEFINED
10 #define SkPathRef_DEFINED 10 #define SkPathRef_DEFINED
(...skipping 88 matching lines...) Expand 10 before | Expand all | Expand 10 after
99 * Gets the path ref that is wrapped in the Editor. 99 * Gets the path ref that is wrapped in the Editor.
100 */ 100 */
101 SkPathRef* pathRef() { return fPathRef; } 101 SkPathRef* pathRef() { return fPathRef; }
102 102
103 void setIsOval(bool isOval) { fPathRef->setIsOval(isOval); } 103 void setIsOval(bool isOval) { fPathRef->setIsOval(isOval); }
104 104
105 void setBounds(const SkRect& rect) { fPathRef->setBounds(rect); } 105 void setBounds(const SkRect& rect) { fPathRef->setBounds(rect); }
106 106
107 // In some cases we need to inject a leading moveTo before we add points 107 // In some cases we need to inject a leading moveTo before we add points
108 // for lineTo, quadTo, conicTo, cubicTo 108 // for lineTo, quadTo, conicTo, cubicTo
109 // 109 //
110 // SkPath path; path.lineTo(...); <--- need a leading moveTo(0, 0) 110 // SkPath path; path.lineTo(...); <--- need a leading moveTo(0, 0)
111 // SkPath path; ... path.close(); path.lineTo(...) <-- need a moveTo(pre vious moveTo) 111 // SkPath path; ... path.close(); path.lineTo(...) <-- need a moveTo(pre vious moveTo)
112 void injectMoveToIfNeeded() { fPathRef->injectMoveToIfNeeded(); } 112 void injectMoveToIfNeeded() { fPathRef->injectMoveToIfNeeded(); }
113 113
114 private: 114 private:
115 SkPathRef* fPathRef; 115 SkPathRef* fPathRef;
116 }; 116 };
117 117
118 public: 118 public:
119 /** 119 /**
(...skipping 343 matching lines...) Expand 10 before | Expand all | Expand 10 after
463 kEmptyGenID = 1, // GenID reserved for path ref with zero points and zer o verbs. 463 kEmptyGenID = 1, // GenID reserved for path ref with zero points and zer o verbs.
464 }; 464 };
465 mutable uint32_t fGenerationID; 465 mutable uint32_t fGenerationID;
466 SkDEBUGCODE(int32_t fEditorsAttached;) // assert that only one editor in use at any time. 466 SkDEBUGCODE(int32_t fEditorsAttached;) // assert that only one editor in use at any time.
467 467
468 friend class PathRefTest_Private; 468 friend class PathRefTest_Private;
469 typedef SkRefCnt INHERITED; 469 typedef SkRefCnt INHERITED;
470 }; 470 };
471 471
472 #endif 472 #endif
OLDNEW
« no previous file with comments | « include/core/SkImageInfo.h ('k') | src/core/SkBitmap.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698