Chromium Code Reviews| OLD | NEW |
|---|---|
| 1 | 1 |
| 2 /* | 2 /* |
| 3 * Copyright 2010 Google Inc. | 3 * Copyright 2010 Google Inc. |
| 4 * | 4 * |
| 5 * Use of this source code is governed by a BSD-style license that can be | 5 * Use of this source code is governed by a BSD-style license that can be |
| 6 * found in the LICENSE file. | 6 * found in the LICENSE file. |
| 7 */ | 7 */ |
| 8 | 8 |
| 9 | 9 |
| 10 #include "GrGpu.h" | 10 #include "GrGpu.h" |
| (...skipping 200 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 211 this->handleDirtyContext(); | 211 this->handleDirtyContext(); |
| 212 GrIndexBuffer* ib = this->onCreateIndexBuffer(size, dynamic); | 212 GrIndexBuffer* ib = this->onCreateIndexBuffer(size, dynamic); |
| 213 if (!this->caps()->reuseScratchBuffers()) { | 213 if (!this->caps()->reuseScratchBuffers()) { |
| 214 ib->resourcePriv().removeScratchKey(); | 214 ib->resourcePriv().removeScratchKey(); |
| 215 } | 215 } |
| 216 return ib; | 216 return ib; |
| 217 } | 217 } |
| 218 | 218 |
| 219 void GrGpu::clear(const SkIRect* rect, | 219 void GrGpu::clear(const SkIRect* rect, |
| 220 GrColor color, | 220 GrColor color, |
| 221 bool canIgnoreRect, | |
| 222 GrRenderTarget* renderTarget) { | 221 GrRenderTarget* renderTarget) { |
|
bsalomon
2015/08/06 16:04:14
Shouldn't this now just require a rect param (cons
egdaniel
2015/08/06 17:02:53
Done.
| |
| 223 SkASSERT(renderTarget); | 222 SkASSERT(renderTarget); |
| 224 this->handleDirtyContext(); | 223 this->handleDirtyContext(); |
| 225 this->onClear(renderTarget, rect, color, canIgnoreRect); | 224 this->onClear(renderTarget, rect, color); |
| 226 } | 225 } |
| 227 | 226 |
| 228 void GrGpu::clearStencilClip(const SkIRect& rect, | 227 void GrGpu::clearStencilClip(const SkIRect& rect, |
| 229 bool insideClip, | 228 bool insideClip, |
| 230 GrRenderTarget* renderTarget) { | 229 GrRenderTarget* renderTarget) { |
| 231 SkASSERT(renderTarget); | 230 SkASSERT(renderTarget); |
| 232 this->handleDirtyContext(); | 231 this->handleDirtyContext(); |
| 233 this->onClearStencilClip(renderTarget, rect, insideClip); | 232 this->onClearStencilClip(renderTarget, rect, insideClip); |
| 234 } | 233 } |
| 235 | 234 |
| (...skipping 144 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 380 //////////////////////////////////////////////////////////////////////////////// | 379 //////////////////////////////////////////////////////////////////////////////// |
| 381 | 380 |
| 382 void GrGpu::draw(const DrawArgs& args, const GrVertices& vertices) { | 381 void GrGpu::draw(const DrawArgs& args, const GrVertices& vertices) { |
| 383 this->handleDirtyContext(); | 382 this->handleDirtyContext(); |
| 384 GrVertices::Iterator iter; | 383 GrVertices::Iterator iter; |
| 385 const GrNonInstancedVertices* verts = iter.init(vertices); | 384 const GrNonInstancedVertices* verts = iter.init(vertices); |
| 386 do { | 385 do { |
| 387 this->onDraw(args, *verts); | 386 this->onDraw(args, *verts); |
| 388 } while ((verts = iter.next())); | 387 } while ((verts = iter.next())); |
| 389 } | 388 } |
| OLD | NEW |