OLD | NEW |
1 // Copyright 2013 The Chromium Authors. All rights reserved. | 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 | 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 "chrome/renderer/media/chrome_key_systems.h" | 5 #include "chrome/renderer/media/chrome_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 202 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
213 | 213 |
214 std::vector<std::string> codecs; | 214 std::vector<std::string> codecs; |
215 GetSupportedCodecs(additional_param_names, additional_param_values, &codecs); | 215 GetSupportedCodecs(additional_param_names, additional_param_values, &codecs); |
216 | 216 |
217 SupportedCodecs supported_codecs = content::EME_CODEC_NONE; | 217 SupportedCodecs supported_codecs = content::EME_CODEC_NONE; |
218 for (size_t i = 0; i < codecs.size(); ++i) { | 218 for (size_t i = 0; i < codecs.size(); ++i) { |
219 if (codecs[i] == kCdmSupportedCodecVorbis) | 219 if (codecs[i] == kCdmSupportedCodecVorbis) |
220 supported_codecs |= content::EME_CODEC_WEBM_VORBIS; | 220 supported_codecs |= content::EME_CODEC_WEBM_VORBIS; |
221 if (codecs[i] == kCdmSupportedCodecVp8) | 221 if (codecs[i] == kCdmSupportedCodecVp8) |
222 supported_codecs |= content::EME_CODEC_WEBM_VP8; | 222 supported_codecs |= content::EME_CODEC_WEBM_VP8; |
| 223 if (codecs[i] == kCdmSupportedCodecVp9) |
| 224 supported_codecs |= content::EME_CODEC_WEBM_VP9; |
223 #if defined(USE_PROPRIETARY_CODECS) | 225 #if defined(USE_PROPRIETARY_CODECS) |
224 if (codecs[i] == kCdmSupportedCodecAac) | 226 if (codecs[i] == kCdmSupportedCodecAac) |
225 supported_codecs |= content::EME_CODEC_MP4_AAC; | 227 supported_codecs |= content::EME_CODEC_MP4_AAC; |
226 if (codecs[i] == kCdmSupportedCodecAvc1) | 228 if (codecs[i] == kCdmSupportedCodecAvc1) |
227 supported_codecs |= content::EME_CODEC_MP4_AVC1; | 229 supported_codecs |= content::EME_CODEC_MP4_AVC1; |
228 #endif // defined(USE_PROPRIETARY_CODECS) | 230 #endif // defined(USE_PROPRIETARY_CODECS) |
229 } | 231 } |
230 | 232 |
231 AddWidevineWithCodecs(WIDEVINE, supported_codecs, concrete_key_systems); | 233 AddWidevineWithCodecs(WIDEVINE, supported_codecs, concrete_key_systems); |
232 | 234 |
(...skipping 37 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
270 #endif | 272 #endif |
271 | 273 |
272 #if defined(WIDEVINE_CDM_AVAILABLE) | 274 #if defined(WIDEVINE_CDM_AVAILABLE) |
273 #if defined(ENABLE_PEPPER_CDMS) | 275 #if defined(ENABLE_PEPPER_CDMS) |
274 AddPepperBasedWidevine(key_systems_info); | 276 AddPepperBasedWidevine(key_systems_info); |
275 #elif defined(OS_ANDROID) | 277 #elif defined(OS_ANDROID) |
276 AddAndroidWidevine(key_systems_info); | 278 AddAndroidWidevine(key_systems_info); |
277 #endif | 279 #endif |
278 #endif | 280 #endif |
279 } | 281 } |
OLD | NEW |