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

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

Issue 418143004: Rename GrGpuObject to GrGpuResource (Closed) Base URL: https://skia.googlesource.com/skia.git@compact
Patch Set: Fix indents Created 6 years, 5 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/GrGpuObject.cpp » ('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 67 matching lines...) Expand 10 before | Expand all | Expand 10 after
78 } 78 }
79 79
80 SkASSERT(NULL == fQuadIndexBuffer || fQuadIndexBuffer->wasDestroyed()); 80 SkASSERT(NULL == fQuadIndexBuffer || fQuadIndexBuffer->wasDestroyed());
81 SkSafeSetNull(fQuadIndexBuffer); 81 SkSafeSetNull(fQuadIndexBuffer);
82 delete fVertexPool; 82 delete fVertexPool;
83 fVertexPool = NULL; 83 fVertexPool = NULL;
84 delete fIndexPool; 84 delete fIndexPool;
85 fIndexPool = NULL; 85 fIndexPool = NULL;
86 } 86 }
87 87
88 void GrGpu::insertObject(GrGpuObject* object) { 88 void GrGpu::insertObject(GrGpuResource* object) {
89 SkASSERT(NULL != object); 89 SkASSERT(NULL != object);
90 SkASSERT(this == object->getGpu()); 90 SkASSERT(this == object->getGpu());
91 91
92 fObjectList.addToHead(object); 92 fObjectList.addToHead(object);
93 } 93 }
94 94
95 void GrGpu::removeObject(GrGpuObject* object) { 95 void GrGpu::removeObject(GrGpuResource* object) {
96 SkASSERT(NULL != object); 96 SkASSERT(NULL != object);
97 SkASSERT(this == object->getGpu()); 97 SkASSERT(this == object->getGpu());
98 98
99 fObjectList.remove(object); 99 fObjectList.remove(object);
100 } 100 }
101 101
102 102
103 void GrGpu::unimpl(const char msg[]) { 103 void GrGpu::unimpl(const char msg[]) {
104 #ifdef SK_DEBUG 104 #ifdef SK_DEBUG
105 GrPrintf("--- GrGpu unimplemented(\"%s\")\n", msg); 105 GrPrintf("--- GrGpu unimplemented(\"%s\")\n", msg);
(...skipping 465 matching lines...) Expand 10 before | Expand all | Expand 10 after
571 } 571 }
572 572
573 void GrGpu::releaseIndexArray() { 573 void GrGpu::releaseIndexArray() {
574 // if index source was array, we stowed data in the pool 574 // if index source was array, we stowed data in the pool
575 const GeometrySrcState& geoSrc = this->getGeomSrc(); 575 const GeometrySrcState& geoSrc = this->getGeomSrc();
576 SkASSERT(kArray_GeometrySrcType == geoSrc.fIndexSrc); 576 SkASSERT(kArray_GeometrySrcType == geoSrc.fIndexSrc);
577 size_t bytes = geoSrc.fIndexCount * sizeof(uint16_t); 577 size_t bytes = geoSrc.fIndexCount * sizeof(uint16_t);
578 fIndexPool->putBack(bytes); 578 fIndexPool->putBack(bytes);
579 --fIndexPoolUseCnt; 579 --fIndexPoolUseCnt;
580 } 580 }
OLDNEW
« no previous file with comments | « src/gpu/GrGpu.h ('k') | src/gpu/GrGpuObject.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698