| OLD | NEW |
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #ifndef CONTENT_RENDERER_PEPPER_CONTENT_DECRYPTOR_DELEGATE_H_ | 5 #ifndef CONTENT_RENDERER_PEPPER_CONTENT_DECRYPTOR_DELEGATE_H_ |
| 6 #define CONTENT_RENDERER_PEPPER_CONTENT_DECRYPTOR_DELEGATE_H_ | 6 #define CONTENT_RENDERER_PEPPER_CONTENT_DECRYPTOR_DELEGATE_H_ |
| 7 | 7 |
| 8 #include <map> | 8 #include <map> |
| 9 #include <queue> | 9 #include <queue> |
| 10 #include <string> | 10 #include <string> |
| (...skipping 84 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 95 bool DecryptAndDecodeAudio( | 95 bool DecryptAndDecodeAudio( |
| 96 const scoped_refptr<media::DecoderBuffer>& encrypted_buffer, | 96 const scoped_refptr<media::DecoderBuffer>& encrypted_buffer, |
| 97 const media::Decryptor::AudioDecodeCB& audio_decode_cb); | 97 const media::Decryptor::AudioDecodeCB& audio_decode_cb); |
| 98 bool DecryptAndDecodeVideo( | 98 bool DecryptAndDecodeVideo( |
| 99 const scoped_refptr<media::DecoderBuffer>& encrypted_buffer, | 99 const scoped_refptr<media::DecoderBuffer>& encrypted_buffer, |
| 100 const media::Decryptor::VideoDecodeCB& video_decode_cb); | 100 const media::Decryptor::VideoDecodeCB& video_decode_cb); |
| 101 | 101 |
| 102 // PPB_ContentDecryptor_Private dispatching methods. | 102 // PPB_ContentDecryptor_Private dispatching methods. |
| 103 void OnPromiseResolved(uint32 promise_id); | 103 void OnPromiseResolved(uint32 promise_id); |
| 104 void OnPromiseResolvedWithSession(uint32 promise_id, PP_Var web_session_id); | 104 void OnPromiseResolvedWithSession(uint32 promise_id, PP_Var web_session_id); |
| 105 void OnPromiseResolvedWithKeyIds(uint32 promise_id, PP_Var key_ids_array); | |
| 106 void OnPromiseRejected(uint32 promise_id, | 105 void OnPromiseRejected(uint32 promise_id, |
| 107 PP_CdmExceptionCode exception_code, | 106 PP_CdmExceptionCode exception_code, |
| 108 uint32 system_code, | 107 uint32 system_code, |
| 109 PP_Var error_description); | 108 PP_Var error_description); |
| 110 void OnSessionMessage(PP_Var web_session_id, | 109 void OnSessionMessage(PP_Var web_session_id, |
| 111 PP_Var message, | 110 PP_CdmMessageType message_type, |
| 112 PP_Var destination_url); | 111 PP_Var message); |
| 113 void OnSessionKeysChange(PP_Var web_session_id, | 112 void OnSessionKeysChange(PP_Var web_session_id, |
| 114 PP_Bool has_additional_usable_key); | 113 PP_Bool has_additional_usable_key, |
| 114 uint32_t key_count, |
| 115 const struct PP_KeyInformation key_information[]); |
| 115 void OnSessionExpirationChange(PP_Var web_session_id, | 116 void OnSessionExpirationChange(PP_Var web_session_id, |
| 116 PP_Time new_expiry_time); | 117 PP_Time new_expiry_time); |
| 117 void OnSessionReady(PP_Var web_session_id); | |
| 118 void OnSessionClosed(PP_Var web_session_id); | 118 void OnSessionClosed(PP_Var web_session_id); |
| 119 void OnSessionError(PP_Var web_session_id, | 119 void OnSessionError(PP_Var web_session_id, |
| 120 PP_CdmExceptionCode exception_code, | 120 PP_CdmExceptionCode exception_code, |
| 121 uint32 system_code, | 121 uint32 system_code, |
| 122 PP_Var error_description); | 122 PP_Var error_description); |
| 123 void DeliverBlock(PP_Resource decrypted_block, | 123 void DeliverBlock(PP_Resource decrypted_block, |
| 124 const PP_DecryptedBlockInfo* block_info); | 124 const PP_DecryptedBlockInfo* block_info); |
| 125 void DecoderInitializeDone(PP_DecryptorStreamType decoder_type, | 125 void DecoderInitializeDone(PP_DecryptorStreamType decoder_type, |
| 126 uint32_t request_id, | 126 uint32_t request_id, |
| 127 PP_Bool success); | 127 PP_Bool success); |
| (...skipping 130 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 258 | 258 |
| 259 base::WeakPtr<ContentDecryptorDelegate> weak_this_; | 259 base::WeakPtr<ContentDecryptorDelegate> weak_this_; |
| 260 base::WeakPtrFactory<ContentDecryptorDelegate> weak_ptr_factory_; | 260 base::WeakPtrFactory<ContentDecryptorDelegate> weak_ptr_factory_; |
| 261 | 261 |
| 262 DISALLOW_COPY_AND_ASSIGN(ContentDecryptorDelegate); | 262 DISALLOW_COPY_AND_ASSIGN(ContentDecryptorDelegate); |
| 263 }; | 263 }; |
| 264 | 264 |
| 265 } // namespace content | 265 } // namespace content |
| 266 | 266 |
| 267 #endif // CONTENT_RENDERER_PEPPER_CONTENT_DECRYPTOR_DELEGATE_H_ | 267 #endif // CONTENT_RENDERER_PEPPER_CONTENT_DECRYPTOR_DELEGATE_H_ |
| OLD | NEW |