Chromium Code Reviews| Index: webkit/plugins/ppapi/ppapi_plugin_instance.h |
| diff --git a/webkit/plugins/ppapi/ppapi_plugin_instance.h b/webkit/plugins/ppapi/ppapi_plugin_instance.h |
| index e5edb5950eafc347c5f74f31e564897c93e2e1d7..324c6036abe0176eef1d52382f29e84bc73bc68c 100644 |
| --- a/webkit/plugins/ppapi/ppapi_plugin_instance.h |
| +++ b/webkit/plugins/ppapi/ppapi_plugin_instance.h |
| @@ -263,19 +263,16 @@ class WEBKIT_PLUGINS_EXPORT PluginInstance : |
| bool CancelKeyRequest(const std::string& session_id); |
| bool Decrypt(const scoped_refptr<media::DecoderBuffer>& encrypted_buffer, |
| const media::Decryptor::DecryptCB& decrypt_cb); |
| - // TODO(xhwang): Change DecryptCB to a DecoderInitCB. |
| bool InitializeVideoDecoder( |
| const media::VideoDecoderConfig& decoder_config, |
| - const media::Decryptor::DecryptCB& decrypt_cb); |
| + const media::Decryptor::DecoderInitCB& decoder_init_cb); |
| // TODO(tomfinegan): Add callback args for DeinitializeDecoder() and |
| // ResetDecoder() |
| bool DeinitializeDecoder(); |
| bool ResetDecoder(); |
| - // TODO(xhwang): Update this when we need to support decrypt and decode. |
| - // Note: This method can be used with an unencrypted frame. |
| bool DecryptAndDecode( |
|
ddorwin
2012/10/13 01:40:28
"// Note: This method can be used with an unencryp
xhwang
2012/10/15 19:53:01
Done.
|
| const scoped_refptr<media::DecoderBuffer>& encrypted_buffer, |
| - const media::Decryptor::DecryptCB& decrypt_cb); |
| + const media::Decryptor::VideoDecodeCB& video_decode_cb); |
|
ddorwin
2012/10/13 01:40:28
What's the plan for audio? Will we have two CBs or
xhwang
2012/10/15 19:53:01
I guess I'll just rename so we have DecryptAndDeco
|
| // There are 2 implementations of the fullscreen interface |
| // PPB_FlashFullscreen is used by Pepper Flash. |
| @@ -780,10 +777,24 @@ class WEBKIT_PLUGINS_EXPORT PluginInstance : |
| scoped_refptr<PPB_URLLoader_Impl> document_loader_; |
| media::DecryptorClient* decryptor_client_; |
| + |
| + // Request ID for tracking pending content decryption callbacks. |
| + // Note that zero indicates an invalid request ID. |
| + // TODO(xhwang): Add completion callbacks for Reset/Stop and remove the use |
| + // of request IDs. |
| uint32_t next_decryption_request_id_; |
| + |
| + // TODO(xhwang): Use two separate callbacks for video and audio instead using |
| + // a map here. |
| typedef std::map<uint32_t, media::Decryptor::DecryptCB> DecryptionCBMap; |
| DecryptionCBMap pending_decryption_cbs_; |
| + uint32_t pending_video_decoder_init_request_id_; |
| + media::Decryptor::DecoderInitCB pending_video_decoder_init_cb_; |
| + |
| + uint32_t pending_video_decode_request_id_; |
| + media::Decryptor::VideoDecodeCB pending_video_decode_cb_; |
| + |
| DISALLOW_COPY_AND_ASSIGN(PluginInstance); |
| }; |