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

Side by Side Diff: content/renderer/media/crypto/encrypted_media_support.h

Issue 501473003: Move EME code out of WebMediaPlayerImpl. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Make lint happy Created 6 years, 4 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 unified diff | Download patch | Annotate | Revision Log
OLDNEW
(Empty)
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
3 // found in the LICENSE file.
4
5 #ifndef CONTENT_RENDERER_MEDIA_CRYPTO_ENCRYPTED_MEDIA_SUPPORT_H_
6 #define CONTENT_RENDERER_MEDIA_CRYPTO_ENCRYPTED_MEDIA_SUPPORT_H_
7
8 #include "media/base/decryptor.h"
9 #include "media/base/demuxer.h"
10 #include "third_party/WebKit/public/platform/WebMediaPlayer.h"
11
12 namespace blink {
13 class WebContentDecryptionModule;
14 class WebContentDecryptionModuleResult;
15 class WebLocalFrame;
16 class WebMediaPlayerClient;
17 class WebString;
18 }
19
20 namespace content {
21
22 class EncryptedMediaSupport {
23 public:
24 static scoped_ptr<EncryptedMediaSupport> create(
25 blink::WebMediaPlayerClient* client);
26
27 EncryptedMediaSupport() { }
28 virtual ~EncryptedMediaSupport();
29
30 virtual blink::WebMediaPlayer::MediaKeyException generateKeyRequest(
ddorwin 2014/08/22 21:08:47 Since we're changing things and this class is used
acolwell GONE FROM CHROMIUM 2014/08/22 23:20:22 Kept names as-is but added comment based on offlin
31 blink::WebLocalFrame* frame,
32 const blink::WebString& key_system,
33 const unsigned char* init_data,
34 unsigned init_data_length) = 0;
35
36 virtual blink::WebMediaPlayer::MediaKeyException addKey(
37 const blink::WebString& key_system,
38 const unsigned char* key,
39 unsigned key_length,
40 const unsigned char* init_data,
41 unsigned init_data_length,
42 const blink::WebString& session_id) = 0;
43
44 virtual blink::WebMediaPlayer::MediaKeyException cancelKeyRequest(
45 const blink::WebString& key_system,
46 const blink::WebString& session_id) = 0;
47
48 virtual void setContentDecryptionModule(
49 blink::WebContentDecryptionModule* cdm) = 0;
50 virtual void setContentDecryptionModule(
51 blink::WebContentDecryptionModule* cdm,
52 blink::WebContentDecryptionModuleResult result) = 0;
53 virtual void setContentDecryptionModuleSync(
54 blink::WebContentDecryptionModule* cdm) = 0;
55
56 virtual media::Demuxer::NeedKeyCB CreateNeedKeyCB() = 0;
ddorwin 2014/08/22 21:08:48 Should there be some documentation that the CB is
acolwell GONE FROM CHROMIUM 2014/08/22 23:20:22 I don't understand what you mean here. I added a c
57 virtual media::SetDecryptorReadyCB CreateSetDecryptorReadyCB() = 0;
58 virtual void OnDecryptError() = 0;
ddorwin 2014/08/22 21:08:48 This seems like something that the support impl wo
acolwell GONE FROM CHROMIUM 2014/08/22 23:20:22 Done.
59
60 private:
61 DISALLOW_COPY_AND_ASSIGN(EncryptedMediaSupport);
62 };
63
64 } // namespace content
65
66 #endif // CONTENT_RENDERER_MEDIA_CRYPTO_ENCRYPTED_MEDIA_SUPPORT_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698