| 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 #include "GrPipeline.h" | 8 #include "GrPipeline.h" |
| 9 | 9 |
| 10 #include "GrCaps.h" | 10 #include "GrCaps.h" |
| (...skipping 48 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 59 pipeline->fRenderTarget.reset(builder.fRenderTarget.get()); | 59 pipeline->fRenderTarget.reset(builder.fRenderTarget.get()); |
| 60 SkASSERT(pipeline->fRenderTarget); | 60 SkASSERT(pipeline->fRenderTarget); |
| 61 pipeline->fScissorState = *args.fScissor; | 61 pipeline->fScissorState = *args.fScissor; |
| 62 pipeline->fStencilSettings = builder.getStencil(); | 62 pipeline->fStencilSettings = builder.getStencil(); |
| 63 pipeline->fDrawFace = builder.getDrawFace(); | 63 pipeline->fDrawFace = builder.getDrawFace(); |
| 64 | 64 |
| 65 pipeline->fFlags = 0; | 65 pipeline->fFlags = 0; |
| 66 if (builder.isHWAntialias()) { | 66 if (builder.isHWAntialias()) { |
| 67 pipeline->fFlags |= kHWAA_Flag; | 67 pipeline->fFlags |= kHWAA_Flag; |
| 68 } | 68 } |
| 69 if (builder.isDither()) { | |
| 70 pipeline->fFlags |= kDither_Flag; | |
| 71 } | |
| 72 if (builder.snapVerticesToPixelCenters()) { | 69 if (builder.snapVerticesToPixelCenters()) { |
| 73 pipeline->fFlags |= kSnapVertices_Flag; | 70 pipeline->fFlags |= kSnapVertices_Flag; |
| 74 } | 71 } |
| 75 | 72 |
| 76 int firstColorProcessorIdx = args.fColorPOI.firstEffectiveProcessorIndex(); | 73 int firstColorProcessorIdx = args.fColorPOI.firstEffectiveProcessorIndex(); |
| 77 | 74 |
| 78 // TODO: Once we can handle single or four channel input into coverage GrFra
gmentProcessors | 75 // TODO: Once we can handle single or four channel input into coverage GrFra
gmentProcessors |
| 79 // then we can use GrPipelineBuilder's coverageProcInfo (like color above) t
o set this initial | 76 // then we can use GrPipelineBuilder's coverageProcInfo (like color above) t
o set this initial |
| 80 // information. | 77 // information. |
| 81 int firstCoverageProcessorIdx = 0; | 78 int firstCoverageProcessorIdx = 0; |
| (...skipping 98 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 180 } | 177 } |
| 181 | 178 |
| 182 for (int i = 0; i < a.numFragmentProcessors(); i++) { | 179 for (int i = 0; i < a.numFragmentProcessors(); i++) { |
| 183 if (!a.getFragmentProcessor(i).isEqual(b.getFragmentProcessor(i), ignore
CoordTransforms)) { | 180 if (!a.getFragmentProcessor(i).isEqual(b.getFragmentProcessor(i), ignore
CoordTransforms)) { |
| 184 return false; | 181 return false; |
| 185 } | 182 } |
| 186 } | 183 } |
| 187 return true; | 184 return true; |
| 188 } | 185 } |
| 189 | 186 |
| OLD | NEW |