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

Side by Side Diff: src/gpu/GrDrawState.h

Issue 684223002: cleanup reentrance logic in CMM (Closed) Base URL: https://skia.googlesource.com/skia.git@drawtarget_on_clip_manager
Patch Set: feedback inc Created 6 years, 1 month 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/GrClipMaskManager.cpp ('k') | tests/GLProgramsTest.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 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 GrDrawState_DEFINED 8 #ifndef GrDrawState_DEFINED
9 #define GrDrawState_DEFINED 9 #define GrDrawState_DEFINED
10 10
(...skipping 600 matching lines...) Expand 10 before | Expand all | Expand 10 after
611 611
612 /** 612 /**
613 * Usually coverage is applied after color blending. The color is blende d using the coeffs 613 * Usually coverage is applied after color blending. The color is blende d using the coeffs
614 * specified by setBlendFunc(). The blended color is then combined with dst using coeffs 614 * specified by setBlendFunc(). The blended color is then combined with dst using coeffs
615 * of src_coverage, 1-src_coverage. Sometimes we are explicitly drawing a coverage mask. In 615 * of src_coverage, 1-src_coverage. Sometimes we are explicitly drawing a coverage mask. In
616 * this case there is no distinction between coverage and color and the caller needs direct 616 * this case there is no distinction between coverage and color and the caller needs direct
617 * control over the blend coeffs. When set, there will be a single blend step controlled by 617 * control over the blend coeffs. When set, there will be a single blend step controlled by
618 * setBlendFunc() which will use coverage*color as the src color. 618 * setBlendFunc() which will use coverage*color as the src color.
619 */ 619 */
620 kCoverageDrawing_StateBit = 0x10, 620 kCoverageDrawing_StateBit = 0x10,
621 621 kLast_StateBit = kCoverageDrawing_StateBit,
622 // Users of the class may add additional bits to the vector
623 kDummyStateBit,
624 kLastPublicStateBit = kDummyStateBit-1,
625 }; 622 };
626 623
627 uint32_t getFlagBits() const { return fFlagBits; } 624 uint32_t getFlagBits() const { return fFlagBits; }
628 625
629 bool isStateFlagEnabled(uint32_t stateBit) const { return 0 != (stateBit & f FlagBits); } 626 bool isStateFlagEnabled(uint32_t stateBit) const { return 0 != (stateBit & f FlagBits); }
630 627
631 bool isClipState() const { return 0 != (fFlagBits & kClip_StateBit); } 628 bool isClipState() const { return 0 != (fFlagBits & kClip_StateBit); }
632 bool isColorWriteDisabled() const { return 0 != (fFlagBits & kNoColorWrites_ StateBit); } 629 bool isColorWriteDisabled() const { return 0 != (fFlagBits & kNoColorWrites_ StateBit); }
633 bool isCoverageDrawing() const { return 0 != (fFlagBits & kCoverageDrawing_S tateBit); } 630 bool isCoverageDrawing() const { return 0 != (fFlagBits & kCoverageDrawing_S tateBit); }
634 631
(...skipping 221 matching lines...) Expand 10 before | Expand all | Expand 10 after
856 mutable uint32_t fCachedCapsID; 853 mutable uint32_t fCachedCapsID;
857 854
858 friend class GrOptDrawState; 855 friend class GrOptDrawState;
859 856
860 typedef SkRefCnt INHERITED; 857 typedef SkRefCnt INHERITED;
861 }; 858 };
862 859
863 GR_MAKE_BITFIELD_OPS(GrDrawState::BlendOptFlags); 860 GR_MAKE_BITFIELD_OPS(GrDrawState::BlendOptFlags);
864 861
865 #endif 862 #endif
OLDNEW
« no previous file with comments | « src/gpu/GrClipMaskManager.cpp ('k') | tests/GLProgramsTest.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698