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

Side by Side Diff: ppapi/native_client/src/shared/ppapi_proxy/plugin_ppb_graphics_3d.h

Issue 9420017: Add Pepper support for several GL extensions (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: fix build_gles2_cmd_buffer Created 8 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 unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « ppapi/native_client/src/shared/ppapi_proxy/plugin_ppb.cc ('k') | ppapi/ppapi_shared.gypi » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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 NATIVE_CLIENT_SRC_SHARED_PPAPI_PROXY_PLUGIN_PPB_GRAPHICS_3D_H_ 5 #ifndef NATIVE_CLIENT_SRC_SHARED_PPAPI_PROXY_PLUGIN_PPB_GRAPHICS_3D_H_
6 #define NATIVE_CLIENT_SRC_SHARED_PPAPI_PROXY_PLUGIN_PPB_GRAPHICS_3D_H_ 6 #define NATIVE_CLIENT_SRC_SHARED_PPAPI_PROXY_PLUGIN_PPB_GRAPHICS_3D_H_
7 7
8 #include "base/memory/scoped_ptr.h" 8 #include "base/memory/scoped_ptr.h"
9 #include "native_client/src/include/nacl_macros.h" 9 #include "native_client/src/include/nacl_macros.h"
10 #include "native_client/src/shared/ppapi_proxy/plugin_resource.h" 10 #include "native_client/src/shared/ppapi_proxy/plugin_resource.h"
11 #include "ppapi/c/pp_graphics_3d.h" 11 #include "ppapi/c/pp_graphics_3d.h"
12 #include "ppapi/c/ppb_graphics_3d.h" 12 #include "ppapi/c/ppb_graphics_3d.h"
13 #include "ppapi/c/ppb_opengles2.h" 13 #include "ppapi/c/ppb_opengles2.h"
14 #include "ppapi/c/dev/ppb_opengles2ext_dev.h"
14 #include "ppapi/c/pp_instance.h" 15 #include "ppapi/c/pp_instance.h"
15 16
16 namespace gpu { 17 namespace gpu {
17 class CommandBuffer; 18 class CommandBuffer;
18 class TransferBuffer; 19 class TransferBuffer;
19 namespace gles2 { 20 namespace gles2 {
20 class GLES2CmdHelper; 21 class GLES2CmdHelper;
21 class GLES2Implementation; 22 class GLES2Implementation;
22 } // namespace gles2 23 } // namespace gles2
23 } // namespace gpu 24 } // namespace gpu
24 25
25 namespace ppapi_proxy { 26 namespace ppapi_proxy {
26 27
27 // Implements the plugin (i.e., .nexe) side of the PPB_Graphics3D interface. 28 // Implements the plugin (i.e., .nexe) side of the PPB_Graphics3D interface.
28 class PluginGraphics3D : public PluginResource { 29 class PluginGraphics3D : public PluginResource {
29 public: 30 public:
30 PluginGraphics3D(); 31 PluginGraphics3D();
31 virtual ~PluginGraphics3D(); 32 virtual ~PluginGraphics3D();
32 33
33 static const PPB_Graphics3D* GetInterface(); 34 static const PPB_Graphics3D* GetInterface();
34 static const PPB_OpenGLES2* GetOpenGLESInterface(); 35 static const PPB_OpenGLES2* GetOpenGLESInterface();
36 static const PPB_OpenGLES2InstancedArrays_Dev*
37 GetOpenGLESInstancedArraysInterface();
38 static const PPB_OpenGLES2FramebufferBlit_Dev*
39 GetOpenGLESFramebufferBlitInterface();
40 static const PPB_OpenGLES2FramebufferMultisample_Dev*
41 GetOpenGLESFramebufferMultisampleInterface();
42 static const PPB_OpenGLES2ChromiumEnableFeature_Dev*
43 GetOpenGLESChromiumEnableFeatureInterface();
44 static const PPB_OpenGLES2ChromiumMapSub_Dev*
45 GetOpenGLESChromiumMapSubInterface();
35 46
36 virtual bool InitFromBrowserResource(PP_Resource graphics3d_id); 47 virtual bool InitFromBrowserResource(PP_Resource graphics3d_id);
37 48
38 gpu::gles2::GLES2Implementation* impl() { 49 gpu::gles2::GLES2Implementation* impl() {
39 return gles2_implementation_.get(); 50 return gles2_implementation_.get();
40 } 51 }
41 52
42 int32_t SwapBuffers(PP_Resource graphics3d_id, 53 int32_t SwapBuffers(PP_Resource graphics3d_id,
43 struct PP_CompletionCallback callback); 54 struct PP_CompletionCallback callback);
44 55
(...skipping 26 matching lines...) Expand all
71 static gpu::gles2::GLES2Implementation* implFromResourceSlow( 82 static gpu::gles2::GLES2Implementation* implFromResourceSlow(
72 PP_Resource context); 83 PP_Resource context);
73 84
74 IMPLEMENT_RESOURCE(PluginGraphics3D); 85 IMPLEMENT_RESOURCE(PluginGraphics3D);
75 NACL_DISALLOW_COPY_AND_ASSIGN(PluginGraphics3D); 86 NACL_DISALLOW_COPY_AND_ASSIGN(PluginGraphics3D);
76 }; 87 };
77 88
78 } // namespace ppapi_proxy 89 } // namespace ppapi_proxy
79 90
80 #endif // NATIVE_CLIENT_SRC_SHARED_PPAPI_PROXY_PLUGIN_PPB_GRAPHICS_3D_H_ 91 #endif // NATIVE_CLIENT_SRC_SHARED_PPAPI_PROXY_PLUGIN_PPB_GRAPHICS_3D_H_
OLDNEW
« no previous file with comments | « ppapi/native_client/src/shared/ppapi_proxy/plugin_ppb.cc ('k') | ppapi/ppapi_shared.gypi » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698