Update V8 to version 4.7.56.
[chromium-blink-merge.git] / media / base / key_system_info.h
blobd349452b8854c9f16baa3f5fd65ec6a241ffe904
1 // Copyright 2013 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.
5 #ifndef MEDIA_BASE_KEY_SYSTEM_INFO_H_
6 #define MEDIA_BASE_KEY_SYSTEM_INFO_H_
8 #include <string>
10 #include "build/build_config.h"
11 #include "media/base/eme_constants.h"
12 #include "media/base/media_export.h"
14 // Definitions:
15 // * Key system
16 // https://dvcs.w3.org/hg/html-media/raw-file/default/encrypted-media/encrypted-media.html#key-system
17 // * Concrete key system
18 // A key system string that can be instantiated, such as
19 // via the MediaKeys constructor. Examples include "org.w3.clearkey" and
20 // "com.widevine.alpha".
21 // * Abstract key system
22 // A key system string that cannot be instantiated like a concrete key system
23 // but is otherwise useful, such as in discovery using isTypeSupported().
24 // * Parent key system
25 // A key system string that is one level up from the child key system. It may
26 // be an abstract key system.
27 // As an example, "com.example" is the parent of "com.example.foo".
29 namespace media {
31 // Contains information about an EME key system as well as how to instantiate
32 // the corresponding CDM.
33 struct MEDIA_EXPORT KeySystemInfo {
34 KeySystemInfo();
35 ~KeySystemInfo();
37 std::string key_system;
39 InitDataTypeMask supported_init_data_types = kInitDataTypeMaskNone;
40 SupportedCodecs supported_codecs = EME_CODEC_NONE;
41 #if defined(OS_ANDROID)
42 SupportedCodecs supported_secure_codecs = EME_CODEC_NONE;
43 #endif // defined(OS_ANDROID)
44 EmeRobustness max_audio_robustness = EmeRobustness::INVALID;
45 EmeRobustness max_video_robustness = EmeRobustness::INVALID;
46 EmeSessionTypeSupport persistent_license_support =
47 EmeSessionTypeSupport::INVALID;
48 EmeSessionTypeSupport persistent_release_message_support =
49 EmeSessionTypeSupport::INVALID;
50 EmeFeatureSupport persistent_state_support = EmeFeatureSupport::INVALID;
51 EmeFeatureSupport distinctive_identifier_support = EmeFeatureSupport::INVALID;
53 // A hierarchical parent for |key_system|. This value can be used to check
54 // supported types but cannot be used to instantiate a MediaKeys object.
55 // Only one parent key system is currently supported per concrete key system.
56 std::string parent_key_system;
58 // The following indicate how the corresponding CDM should be instantiated.
59 bool use_aes_decryptor = false;
60 #if defined(ENABLE_PEPPER_CDMS)
61 std::string pepper_type;
62 #endif
65 } // namespace media
67 #endif // MEDIA_BASE_KEY_SYSTEM_INFO_H_