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 GrDrawBatch_DEFINED | 8 #ifndef GrDrawBatch_DEFINED |
9 #define GrDrawBatch_DEFINED | 9 #define GrDrawBatch_DEFINED |
10 | 10 |
(...skipping 82 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
93 this->pipeline()->getColorFragmentProcessor(i).name()
, | 93 this->pipeline()->getColorFragmentProcessor(i).name()
, |
94 this->pipeline()->getColorFragmentProcessor(i).dumpIn
fo().c_str()); | 94 this->pipeline()->getColorFragmentProcessor(i).dumpIn
fo().c_str()); |
95 } | 95 } |
96 string.append("CoverageStages:\n"); | 96 string.append("CoverageStages:\n"); |
97 for (int i = 0; i < this->pipeline()->numCoverageFragmentProcessors(); i
++) { | 97 for (int i = 0; i < this->pipeline()->numCoverageFragmentProcessors(); i
++) { |
98 string.appendf("\t\t%s\n\t\t%s\n", | 98 string.appendf("\t\t%s\n\t\t%s\n", |
99 this->pipeline()->getCoverageFragmentProcessor(i).nam
e(), | 99 this->pipeline()->getCoverageFragmentProcessor(i).nam
e(), |
100 this->pipeline()->getCoverageFragmentProcessor(i).dum
pInfo().c_str()); | 100 this->pipeline()->getCoverageFragmentProcessor(i).dum
pInfo().c_str()); |
101 } | 101 } |
102 string.appendf("XP: %s\n", this->pipeline()->getXferProcessor().name()); | 102 string.appendf("XP: %s\n", this->pipeline()->getXferProcessor().name()); |
| 103 |
| 104 bool scissorEnabled = this->pipeline()->getScissorState().enabled(); |
| 105 string.appendf("Scissor: "); |
| 106 if (scissorEnabled) { |
| 107 string.appendf("[L: %d, T: %d, R: %d, B: %d]\n", |
| 108 this->pipeline()->getScissorState().rect().fLeft, |
| 109 this->pipeline()->getScissorState().rect().fTop, |
| 110 this->pipeline()->getScissorState().rect().fRight, |
| 111 this->pipeline()->getScissorState().rect().fBottom); |
| 112 } else { |
| 113 string.appendf("<disabled>\n"); |
| 114 } |
| 115 string.append(INHERITED::dumpInfo()); |
| 116 |
103 return string; | 117 return string; |
104 } | 118 } |
105 | 119 |
106 protected: | 120 protected: |
107 virtual void computePipelineOptimizations(GrInitInvariantOutput* color, | 121 virtual void computePipelineOptimizations(GrInitInvariantOutput* color, |
108 GrInitInvariantOutput* coverage, | 122 GrInitInvariantOutput* coverage, |
109 GrBatchToXPOverrides* overrides) c
onst = 0; | 123 GrBatchToXPOverrides* overrides) c
onst = 0; |
110 | 124 |
111 private: | 125 private: |
112 /** | 126 /** |
(...skipping 12 matching lines...) Expand all Loading... |
125 }; | 139 }; |
126 SkTArray<QueuedUpload> fInlineUploads; | 140 SkTArray<QueuedUpload> fInlineUploads; |
127 | 141 |
128 private: | 142 private: |
129 SkAlignedSTStorage<1, GrPipeline> fPipelineStorage; | 143 SkAlignedSTStorage<1, GrPipeline> fPipelineStorage; |
130 bool fPipelineInstalled; | 144 bool fPipelineInstalled; |
131 typedef GrBatch INHERITED; | 145 typedef GrBatch INHERITED; |
132 }; | 146 }; |
133 | 147 |
134 #endif | 148 #endif |
OLD | NEW |