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

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

Issue 168893002: fix calling undef inline func build error (Closed) Base URL: https://skia.googlecode.com/svn/trunk
Patch Set: Hanlde rrect in SkCanvas::validateClip() 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 | « src/core/SkCanvas.cpp ('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 2011 Google Inc. 3 * Copyright 2011 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 #include "SkClipStack.h" 8 #include "SkClipStack.h"
9 #include "SkPath.h" 9 #include "SkPath.h"
10 #include "SkThread.h" 10 #include "SkThread.h"
(...skipping 85 matching lines...) Expand 10 before | Expand all | Expand 10 after
96 case kRRect_Type: 96 case kRRect_Type:
97 path->reset(); 97 path->reset();
98 path->addRRect(fRRect); 98 path->addRRect(fRRect);
99 break; 99 break;
100 case kPath_Type: 100 case kPath_Type:
101 *path = fPath; 101 *path = fPath;
102 break; 102 break;
103 } 103 }
104 } 104 }
105 105
106 void SkClipStack::Element::setEmpty() {
107 fType = kEmpty_Type;
108 fFiniteBound.setEmpty();
109 fFiniteBoundType = kNormal_BoundsType;
110 fIsIntersectionOfRects = false;
111 fRect.setEmpty();
112 fRRect.setEmpty();
113 fPath.reset();
114 fGenID = kEmptyGenID;
115 SkDEBUGCODE(this->checkEmpty();)
116 }
117
106 void SkClipStack::Element::checkEmpty() const { 118 void SkClipStack::Element::checkEmpty() const {
107 SkASSERT(fFiniteBound.isEmpty()); 119 SkASSERT(fFiniteBound.isEmpty());
108 SkASSERT(kNormal_BoundsType == fFiniteBoundType); 120 SkASSERT(kNormal_BoundsType == fFiniteBoundType);
109 SkASSERT(!fIsIntersectionOfRects); 121 SkASSERT(!fIsIntersectionOfRects);
110 SkASSERT(kEmptyGenID == fGenID); 122 SkASSERT(kEmptyGenID == fGenID);
111 SkASSERT(fPath.isEmpty()); 123 SkASSERT(fPath.isEmpty());
112 } 124 }
113 125
114 bool SkClipStack::Element::canBeIntersectedInPlace(int saveCount, SkRegion::Op o p) const { 126 bool SkClipStack::Element::canBeIntersectedInPlace(int saveCount, SkRegion::Op o p) const {
115 if (kEmpty_Type == fType && 127 if (kEmpty_Type == fType &&
(...skipping 664 matching lines...) Expand 10 before | Expand all | Expand 10 after
780 return kWideOpenGenID; 792 return kWideOpenGenID;
781 } 793 }
782 794
783 const Element* back = static_cast<const Element*>(fDeque.back()); 795 const Element* back = static_cast<const Element*>(fDeque.back());
784 if (kInsideOut_BoundsType == back->fFiniteBoundType && back->fFiniteBound.is Empty()) { 796 if (kInsideOut_BoundsType == back->fFiniteBoundType && back->fFiniteBound.is Empty()) {
785 return kWideOpenGenID; 797 return kWideOpenGenID;
786 } 798 }
787 799
788 return back->getGenID(); 800 return back->getGenID();
789 } 801 }
OLDNEW
« no previous file with comments | « src/core/SkCanvas.cpp ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698