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

Side by Side Diff: src/gpu/GrReducedClip.cpp

Issue 1316233002: Style Change: NULL->nullptr (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: 2015-08-27 (Thursday) 10:25:06 EDT Created 5 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 | « src/gpu/GrReducedClip.h ('k') | src/gpu/GrRenderTarget.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 7
8 #include "GrReducedClip.h" 8 #include "GrReducedClip.h"
9 9
10 typedef SkClipStack::Element Element; 10 typedef SkClipStack::Element Element;
(...skipping 16 matching lines...) Expand all
27 27
28 // During our backwards walk, track whether we've seen ops that either grow or shrink the clip. 28 // During our backwards walk, track whether we've seen ops that either grow or shrink the clip.
29 // TODO: track these per saved clip so that we can consider them on the forw ard pass. 29 // TODO: track these per saved clip so that we can consider them on the forw ard pass.
30 bool embiggens = false; 30 bool embiggens = false;
31 bool emsmallens = false; 31 bool emsmallens = false;
32 32
33 SkClipStack::Iter iter(stack, SkClipStack::Iter::kTop_IterStart); 33 SkClipStack::Iter iter(stack, SkClipStack::Iter::kTop_IterStart);
34 int numAAElements = 0; 34 int numAAElements = 0;
35 while ((kUnknown_InitialState == *initialState)) { 35 while ((kUnknown_InitialState == *initialState)) {
36 const Element* element = iter.prev(); 36 const Element* element = iter.prev();
37 if (NULL == element) { 37 if (nullptr == element) {
38 *initialState = GrReducedClip::kAllIn_InitialState; 38 *initialState = GrReducedClip::kAllIn_InitialState;
39 break; 39 break;
40 } 40 }
41 if (SkClipStack::kEmptyGenID == element->getGenID()) { 41 if (SkClipStack::kEmptyGenID == element->getGenID()) {
42 *initialState = GrReducedClip::kAllOut_InitialState; 42 *initialState = GrReducedClip::kAllOut_InitialState;
43 break; 43 break;
44 } 44 }
45 if (SkClipStack::kWideOpenGenID == element->getGenID()) { 45 if (SkClipStack::kWideOpenGenID == element->getGenID()) {
46 *initialState = GrReducedClip::kAllIn_InitialState; 46 *initialState = GrReducedClip::kAllIn_InitialState;
47 break; 47 break;
(...skipping 384 matching lines...) Expand 10 before | Expand all | Expand 10 after
432 SkRect scalarBounds = SkRect::Make(*bounds); 432 SkRect scalarBounds = SkRect::Make(*bounds);
433 433
434 // Now that we have determined the bounds to use and filtered out the trivia l cases, call the 434 // Now that we have determined the bounds to use and filtered out the trivia l cases, call the
435 // helper that actually walks the stack. 435 // helper that actually walks the stack.
436 reduced_stack_walker(stack, scalarBounds, result, resultGenID, initialState, requiresAA); 436 reduced_stack_walker(stack, scalarBounds, result, resultGenID, initialState, requiresAA);
437 437
438 // The list that was computed in this function may be cached based on the ge n id of the last 438 // The list that was computed in this function may be cached based on the ge n id of the last
439 // element. 439 // element.
440 SkASSERT(SkClipStack::kInvalidGenID != *resultGenID); 440 SkASSERT(SkClipStack::kInvalidGenID != *resultGenID);
441 } 441 }
OLDNEW
« no previous file with comments | « src/gpu/GrReducedClip.h ('k') | src/gpu/GrRenderTarget.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698