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

Side by Side Diff: media/base/browser_cdm.h

Issue 308073004: Add PlayerTracker and BrowserCdm interfaces. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: comments addressed Created 6 years, 6 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 MEDIA_BASE_BROWSER_CDM_H_
6 #define MEDIA_BASE_BROWSER_CDM_H_
7
8 #include "media/base/media_keys.h"
9 #include "media/base/player_tracker.h"
10
11 namespace media {
12
13 // Interface for browser side CDMs.
14 class BrowserCdm : public MediaKeys, public PlayerTracker {
15 public:
16 virtual ~BrowserCdm();
17
18 // MediaKeys implementation.
19 virtual bool CreateSession(uint32 session_id,
20 const std::string& content_type,
21 const uint8* init_data,
22 int init_data_length) = 0;
23 virtual void LoadSession(uint32 session_id,
24 const std::string& web_session_id) = 0;
25 virtual void UpdateSession(uint32 session_id,
26 const uint8* response,
27 int response_length) = 0;
28 virtual void ReleaseSession(uint32 session_id) = 0;
29
30 // PlayerTracker implementation.
31 virtual int RegisterPlayer(const base::Closure& new_key_cb,
32 const base::Closure& cdm_unset_cb) = 0;
33 virtual void UnregisterPlayer(int registration_id) = 0;
34
35 protected:
36 BrowserCdm();
37
38 private:
39 DISALLOW_COPY_AND_ASSIGN(BrowserCdm);
40 };
41
42 } // namespace media
43
44 #endif // MEDIA_BASE_BROWSER_CDM_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698