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

Side by Side Diff: gpu/command_buffer/client/gl_in_process_context.h

Issue 23660006: FeatureInfo: Remove allowed_extensions and init workarounds early (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: fix android_webview build Created 7 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 | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #ifndef GPU_COMMAND_BUFFER_CLIENT_GL_IN_PROCESS_CONTEXT_H_ 5 #ifndef GPU_COMMAND_BUFFER_CLIENT_GL_IN_PROCESS_CONTEXT_H_
6 #define GPU_COMMAND_BUFFER_CLIENT_GL_IN_PROCESS_CONTEXT_H_ 6 #define GPU_COMMAND_BUFFER_CLIENT_GL_IN_PROCESS_CONTEXT_H_
7 7
8 #include "base/callback.h" 8 #include "base/callback.h"
9 #include "base/compiler_specific.h" 9 #include "base/compiler_specific.h"
10 #include "gles2_impl_export.h" 10 #include "gles2_impl_export.h"
(...skipping 36 matching lines...) Expand 10 before | Expand all | Expand 10 after
47 virtual ~GLInProcessContext() {} 47 virtual ~GLInProcessContext() {}
48 48
49 // Create a GLInProcessContext, if |is_offscreen| is true, renders to an 49 // Create a GLInProcessContext, if |is_offscreen| is true, renders to an
50 // offscreen context. |attrib_list| must be NULL or a NONE-terminated list 50 // offscreen context. |attrib_list| must be NULL or a NONE-terminated list
51 // of attribute/value pairs. 51 // of attribute/value pairs.
52 static GLInProcessContext* CreateContext( 52 static GLInProcessContext* CreateContext(
53 bool is_offscreen, 53 bool is_offscreen,
54 gfx::AcceleratedWidget window, 54 gfx::AcceleratedWidget window,
55 const gfx::Size& size, 55 const gfx::Size& size,
56 bool share_resources, 56 bool share_resources,
57 const char* allowed_extensions,
58 const GLInProcessContextAttribs& attribs, 57 const GLInProcessContextAttribs& attribs,
59 gfx::GpuPreference gpu_preference); 58 gfx::GpuPreference gpu_preference);
60 59
61 // Create context with the provided GLSurface. All other arguments match 60 // Create context with the provided GLSurface. All other arguments match
62 // CreateContext factory above. Can only be called if the command buffer 61 // CreateContext factory above. Can only be called if the command buffer
63 // service runs on the same thread as this client because GLSurface is not 62 // service runs on the same thread as this client because GLSurface is not
64 // thread safe. 63 // thread safe.
65 static GLInProcessContext* CreateWithSurface( 64 static GLInProcessContext* CreateWithSurface(
66 scoped_refptr<gfx::GLSurface> surface, 65 scoped_refptr<gfx::GLSurface> surface,
67 bool share_resources, 66 bool share_resources,
68 const char* allowed_extensions,
69 const GLInProcessContextAttribs& attribs, 67 const GLInProcessContextAttribs& attribs,
70 gfx::GpuPreference gpu_preference); 68 gfx::GpuPreference gpu_preference);
71 69
72 virtual void SetContextLostCallback(const base::Closure& callback) = 0; 70 virtual void SetContextLostCallback(const base::Closure& callback) = 0;
73 71
74 virtual void SignalSyncPoint(unsigned sync_point, 72 virtual void SignalSyncPoint(unsigned sync_point,
75 const base::Closure& callback) = 0; 73 const base::Closure& callback) = 0;
76 74
77 virtual void SignalQuery(unsigned query, const base::Closure& callback) = 0; 75 virtual void SignalQuery(unsigned query, const base::Closure& callback) = 0;
78 76
79 // Allows direct access to the GLES2 implementation so a GLInProcessContext 77 // Allows direct access to the GLES2 implementation so a GLInProcessContext
80 // can be used without making it current. 78 // can be used without making it current.
81 virtual gles2::GLES2Implementation* GetImplementation() = 0; 79 virtual gles2::GLES2Implementation* GetImplementation() = 0;
82 80
83 #if defined(OS_ANDROID) 81 #if defined(OS_ANDROID)
84 virtual scoped_refptr<gfx::SurfaceTexture> GetSurfaceTexture( 82 virtual scoped_refptr<gfx::SurfaceTexture> GetSurfaceTexture(
85 uint32 stream_id) = 0; 83 uint32 stream_id) = 0;
86 #endif 84 #endif
87 }; 85 };
88 86
89 } // namespace gpu 87 } // namespace gpu
90 88
91 #endif // GPU_COMMAND_BUFFER_CLIENT_GL_IN_PROCESS_CONTEXT_H_ 89 #endif // GPU_COMMAND_BUFFER_CLIENT_GL_IN_PROCESS_CONTEXT_H_
OLDNEW
« no previous file with comments | « content/renderer/pepper/pepper_platform_context_3d.cc ('k') | gpu/command_buffer/client/gl_in_process_context.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698