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

Unified Diff: webkit/plugins/ppapi/ppb_video_decoder_impl.cc

Issue 8676042: Remove Context3D/Surface3D (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: style Created 9 years, 1 month 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 | « webkit/plugins/ppapi/ppb_surface_3d_impl.cc ('k') | webkit/plugins/ppapi/resource_creation_impl.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: webkit/plugins/ppapi/ppb_video_decoder_impl.cc
diff --git a/webkit/plugins/ppapi/ppb_video_decoder_impl.cc b/webkit/plugins/ppapi/ppb_video_decoder_impl.cc
index b9e6da0b31dc97f94430131ef46ebb2d9021d75c..f108ecfba61b0b33e3891fbc817e98a5aa3ef174 100644
--- a/webkit/plugins/ppapi/ppb_video_decoder_impl.cc
+++ b/webkit/plugins/ppapi/ppb_video_decoder_impl.cc
@@ -21,13 +21,11 @@
#include "webkit/plugins/ppapi/plugin_module.h"
#include "webkit/plugins/ppapi/ppapi_plugin_instance.h"
#include "webkit/plugins/ppapi/ppb_buffer_impl.h"
-#include "webkit/plugins/ppapi/ppb_context_3d_impl.h"
#include "webkit/plugins/ppapi/ppb_graphics_3d_impl.h"
#include "webkit/plugins/ppapi/resource_helper.h"
using ppapi::thunk::EnterResourceNoLock;
using ppapi::thunk::PPB_Buffer_API;
-using ppapi::thunk::PPB_Context3D_API;
using ppapi::thunk::PPB_Graphics3D_API;
using ppapi::thunk::PPB_VideoDecoder_API;
@@ -64,28 +62,16 @@ PP_Resource PPB_VideoDecoder_Impl::Create(
PP_Instance instance,
PP_Resource graphics_context,
PP_VideoDecoder_Profile profile) {
- PluginDelegate::PlatformContext3D* platform_context = NULL;
- gpu::gles2::GLES2Implementation* gles2_impl = NULL;
- EnterResourceNoLock<PPB_Context3D_API> enter_context(graphics_context, false);
- if (enter_context.succeeded()) {
- PPB_Context3D_Impl* context3d_impl =
- static_cast<PPB_Context3D_Impl*>(enter_context.object());
- platform_context = context3d_impl->platform_context();
- gles2_impl = context3d_impl->gles2_impl();
- } else {
- EnterResourceNoLock<PPB_Graphics3D_API> enter_context(graphics_context,
- true);
- if (enter_context.failed())
- return 0;
- PPB_Graphics3D_Impl* graphics3d_impl =
- static_cast<PPB_Graphics3D_Impl*>(enter_context.object());
- platform_context = graphics3d_impl->platform_context();
- gles2_impl = graphics3d_impl->gles2_impl();
- }
+ EnterResourceNoLock<PPB_Graphics3D_API> enter_context(graphics_context, true);
+ if (enter_context.failed())
+ return 0;
+ PPB_Graphics3D_Impl* graphics3d_impl =
+ static_cast<PPB_Graphics3D_Impl*>(enter_context.object());
scoped_refptr<PPB_VideoDecoder_Impl> decoder(
new PPB_VideoDecoder_Impl(instance));
- if (decoder->Init(graphics_context, platform_context, gles2_impl, profile))
+ if (decoder->Init(graphics_context, graphics3d_impl->platform_context(),
+ graphics3d_impl->gles2_impl(), profile))
return decoder->GetReference();
return 0;
}
« no previous file with comments | « webkit/plugins/ppapi/ppb_surface_3d_impl.cc ('k') | webkit/plugins/ppapi/resource_creation_impl.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698