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

Unified Diff: dm/DMGpuSupport.h

Issue 319043005: Support using OpenGL ES context on desktop (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: add docs Created 6 years, 6 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
Index: dm/DMGpuSupport.h
diff --git a/dm/DMGpuSupport.h b/dm/DMGpuSupport.h
index 46896b43217f91b623a494b55f437dfa510d03bf..bcc00c27e46454c123821b7962fff3d196a5c078 100644
--- a/dm/DMGpuSupport.h
+++ b/dm/DMGpuSupport.h
@@ -19,9 +19,10 @@ static const bool kGPUDisabled = false;
static inline SkSurface* NewGpuSurface(GrContextFactory* grFactory,
GrContextFactory::GLContextType type,
+ GrGLStandard gpuAPI,
SkImageInfo info,
int samples) {
- return SkSurface::NewRenderTarget(grFactory->get(type), info, samples);
+ return SkSurface::NewRenderTarget(grFactory->get(type, gpuAPI), info, samples);
}
} // namespace DM
@@ -30,6 +31,12 @@ static inline SkSurface* NewGpuSurface(GrContextFactory* grFactory,
// Ganesh is not available. Fake it.
+enum GrGLStandard {
+ kNone_GrGLStandard,
+ kGL_GrGLStandard,
+ kGLES_GrGLStandard
+};
+
class GrContextFactory {
public:
typedef int GLContextType;
@@ -48,6 +55,7 @@ static const bool kGPUDisabled = true;
static inline SkSurface* NewGpuSurface(GrContextFactory*,
GrContextFactory::GLContextType,
+ GrGLStandard,
SkImageInfo,
int) {
return NULL;

Powered by Google App Engine
This is Rietveld 408576698