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

Unified Diff: src/gpu/GrGpu.cpp

Issue 1728093005: Move Budgeted enum out of SkSurface, use in GrTextureProvider (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: add aliases for Chrome Created 4 years, 10 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 | « src/gpu/GrGpu.h ('k') | src/gpu/GrGpuResource.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/gpu/GrGpu.cpp
diff --git a/src/gpu/GrGpu.cpp b/src/gpu/GrGpu.cpp
index 4fcd4d57af0a23b7f7c316c813fd7c25b942db38..8548e54a17121588eaddef0d57a0abe1796ed1e7 100644
--- a/src/gpu/GrGpu.cpp
+++ b/src/gpu/GrGpu.cpp
@@ -88,7 +88,7 @@ static GrSurfaceOrigin resolve_origin(GrSurfaceOrigin origin, bool renderTarget)
}
}
-GrTexture* GrGpu::createTexture(const GrSurfaceDesc& origDesc, bool budgeted,
+GrTexture* GrGpu::createTexture(const GrSurfaceDesc& origDesc, SkBudgeted budgeted,
const void* srcData, size_t rowBytes) {
GrSurfaceDesc desc = origDesc;
@@ -120,8 +120,9 @@ GrTexture* GrGpu::createTexture(const GrSurfaceDesc& origDesc, bool budgeted,
}
}
- GrGpuResource::LifeCycle lifeCycle = budgeted ? GrGpuResource::kCached_LifeCycle :
- GrGpuResource::kUncached_LifeCycle;
+ GrGpuResource::LifeCycle lifeCycle = SkBudgeted::kYes == budgeted ?
+ GrGpuResource::kCached_LifeCycle :
+ GrGpuResource::kUncached_LifeCycle;
desc.fSampleCnt = SkTMin(desc.fSampleCnt, this->caps()->maxSampleCount());
// Attempt to catch un- or wrongly initialized sample counts;
« no previous file with comments | « src/gpu/GrGpu.h ('k') | src/gpu/GrGpuResource.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698