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

Side by Side Diff: src/shared/ppapi_proxy/plugin_ppb_gles_extensions.cc

Issue 6579023: Added PPB_GLESChromiumTextureMapping interface. (Closed) Base URL: svn://svn.chromium.org/native_client/trunk/src/native_client
Patch Set: Created 9 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
OLDNEW
(Empty)
1 // Copyright (c) 2010 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
4
5 #include "native_client/src/shared/ppapi_proxy/plugin_ppb_gles_extensions.h"
6
7 #include "gpu/command_buffer/client/gles2_implementation.h"
8 #include "native_client/src/shared/ppapi_proxy/plugin_context_3d.h"
9
10 namespace ppapi_proxy {
11
12 namespace GLESChromiumTextureMapping {
13
14 namespace {
15
16 void* MapTexSubImage2DCHROMIUM(
17 PP_Resource context_id,
18 GLenum target,
19 GLint level,
20 GLint xoffset,
21 GLint yoffset,
22 GLsizei width,
23 GLsizei height,
24 GLenum format,
25 GLenum type,
26 GLenum access) {
27 return PluginResource::GetAs<PluginContext3D>(context_id)->impl()->
28 MapTexSubImage2DCHROMIUM(target, level, xoffset, yoffset, width, height,
29 format, type, access);
30 }
31
32 void UnmapTexSubImage2DCHROMIUM(PP_Resource context_id, const void* mem) {
33 PluginResource::GetAs<PluginContext3D>(context_id)->impl()->
34 UnmapTexSubImage2DCHROMIUM(mem);
35 }
36
37 } // namespace
38
39 const PPB_GLESChromiumTextureMapping_Dev* GetInterface() {
40 static const struct PPB_GLESChromiumTextureMapping_Dev interface_functions = {
41 &MapTexSubImage2DCHROMIUM,
42 &UnmapTexSubImage2DCHROMIUM
43 };
44 return &interface_functions;
45 }
46
47 } // namespace GLESChromiumTextureMapping
48
49 } // namespace ppapi_proxy
50
OLDNEW
« src/shared/ppapi_proxy/plugin_ppb.cc ('K') | « src/shared/ppapi_proxy/plugin_ppb_gles_extensions.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698