You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
chromium/chromium-64.0.3282.119-enab...

55 lines
2.0 KiB

diff -up chromium-64.0.3282.119/media/base/mime_util_internal.cc.mp3 chromium-64.0.3282.119/media/base/mime_util_internal.cc
--- chromium-64.0.3282.119/media/base/mime_util_internal.cc.mp3 2018-01-24 15:05:48.000000000 -0500
+++ chromium-64.0.3282.119/media/base/mime_util_internal.cc 2018-01-25 11:18:12.354147726 -0500
@@ -279,15 +279,19 @@ void MimeUtil::AddSupportedMediaFormats(
CodecSet webm_codecs(webm_audio_codecs);
webm_codecs.insert(webm_video_codecs.begin(), webm_video_codecs.end());
-#if BUILDFLAG(USE_PROPRIETARY_CODECS)
const CodecSet mp3_codecs{MP3};
+#if BUILDFLAG(USE_PROPRIETARY_CODECS)
const CodecSet aac{MPEG2_AAC, MPEG4_AAC};
+#else
+ const CodecSet aac{};
+#endif
+ CodecSet mp4_audio_codecs(aac);
+ mp4_audio_codecs.emplace(MP3);
+#if BUILDFLAG(USE_PROPRIETARY_CODECS)
CodecSet avc_and_aac(aac);
avc_and_aac.emplace(H264);
- CodecSet mp4_audio_codecs(aac);
- mp4_audio_codecs.emplace(MP3);
mp4_audio_codecs.emplace(FLAC);
#if BUILDFLAG(ENABLE_AC3_EAC3_AUDIO_DEMUXING)
mp4_audio_codecs.emplace(AC3);
@@ -329,10 +333,10 @@ void MimeUtil::AddSupportedMediaFormats(
AddContainerWithCodecs("application/ogg", ogg_codecs, false);
AddContainerWithCodecs("audio/flac", implicit_codec, false);
-#if BUILDFLAG(USE_PROPRIETARY_CODECS)
AddContainerWithCodecs("audio/mpeg", mp3_codecs, true); // Allow "mp3".
AddContainerWithCodecs("audio/mp3", implicit_codec, true);
AddContainerWithCodecs("audio/x-mp3", implicit_codec, true);
+#if BUILDFLAG(USE_PROPRIETARY_CODECS)
AddContainerWithCodecs("audio/aac", implicit_codec, true); // AAC / ADTS.
AddContainerWithCodecs("audio/mp4", mp4_audio_codecs, true);
DCHECK(!mp4_video_codecs.empty());
@@ -970,7 +974,6 @@ bool MimeUtil::IsCodecProprietary(Codec
case INVALID_CODEC:
case AC3:
case EAC3:
- case MP3:
case MPEG2_AAC:
case MPEG4_AAC:
case H264:
@@ -978,6 +981,7 @@ bool MimeUtil::IsCodecProprietary(Codec
case DOLBY_VISION:
return true;
+ case MP3:
case PCM:
case VORBIS:
case OPUS: