| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright 2010 Google Inc. | 2 * Copyright 2010 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 GrDrawTarget_DEFINED | 8 #ifndef GrDrawTarget_DEFINED |
| 9 #define GrDrawTarget_DEFINED | 9 #define GrDrawTarget_DEFINED |
| 10 | 10 |
| (...skipping 105 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 116 * @param localRect optional rect that specifies local coords to map onto | 116 * @param localRect optional rect that specifies local coords to map onto |
| 117 * rect. If NULL then rect serves as the local coords. | 117 * rect. If NULL then rect serves as the local coords. |
| 118 * @param localMatrix Optional local matrix. The local coordinates are speci
fied by localRect, | 118 * @param localMatrix Optional local matrix. The local coordinates are speci
fied by localRect, |
| 119 * or if it is NULL by rect. This matrix applies to the c
oordinate implied by | 119 * or if it is NULL by rect. This matrix applies to the c
oordinate implied by |
| 120 * that rectangle before it is input to GrCoordTransforms
that read local | 120 * that rectangle before it is input to GrCoordTransforms
that read local |
| 121 * coordinates | 121 * coordinates |
| 122 */ | 122 */ |
| 123 void drawBWRect(const GrPipelineBuilder& pipelineBuilder, | 123 void drawBWRect(const GrPipelineBuilder& pipelineBuilder, |
| 124 GrColor color, | 124 GrColor color, |
| 125 const SkMatrix& viewMatrix, | 125 const SkMatrix& viewMatrix, |
| 126 const SkRect& rect); |
| 127 |
| 128 void drawBWRect(const GrPipelineBuilder& pipelineBuilder, |
| 129 GrColor color, |
| 130 const SkMatrix& viewMatrix, |
| 126 const SkRect& rect, | 131 const SkRect& rect, |
| 127 const SkRect* localRect, | 132 const SkMatrix& localMatrix); |
| 128 const SkMatrix* localMatrix); | 133 |
| 134 void drawBWRect(const GrPipelineBuilder& pipelineBuilder, |
| 135 GrColor color, |
| 136 const SkMatrix& viewMatrix, |
| 137 const SkRect& rect, |
| 138 const SkRect& localRect); |
| 129 | 139 |
| 130 /** | 140 /** |
| 131 * Helper for drawRect when the caller doesn't need separate local rects or
matrices. | 141 * Helper for drawRect when the caller doesn't need separate local rects or
matrices. |
| 132 */ | 142 */ |
| 133 void drawSimpleRect(const GrPipelineBuilder& ds, GrColor color, const SkMatr
ix& viewM, | 143 void drawSimpleRect(const GrPipelineBuilder& ds, GrColor color, const SkMatr
ix& viewM, |
| 134 const SkRect& rect) { | 144 const SkRect& rect) { |
| 135 this->drawBWRect(ds, color, viewM, rect, NULL, NULL); | 145 this->drawBWRect(ds, color, viewM, rect); |
| 136 } | 146 } |
| 137 void drawSimpleRect(const GrPipelineBuilder& ds, GrColor color, const SkMatr
ix& viewM, | 147 void drawSimpleRect(const GrPipelineBuilder& ds, GrColor color, const SkMatr
ix& viewM, |
| 138 const SkIRect& irect) { | 148 const SkIRect& irect) { |
| 139 SkRect rect = SkRect::Make(irect); | 149 SkRect rect = SkRect::Make(irect); |
| 140 this->drawBWRect(ds, color, viewM, rect, NULL, NULL); | 150 this->drawBWRect(ds, color, viewM, rect); |
| 141 } | 151 } |
| 142 | 152 |
| 143 void drawAARect(const GrPipelineBuilder& pipelineBuilder, | 153 void drawAARect(const GrPipelineBuilder& pipelineBuilder, |
| 144 GrColor color, | 154 GrColor color, |
| 145 const SkMatrix& viewMatrix, | 155 const SkMatrix& viewMatrix, |
| 146 const SkRect& rect, | 156 const SkRect& rect, |
| 147 const SkRect& devRect); | 157 const SkRect& devRect); |
| 148 | 158 |
| 149 /** | 159 /** |
| 150 * Clear the passed in render target. Ignores the GrPipelineBuilder and clip
. Clears the whole | 160 * Clear the passed in render target. Ignores the GrPipelineBuilder and clip
. Clears the whole |
| (...skipping 163 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 314 bool setupClip(const GrPipelineBuilder&, | 324 bool setupClip(const GrPipelineBuilder&, |
| 315 GrPipelineBuilder::AutoRestoreFragmentProcessorState*, | 325 GrPipelineBuilder::AutoRestoreFragmentProcessorState*, |
| 316 GrPipelineBuilder::AutoRestoreStencil*, | 326 GrPipelineBuilder::AutoRestoreStencil*, |
| 317 GrScissorState* scissorState, | 327 GrScissorState* scissorState, |
| 318 const SkRect* devBounds) override; | 328 const SkRect* devBounds) override; |
| 319 | 329 |
| 320 typedef GrDrawTarget INHERITED; | 330 typedef GrDrawTarget INHERITED; |
| 321 }; | 331 }; |
| 322 | 332 |
| 323 #endif | 333 #endif |
| OLD | NEW |