OLD | NEW |
1 /* | 1 /* |
2 * Copyright 2011 Google Inc. | 2 * Copyright 2011 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 #ifndef GrPathRenderer_DEFINED | 8 #ifndef GrPathRenderer_DEFINED |
9 #define GrPathRenderer_DEFINED | 9 #define GrPathRenderer_DEFINED |
10 | 10 |
(...skipping 178 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
189 const SkMatrix* fViewMatrix; | 189 const SkMatrix* fViewMatrix; |
190 bool fIsAA; | 190 bool fIsAA; |
191 const GrShape* fShape; | 191 const GrShape* fShape; |
192 | 192 |
193 #ifdef SK_DEBUG | 193 #ifdef SK_DEBUG |
194 void validate() const { | 194 void validate() const { |
195 SkASSERT(fResourceProvider); | 195 SkASSERT(fResourceProvider); |
196 SkASSERT(fDrawContext); | 196 SkASSERT(fDrawContext); |
197 SkASSERT(fViewMatrix); | 197 SkASSERT(fViewMatrix); |
198 SkASSERT(fShape); | 198 SkASSERT(fShape); |
199 SkASSERT(fShape->style().isSimpleFill()) | 199 SkASSERT(fShape->style().isSimpleFill()); |
200 SkPath path; | 200 SkPath path; |
201 fShape->asPath(&path); | 201 fShape->asPath(&path); |
202 SkASSERT(!path.isInverseFillType()); | 202 SkASSERT(!path.isInverseFillType()); |
203 } | 203 } |
204 #endif | 204 #endif |
205 }; | 205 }; |
206 | 206 |
207 /** | 207 /** |
208 * Draws the path to the stencil buffer. Assume the writable stencil bits ar
e already | 208 * Draws the path to the stencil buffer. Assume the writable stencil bits ar
e already |
209 * initialized to zero. The pixels inside the path will have non-zero stenci
l values afterwards. | 209 * initialized to zero. The pixels inside the path will have non-zero stenci
l values afterwards. |
(...skipping 75 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
285 drawArgs.fShape = args.fShape; | 285 drawArgs.fShape = args.fShape; |
286 drawArgs.fAntiAlias = false; // In this case the MSAA handles the AA so
we want to draw BW | 286 drawArgs.fAntiAlias = false; // In this case the MSAA handles the AA so
we want to draw BW |
287 drawArgs.fGammaCorrect = false; | 287 drawArgs.fGammaCorrect = false; |
288 this->drawPath(drawArgs); | 288 this->drawPath(drawArgs); |
289 } | 289 } |
290 | 290 |
291 typedef SkRefCnt INHERITED; | 291 typedef SkRefCnt INHERITED; |
292 }; | 292 }; |
293 | 293 |
294 #endif | 294 #endif |
OLD | NEW |