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

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

Issue 7545014: Implement PPAPI VideoDecode out-of-process support (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: responses to ddorwin and piman Created 9 years, 5 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
Index: webkit/plugins/ppapi/ppb_video_decoder_impl.h
diff --git a/webkit/plugins/ppapi/ppb_video_decoder_impl.h b/webkit/plugins/ppapi/ppb_video_decoder_impl.h
index 2347c4b84c29246f98a056d7d4a5a4487bedac96..24c703b23eddbca8f794fc274d0727071065f016 100644
--- a/webkit/plugins/ppapi/ppb_video_decoder_impl.h
+++ b/webkit/plugins/ppapi/ppb_video_decoder_impl.h
@@ -13,6 +13,7 @@
#include "base/memory/scoped_ptr.h"
#include "ppapi/c/dev/pp_video_dev.h"
#include "ppapi/c/pp_var.h"
+#include "ppapi/shared_impl/video_decoder_impl.h"
#include "ppapi/thunk/ppb_video_decoder_api.h"
#include "webkit/plugins/ppapi/plugin_delegate.h"
#include "webkit/plugins/ppapi/resource.h"
@@ -35,7 +36,7 @@ namespace ppapi {
class PluginInstance;
class PPB_VideoDecoder_Impl : public Resource,
- public ::ppapi::thunk::PPB_VideoDecoder_API,
+ public ::ppapi::VideoDecoderImpl,
public media::VideoDecodeAccelerator::Client {
public:
virtual ~PPB_VideoDecoder_Impl();
@@ -71,44 +72,20 @@ class PPB_VideoDecoder_Impl : public Resource,
virtual void NotifyEndOfBitstreamBuffer(int32 buffer_id) OVERRIDE;
virtual void NotifyResetDone() OVERRIDE;
- private:
- // Key: bitstream_buffer_id, value: callback to run when bitstream decode is
- // done.
- typedef std::map<int32, PP_CompletionCallback> CallbackById;
-
- explicit PPB_VideoDecoder_Impl(PluginInstance* instance);
-
// Initialize the underlying decoder and return success status.
Ami GONE FROM CHROMIUM 2011/08/02 00:49:08 s/public/protected/?
vrk (LEFT CHROMIUM) 2011/08/03 19:04:30 Done.
- bool Init(PP_Resource context_id, const PP_VideoConfigElement* dec_config);
+ virtual bool Init(PP_Resource context_id,
+ const PP_VideoConfigElement* dec_config);
Ami GONE FROM CHROMIUM 2011/08/02 00:49:08 OVERRIDE
vrk (LEFT CHROMIUM) 2011/08/03 19:04:30 Done.
- // Tell command buffer to process all commands it has received so far.
- void FlushCommandBuffer();
+ private:
+ explicit PPB_VideoDecoder_Impl(PluginInstance* instance);
// This is NULL before initialization, and if this PPB_VideoDecoder_Impl is
// swapped with another.
scoped_refptr<PluginDelegate::PlatformVideoDecoder> platform_video_decoder_;
- // Factory to produce our callbacks.
- base::ScopedCallbackFactory<PPB_VideoDecoder_Impl> callback_factory_;
-
- // The resource ID of the underlying Context3d object being used. Used only
- // for reference counting to keep it alive for the lifetime of |*this|.
- PP_Resource context3d_id_;
-
- PP_CompletionCallback flush_callback_;
- PP_CompletionCallback reset_callback_;
- CallbackById bitstream_buffer_callbacks_;
-
// Reference to the plugin requesting this interface.
const PPP_VideoDecoder_Dev* ppp_videodecoder_;
- // Reference to the GLES2Implementation owned by PPB_Context3D_Impl.
- // PPB_Context3D_Impl is guaranteed to be alive for the lifetime of this
- // class.
- // In the out-of-process case, Context3D's gles2_impl() exists in the plugin
- // process only, so gles2_impl_ is NULL in that case.
- gpu::gles2::GLES2Implementation* gles2_impl_;
-
DISALLOW_COPY_AND_ASSIGN(PPB_VideoDecoder_Impl);
};

Powered by Google App Engine
This is Rietveld 408576698