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

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

Issue 578563002: Remove createPath* from GrGpu and GrContext (Closed) Base URL: https://skia.googlesource.com/skia.git@upload_glyphmemorypath
Patch Set: Simple quick change Created 6 years, 3 months 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
« no previous file with comments | « src/gpu/GrGpu.h ('k') | src/gpu/GrPathRendering.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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 146 matching lines...) Expand 10 before | Expand all | Expand 10 after
157 GrVertexBuffer* GrGpu::createVertexBuffer(size_t size, bool dynamic) { 157 GrVertexBuffer* GrGpu::createVertexBuffer(size_t size, bool dynamic) {
158 this->handleDirtyContext(); 158 this->handleDirtyContext();
159 return this->onCreateVertexBuffer(size, dynamic); 159 return this->onCreateVertexBuffer(size, dynamic);
160 } 160 }
161 161
162 GrIndexBuffer* GrGpu::createIndexBuffer(size_t size, bool dynamic) { 162 GrIndexBuffer* GrGpu::createIndexBuffer(size_t size, bool dynamic) {
163 this->handleDirtyContext(); 163 this->handleDirtyContext();
164 return this->onCreateIndexBuffer(size, dynamic); 164 return this->onCreateIndexBuffer(size, dynamic);
165 } 165 }
166 166
167 GrPath* GrGpu::createPath(const SkPath& path, const SkStrokeRec& stroke) {
168 SkASSERT(this->caps()->pathRenderingSupport());
169 this->handleDirtyContext();
170 return this->pathRendering()->createPath(path, stroke);
171 }
172
173 GrPathRange* GrGpu::createPathRange(size_t size, const SkStrokeRec& stroke) {
174 this->handleDirtyContext();
175 return this->pathRendering()->createPathRange(size, stroke);
176 }
177
178 void GrGpu::clear(const SkIRect* rect, 167 void GrGpu::clear(const SkIRect* rect,
179 GrColor color, 168 GrColor color,
180 bool canIgnoreRect, 169 bool canIgnoreRect,
181 GrRenderTarget* renderTarget) { 170 GrRenderTarget* renderTarget) {
182 if (NULL == renderTarget) { 171 if (NULL == renderTarget) {
183 renderTarget = this->getDrawState().getRenderTarget(); 172 renderTarget = this->getDrawState().getRenderTarget();
184 } 173 }
185 if (NULL == renderTarget) { 174 if (NULL == renderTarget) {
186 SkASSERT(0); 175 SkASSERT(0);
187 return; 176 return;
(...skipping 334 matching lines...) Expand 10 before | Expand all | Expand 10 after
522 } 511 }
523 512
524 void GrGpu::releaseIndexArray() { 513 void GrGpu::releaseIndexArray() {
525 // if index source was array, we stowed data in the pool 514 // if index source was array, we stowed data in the pool
526 const GeometrySrcState& geoSrc = this->getGeomSrc(); 515 const GeometrySrcState& geoSrc = this->getGeomSrc();
527 SkASSERT(kArray_GeometrySrcType == geoSrc.fIndexSrc); 516 SkASSERT(kArray_GeometrySrcType == geoSrc.fIndexSrc);
528 size_t bytes = geoSrc.fIndexCount * sizeof(uint16_t); 517 size_t bytes = geoSrc.fIndexCount * sizeof(uint16_t);
529 fIndexPool->putBack(bytes); 518 fIndexPool->putBack(bytes);
530 --fIndexPoolUseCnt; 519 --fIndexPoolUseCnt;
531 } 520 }
OLDNEW
« no previous file with comments | « src/gpu/GrGpu.h ('k') | src/gpu/GrPathRendering.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698