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

Unified Diff: src/gpu/GrContext.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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « include/gpu/GrSurface.h ('k') | src/gpu/GrGeometryBuffer.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/gpu/GrContext.cpp
diff --git a/src/gpu/GrContext.cpp b/src/gpu/GrContext.cpp
index d3edd21e5f40ea22de774c72c06b9bb8d5c9686f..c17144644018add3af3a9f4146dee8263b59db10 100755
--- a/src/gpu/GrContext.cpp
+++ b/src/gpu/GrContext.cpp
@@ -257,7 +257,7 @@ GrTexture* GrContext::findAndRefTexture(const GrTextureDesc& desc,
const GrCacheID& cacheID,
const GrTextureParams* params) {
GrResourceKey resourceKey = GrTextureImpl::ComputeKey(fGpu, params, desc, cacheID);
- GrGpuObject* resource = fResourceCache->find(resourceKey);
+ GrGpuResource* resource = fResourceCache->find(resourceKey);
SkSafeRef(resource);
return static_cast<GrTexture*>(resource);
}
@@ -283,7 +283,7 @@ GrStencilBuffer* GrContext::findStencilBuffer(int width, int height,
GrResourceKey resourceKey = GrStencilBuffer::ComputeKey(width,
height,
sampleCnt);
- GrGpuObject* resource = fResourceCache->find(resourceKey);
+ GrGpuResource* resource = fResourceCache->find(resourceKey);
return static_cast<GrStencilBuffer*>(resource);
}
@@ -471,7 +471,7 @@ GrTexture* GrContext::lockAndRefScratchTexture(const GrTextureDesc& inDesc, Scra
desc.fHeight = SkTMax(MIN_SIZE, GrNextPow2(desc.fHeight));
}
- GrGpuObject* resource = NULL;
+ GrGpuResource* resource = NULL;
int origWidth = desc.fWidth;
int origHeight = desc.fHeight;
@@ -1903,13 +1903,13 @@ GrPath* GrContext::createPath(const SkPath& inPath, const SkStrokeRec& stroke) {
return path;
}
-void GrContext::addResourceToCache(const GrResourceKey& resourceKey, GrGpuObject* resource) {
+void GrContext::addResourceToCache(const GrResourceKey& resourceKey, GrGpuResource* resource) {
fResourceCache->purgeAsNeeded(1, resource->gpuMemorySize());
fResourceCache->addResource(resourceKey, resource);
}
-GrGpuObject* GrContext::findAndRefCachedResource(const GrResourceKey& resourceKey) {
- GrGpuObject* resource = fResourceCache->find(resourceKey);
+GrGpuResource* GrContext::findAndRefCachedResource(const GrResourceKey& resourceKey) {
+ GrGpuResource* resource = fResourceCache->find(resourceKey);
SkSafeRef(resource);
return resource;
}
« no previous file with comments | « include/gpu/GrSurface.h ('k') | src/gpu/GrGeometryBuffer.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698