Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(885)

Side by Side Diff: src/gpu/GrGpu.cpp

Issue 701573002: Workaround for PowerVR clear issue. (Closed) Base URL: https://skia.googlesource.com/skia.git@no_null
Patch Set: Add missing spaces Created 6 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
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 176 matching lines...) Expand 10 before | Expand all | Expand 10 after
187 SkFAIL("Can't get indices into buffer!"); 187 SkFAIL("Can't get indices into buffer!");
188 } 188 }
189 SkDELETE_ARRAY(data); 189 SkDELETE_ARRAY(data);
190 } else { 190 } else {
191 buffer->unmap(); 191 buffer->unmap();
192 } 192 }
193 } 193 }
194 return buffer; 194 return buffer;
195 } 195 }
196 196
197 void GrGpu::clear(const SkIRect* rect, 197 void GrGpu::onClear(const SkIRect* rect,
198 GrColor color, 198 GrColor color,
199 bool canIgnoreRect, 199 bool canIgnoreRect,
200 GrRenderTarget* renderTarget) { 200 GrRenderTarget* renderTarget) {
201 SkASSERT(renderTarget); 201 SkASSERT(renderTarget);
202 this->handleDirtyContext(); 202 this->handleDirtyContext();
203 this->onClear(renderTarget, rect, color, canIgnoreRect); 203 this->onGpuClear(renderTarget, rect, color, canIgnoreRect);
204 } 204 }
205 205
206 void GrGpu::clearStencilClip(const SkIRect& rect, 206 void GrGpu::clearStencilClip(const SkIRect& rect,
207 bool insideClip, 207 bool insideClip,
208 GrRenderTarget* renderTarget) { 208 GrRenderTarget* renderTarget) {
209 if (NULL == renderTarget) { 209 if (NULL == renderTarget) {
210 renderTarget = this->getDrawState().getRenderTarget(); 210 renderTarget = this->getDrawState().getRenderTarget();
211 } 211 }
212 if (NULL == renderTarget) { 212 if (NULL == renderTarget) {
213 SkASSERT(0); 213 SkASSERT(0);
(...skipping 291 matching lines...) Expand 10 before | Expand all | Expand 10 after
505 --fVertexPoolUseCnt; 505 --fVertexPoolUseCnt;
506 } 506 }
507 507
508 void GrGpu::releaseReservedIndexSpace() { 508 void GrGpu::releaseReservedIndexSpace() {
509 const GeometrySrcState& geoSrc = this->getGeomSrc(); 509 const GeometrySrcState& geoSrc = this->getGeomSrc();
510 SkASSERT(kReserved_GeometrySrcType == geoSrc.fIndexSrc); 510 SkASSERT(kReserved_GeometrySrcType == geoSrc.fIndexSrc);
511 size_t bytes = geoSrc.fIndexCount * sizeof(uint16_t); 511 size_t bytes = geoSrc.fIndexCount * sizeof(uint16_t);
512 fIndexPool->putBack(bytes); 512 fIndexPool->putBack(bytes);
513 --fIndexPoolUseCnt; 513 --fIndexPoolUseCnt;
514 } 514 }
OLDNEW
« no previous file with comments | « src/gpu/GrGpu.h ('k') | src/gpu/GrInOrderDrawBuffer.h » ('j') | src/gpu/gl/GrGLUtil.cpp » ('J')

Powered by Google App Engine
This is Rietveld 408576698