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

Side by Side Diff: src/pathops/SkPathWriter.h

Issue 1037953004: add conics to path ops (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: turn off pathops specific debuggging Created 5 years, 8 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/pathops/SkPathOpsTypes.h ('k') | src/pathops/SkPathWriter.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 * Copyright 2012 Google Inc. 2 * Copyright 2012 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 #ifndef SkPathWriter_DEFINED 7 #ifndef SkPathWriter_DEFINED
8 #define SkPathWriter_DEFINED 8 #define SkPathWriter_DEFINED
9 9
10 #include "SkPath.h" 10 #include "SkPath.h"
11 11
12 class SkPathWriter { 12 class SkPathWriter {
13 public: 13 public:
14 SkPathWriter(SkPath& path); 14 SkPathWriter(SkPath& path);
15 void close(); 15 void close();
16 void conicTo(const SkPoint& pt1, const SkPoint& pt2, SkScalar weight);
16 void cubicTo(const SkPoint& pt1, const SkPoint& pt2, const SkPoint& pt3); 17 void cubicTo(const SkPoint& pt1, const SkPoint& pt2, const SkPoint& pt3);
17 void deferredLine(const SkPoint& pt); 18 void deferredLine(const SkPoint& pt);
18 void deferredMove(const SkPoint& pt); 19 void deferredMove(const SkPoint& pt);
19 void deferredMoveLine(const SkPoint& pt); 20 void deferredMoveLine(const SkPoint& pt);
20 bool hasMove() const; 21 bool hasMove() const;
21 void init(); 22 void init();
22 bool isClosed() const; 23 bool isClosed() const;
23 bool isEmpty() const { return fEmpty; } 24 bool isEmpty() const { return fEmpty; }
24 void lineTo(); 25 void lineTo();
25 const SkPath* nativePath() const; 26 const SkPath* nativePath() const;
26 void nudge(); 27 void nudge();
27 void quadTo(const SkPoint& pt1, const SkPoint& pt2); 28 void quadTo(const SkPoint& pt1, const SkPoint& pt2);
28 bool someAssemblyRequired() const; 29 bool someAssemblyRequired() const;
29 30
30 private: 31 private:
31 bool changedSlopes(const SkPoint& pt) const; 32 bool changedSlopes(const SkPoint& pt) const;
32 void moveTo(); 33 void moveTo();
33 34
34 SkPath* fPathPtr; 35 SkPath* fPathPtr;
35 SkPoint fDefer[2]; 36 SkPoint fDefer[2];
36 SkPoint fFirstPt; 37 SkPoint fFirstPt;
37 int fCloses; 38 int fCloses;
38 int fMoves; 39 int fMoves;
39 bool fEmpty; 40 bool fEmpty;
40 bool fHasMove; 41 bool fHasMove;
41 bool fMoved; 42 bool fMoved;
42 }; 43 };
43 44
44 #endif /* defined(__PathOps__SkPathWriter__) */ 45 #endif /* defined(__PathOps__SkPathWriter__) */
OLDNEW
« no previous file with comments | « src/pathops/SkPathOpsTypes.h ('k') | src/pathops/SkPathWriter.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698