| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright 2015 Google Inc. | 2 * Copyright 2015 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 GrPipelineBuilder_DEFINED | 8 #ifndef GrPipelineBuilder_DEFINED |
| 9 #define GrPipelineBuilder_DEFINED | 9 #define GrPipelineBuilder_DEFINED |
| 10 | 10 |
| 11 #include "GrBlend.h" | 11 #include "GrBlend.h" |
| 12 #include "GrClip.h" | 12 #include "GrClip.h" |
| 13 #include "GrDrawTargetCaps.h" | 13 #include "GrDrawTargetCaps.h" |
| 14 #include "GrGpuResourceRef.h" | 14 #include "GrGpuResourceRef.h" |
| 15 #include "GrFragmentStage.h" | 15 #include "GrFragmentStage.h" |
| 16 #include "GrProcOptInfo.h" | 16 #include "GrProcOptInfo.h" |
| 17 #include "GrRenderTarget.h" | 17 #include "GrRenderTarget.h" |
| 18 #include "GrStencil.h" | 18 #include "GrStencil.h" |
| 19 #include "GrXferProcessor.h" | 19 #include "GrXferProcessor.h" |
| 20 #include "SkMatrix.h" | 20 #include "SkMatrix.h" |
| 21 #include "effects/GrCoverageSetOpXP.h" | 21 #include "effects/GrCoverageSetOpXP.h" |
| 22 #include "effects/GrDisableColorXP.h" | 22 #include "effects/GrDisableColorXP.h" |
| 23 #include "effects/GrPorterDuffXferProcessor.h" | 23 #include "effects/GrPorterDuffXferProcessor.h" |
| 24 #include "effects/GrSimpleTextureEffect.h" | 24 #include "effects/GrSimpleTextureEffect.h" |
| 25 | 25 |
| 26 class GrBatch; | 26 class GrBatch; |
| 27 class GrDrawTargetCaps; | 27 class GrCaps; |
| 28 class GrPaint; | 28 class GrPaint; |
| 29 class GrTexture; | 29 class GrTexture; |
| 30 | 30 |
| 31 class GrPipelineBuilder { | 31 class GrPipelineBuilder { |
| 32 public: | 32 public: |
| 33 GrPipelineBuilder(); | 33 GrPipelineBuilder(); |
| 34 | 34 |
| 35 GrPipelineBuilder(const GrPipelineBuilder& pipelineBuilder) { | 35 GrPipelineBuilder(const GrPipelineBuilder& pipelineBuilder) { |
| 36 SkDEBUGCODE(fBlockEffectRemovalCnt = 0;) | 36 SkDEBUGCODE(fBlockEffectRemovalCnt = 0;) |
| 37 *this = pipelineBuilder; | 37 *this = pipelineBuilder; |
| (...skipping 134 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 172 const GrXPFactory* getXPFactory() const { | 172 const GrXPFactory* getXPFactory() const { |
| 173 if (!fXPFactory) { | 173 if (!fXPFactory) { |
| 174 fXPFactory.reset(GrPorterDuffXPFactory::Create(SkXfermode::kSrc_Mode
)); | 174 fXPFactory.reset(GrPorterDuffXPFactory::Create(SkXfermode::kSrc_Mode
)); |
| 175 } | 175 } |
| 176 return fXPFactory.get(); | 176 return fXPFactory.get(); |
| 177 } | 177 } |
| 178 | 178 |
| 179 /** | 179 /** |
| 180 * Checks whether the xp will need a copy of the destination to correctly bl
end. | 180 * Checks whether the xp will need a copy of the destination to correctly bl
end. |
| 181 */ | 181 */ |
| 182 bool willXPNeedDstCopy(const GrDrawTargetCaps& caps, const GrProcOptInfo& co
lorPOI, | 182 bool willXPNeedDstCopy(const GrCaps& caps, const GrProcOptInfo& colorPOI, |
| 183 const GrProcOptInfo& coveragePOI) const; | 183 const GrProcOptInfo& coveragePOI) const; |
| 184 | 184 |
| 185 /// @} | 185 /// @} |
| 186 | 186 |
| 187 | 187 |
| 188 /////////////////////////////////////////////////////////////////////////// | 188 /////////////////////////////////////////////////////////////////////////// |
| 189 /// @name Render Target | 189 /// @name Render Target |
| 190 //// | 190 //// |
| 191 | 191 |
| 192 /** | 192 /** |
| (...skipping 241 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 434 mutable GrProcOptInfo fCoverageProcInfo; | 434 mutable GrProcOptInfo fCoverageProcInfo; |
| 435 mutable bool fColorProcInfoValid; | 435 mutable bool fColorProcInfoValid; |
| 436 mutable bool fCoverageProcInfoValid; | 436 mutable bool fCoverageProcInfoValid; |
| 437 mutable GrColor fColorCache; | 437 mutable GrColor fColorCache; |
| 438 mutable GrColor fCoverageCache; | 438 mutable GrColor fCoverageCache; |
| 439 | 439 |
| 440 friend class GrPipeline; | 440 friend class GrPipeline; |
| 441 }; | 441 }; |
| 442 | 442 |
| 443 #endif | 443 #endif |
| OLD | NEW |