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

Unified Diff: ppapi/thunk/ppb_graphics_3d_thunk.cc

Issue 7824040: Pepper 3D API changes: (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: '' Created 9 years, 4 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 | « ppapi/thunk/ppb_graphics_3d_api.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ppapi/thunk/ppb_graphics_3d_thunk.cc
===================================================================
--- ppapi/thunk/ppb_graphics_3d_thunk.cc (revision 99369)
+++ ppapi/thunk/ppb_graphics_3d_thunk.cc (working copy)
@@ -17,6 +17,13 @@
typedef EnterResource<PPB_Graphics3D_API> EnterGraphics3D;
+int32_t GetAttribMaxValue(PP_Resource instance,
+ int32_t attribute,
+ int32_t* value) {
+ // TODO(alokp): Implement me.
+ return PP_ERROR_FAILED;
+}
+
PP_Resource Create(PP_Instance instance,
PP_Resource share_context,
const int32_t* attrib_list) {
@@ -46,6 +53,14 @@
return enter.object()->SetAttribs(attrib_list);
}
+int32_t GetError(PP_Resource graphics_3d) {
+ EnterGraphics3D enter(graphics_3d, true);
+ if (enter.failed())
+ return PP_ERROR_BADRESOURCE;
+
+ return enter.object()->GetError();
+}
+
int32_t ResizeBuffers(PP_Resource graphics_3d, int32_t width, int32_t height) {
EnterGraphics3D enter(graphics_3d, true);
if (enter.failed())
@@ -62,10 +77,12 @@
}
const PPB_Graphics3D_Dev g_ppb_graphics_3d_thunk = {
+ &GetAttribMaxValue,
&Create,
&IsGraphics3D,
&GetAttribs,
&SetAttribs,
+ &GetError,
&ResizeBuffers,
&SwapBuffers
};
« no previous file with comments | « ppapi/thunk/ppb_graphics_3d_api.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698