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

Side by Side Diff: components/cdm/renderer/widevine_key_systems.cc

Issue 1027363002: Change EmeInitDataType to be an enum class (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: rebase Created 5 years, 9 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
OLDNEW
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 #include "components/cdm/renderer/widevine_key_systems.h" 5 #include "components/cdm/renderer/widevine_key_systems.h"
6 6
7 #include <string> 7 #include <string>
8 #include <vector> 8 #include <vector>
9 9
10 #include "base/logging.h" 10 #include "base/logging.h"
(...skipping 44 matching lines...) Expand 10 before | Expand all | Expand 10 after
55 55
56 // TODO(xhwang): A container or an initDataType may be supported even though 56 // TODO(xhwang): A container or an initDataType may be supported even though
57 // there are no codecs supported in that container. Fix this when we support 57 // there are no codecs supported in that container. Fix this when we support
58 // initDataType. 58 // initDataType.
59 info.supported_codecs = supported_codecs; 59 info.supported_codecs = supported_codecs;
60 60
61 // Here we assume that support for a container imples support for the 61 // Here we assume that support for a container imples support for the
62 // associated initialization data type. KeySystems handles validating 62 // associated initialization data type. KeySystems handles validating
63 // |init_data_type| x |container| pairings. 63 // |init_data_type| x |container| pairings.
64 if (supported_codecs & media::EME_CODEC_WEBM_ALL) 64 if (supported_codecs & media::EME_CODEC_WEBM_ALL)
65 info.supported_init_data_types |= media::EME_INIT_DATA_TYPE_WEBM; 65 info.supported_init_data_types |= media::kInitDataTypeMaskWebM;
66 #if defined(USE_PROPRIETARY_CODECS) 66 #if defined(USE_PROPRIETARY_CODECS)
67 if (supported_codecs & media::EME_CODEC_MP4_ALL) 67 if (supported_codecs & media::EME_CODEC_MP4_ALL)
68 info.supported_init_data_types |= media::EME_INIT_DATA_TYPE_CENC; 68 info.supported_init_data_types |= media::kInitDataTypeMaskCenc;
69 #endif // defined(USE_PROPRIETARY_CODECS) 69 #endif // defined(USE_PROPRIETARY_CODECS)
70 70
71 info.max_audio_robustness = max_audio_robustness; 71 info.max_audio_robustness = max_audio_robustness;
72 info.max_video_robustness = max_video_robustness; 72 info.max_video_robustness = max_video_robustness;
73 info.persistent_license_support = persistent_license_support; 73 info.persistent_license_support = persistent_license_support;
74 info.persistent_release_message_support = persistent_release_message_support; 74 info.persistent_release_message_support = persistent_release_message_support;
75 info.persistent_state_support = persistent_state_support; 75 info.persistent_state_support = persistent_state_support;
76 info.distinctive_identifier_support = distinctive_identifier_support; 76 info.distinctive_identifier_support = distinctive_identifier_support;
77 77
78 #if defined(ENABLE_PEPPER_CDMS) 78 #if defined(ENABLE_PEPPER_CDMS)
79 info.pepper_type = kWidevineCdmPluginMimeType; 79 info.pepper_type = kWidevineCdmPluginMimeType;
80 #endif // defined(ENABLE_PEPPER_CDMS) 80 #endif // defined(ENABLE_PEPPER_CDMS)
81 81
82 concrete_key_systems->push_back(info); 82 concrete_key_systems->push_back(info);
83 } 83 }
84 84
85 } // namespace cdm 85 } // namespace cdm
86 86
87 #endif // defined(WIDEVINE_CDM_AVAILABLE) 87 #endif // defined(WIDEVINE_CDM_AVAILABLE)
OLDNEW
« no previous file with comments | « components/cdm/renderer/android_key_systems.cc ('k') | content/browser/media/cdm/browser_cdm_manager.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698