Chromium Code Reviews| OLD | NEW |
|---|---|
| 1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 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 MEDIA_BLINK_ENCRYPTED_MEDIA_PLAYER_SUPPORT_H_ | 5 #ifndef MEDIA_BLINK_ENCRYPTED_MEDIA_PLAYER_SUPPORT_H_ |
| 6 #define MEDIA_BLINK_ENCRYPTED_MEDIA_PLAYER_SUPPORT_H_ | 6 #define MEDIA_BLINK_ENCRYPTED_MEDIA_PLAYER_SUPPORT_H_ |
| 7 | 7 |
| 8 #include <string> | 8 #include <string> |
| 9 #include <vector> | 9 #include <vector> |
| 10 | 10 |
| (...skipping 19 matching lines...) Expand all Loading... | |
| 30 | 30 |
| 31 class MediaPermission; | 31 class MediaPermission; |
| 32 class WebContentDecryptionModuleImpl; | 32 class WebContentDecryptionModuleImpl; |
| 33 | 33 |
| 34 // Provides support to prefixed EME implementation. | 34 // Provides support to prefixed EME implementation. |
| 35 // Do NOT add unprefixed EME functionality to this class! | 35 // Do NOT add unprefixed EME functionality to this class! |
| 36 // TODO(xhwang): When deprecating prefixed EME support, drop this whole file. | 36 // TODO(xhwang): When deprecating prefixed EME support, drop this whole file. |
| 37 class EncryptedMediaPlayerSupport | 37 class EncryptedMediaPlayerSupport |
| 38 : public base::SupportsWeakPtr<EncryptedMediaPlayerSupport> { | 38 : public base::SupportsWeakPtr<EncryptedMediaPlayerSupport> { |
| 39 public: | 39 public: |
| 40 typedef base::Callback<void(CdmContext*, const CdmAttachedCB&)> | 40 using SetCdmContextCB = ProxyDecryptor::SetCdmContextCB; |
| 41 SetCdmContextCB; | |
| 42 | 41 |
| 42 // |set_cdm_context_cb| is called when the real CDM is created successfully. | |
|
ddorwin
2015/04/10 00:59:43
"real"? Is there a fake/stub/temporary one?
"CDM
xhwang
2015/04/10 17:41:17
Done.
| |
| 43 EncryptedMediaPlayerSupport(CdmFactory* cdm_factory, | 43 EncryptedMediaPlayerSupport(CdmFactory* cdm_factory, |
| 44 blink::WebMediaPlayerClient* client, | 44 blink::WebMediaPlayerClient* client, |
| 45 MediaPermission* media_permission, | 45 MediaPermission* media_permission, |
| 46 const SetCdmContextCB& set_cdm_context_cb); | 46 const SetCdmContextCB& set_cdm_context_cb); |
| 47 ~EncryptedMediaPlayerSupport(); | 47 ~EncryptedMediaPlayerSupport(); |
| 48 | 48 |
| 49 blink::WebMediaPlayer::MediaKeyException GenerateKeyRequest( | 49 blink::WebMediaPlayer::MediaKeyException GenerateKeyRequest( |
| 50 blink::WebLocalFrame* frame, | 50 blink::WebLocalFrame* frame, |
| 51 const blink::WebString& key_system, | 51 const blink::WebString& key_system, |
| 52 const unsigned char* init_data, | 52 const unsigned char* init_data, |
| (...skipping 60 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 113 | 113 |
| 114 // Manages decryption keys and decrypts encrypted frames. | 114 // Manages decryption keys and decrypts encrypted frames. |
| 115 scoped_ptr<ProxyDecryptor> proxy_decryptor_; | 115 scoped_ptr<ProxyDecryptor> proxy_decryptor_; |
| 116 | 116 |
| 117 DISALLOW_COPY_AND_ASSIGN(EncryptedMediaPlayerSupport); | 117 DISALLOW_COPY_AND_ASSIGN(EncryptedMediaPlayerSupport); |
| 118 }; | 118 }; |
| 119 | 119 |
| 120 } // namespace media | 120 } // namespace media |
| 121 | 121 |
| 122 #endif // MEDIA_BLINK_ENCRYPTED_MEDIA_PLAYER_SUPPORT_H_ | 122 #endif // MEDIA_BLINK_ENCRYPTED_MEDIA_PLAYER_SUPPORT_H_ |
| OLD | NEW |