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 PPAPI_CPP_PRIVATE_CONTENT_DECRYPTOR_PRIVATE_H_ | 5 #ifndef PPAPI_CPP_PRIVATE_CONTENT_DECRYPTOR_PRIVATE_H_ |
6 #define PPAPI_CPP_PRIVATE_CONTENT_DECRYPTOR_PRIVATE_H_ | 6 #define PPAPI_CPP_PRIVATE_CONTENT_DECRYPTOR_PRIVATE_H_ |
7 | 7 |
8 #include "ppapi/c/private/pp_content_decryptor.h" | 8 #include "ppapi/c/private/pp_content_decryptor.h" |
9 #include "ppapi/c/private/ppb_content_decryptor_private.h" | 9 #include "ppapi/c/private/ppb_content_decryptor_private.h" |
10 #include "ppapi/c/private/ppp_content_decryptor_private.h" | 10 #include "ppapi/c/private/ppp_content_decryptor_private.h" |
(...skipping 45 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
56 virtual void DecryptAndDecode( | 56 virtual void DecryptAndDecode( |
57 PP_DecryptorStreamType decoder_type, | 57 PP_DecryptorStreamType decoder_type, |
58 pp::Buffer_Dev encrypted_buffer, | 58 pp::Buffer_Dev encrypted_buffer, |
59 const PP_EncryptedBlockInfo& encrypted_block_info) = 0; | 59 const PP_EncryptedBlockInfo& encrypted_block_info) = 0; |
60 | 60 |
61 // PPB_ContentDecryptor_Private methods for passing data from the decryptor | 61 // PPB_ContentDecryptor_Private methods for passing data from the decryptor |
62 // to the browser. | 62 // to the browser. |
63 void SessionCreated(uint32_t session_id, const std::string& web_session_id); | 63 void SessionCreated(uint32_t session_id, const std::string& web_session_id); |
64 void SessionMessage(uint32_t session_id, | 64 void SessionMessage(uint32_t session_id, |
65 pp::VarArrayBuffer message, | 65 pp::VarArrayBuffer message, |
66 const std::string& default_url); | 66 const std::string& destination_url); |
67 void SessionReady(uint32_t session_id); | 67 void SessionReady(uint32_t session_id); |
68 void SessionClosed(uint32_t session_id); | 68 void SessionClosed(uint32_t session_id); |
69 void SessionError(uint32_t session_id, | 69 void SessionError(uint32_t session_id, |
70 int32_t media_error, | 70 int32_t media_error, |
71 uint32_t system_code); | 71 uint32_t system_code); |
72 | 72 |
73 // The plugin must not hold a reference to the encrypted buffer resource | 73 // The plugin must not hold a reference to the encrypted buffer resource |
74 // provided to Decrypt() when it calls this method. The browser will reuse | 74 // provided to Decrypt() when it calls this method. The browser will reuse |
75 // the buffer in a subsequent Decrypt() call. | 75 // the buffer in a subsequent Decrypt() call. |
76 void DeliverBlock(pp::Buffer_Dev decrypted_block, | 76 void DeliverBlock(pp::Buffer_Dev decrypted_block, |
(...skipping 19 matching lines...) Expand all Loading... |
96 void DeliverSamples(pp::Buffer_Dev audio_frames, | 96 void DeliverSamples(pp::Buffer_Dev audio_frames, |
97 const PP_DecryptedSampleInfo& decrypted_sample_info); | 97 const PP_DecryptedSampleInfo& decrypted_sample_info); |
98 | 98 |
99 private: | 99 private: |
100 InstanceHandle associated_instance_; | 100 InstanceHandle associated_instance_; |
101 }; | 101 }; |
102 | 102 |
103 } // namespace pp | 103 } // namespace pp |
104 | 104 |
105 #endif // PPAPI_CPP_PRIVATE_CONTENT_DECRYPTOR_PRIVATE_H_ | 105 #endif // PPAPI_CPP_PRIVATE_CONTENT_DECRYPTOR_PRIVATE_H_ |
OLD | NEW |