Bug 1207429: P1. remove media.fragmented-mp4.exposed pref. r=kentuckyfriedtakahe draft
authorJean-Yves Avenard <jyavenard@mozilla.com>
Fri, 25 Sep 2015 16:37:53 +1000
changeset 607022 dfb4633ba5fe4244a65e1712609a462d4ad79a23
parent 607021 91a5dbaf6e66529290db1fc0466a0252e6040644
child 607023 8fd2ae9e68c96c078e9abc58dff0e3a0f80e292e
push id93006
push userjyavenard@mozilla.com
push dateThu, 15 Oct 2015 05:15:33 +0000
treeherdertry@45ea2a01301e [default view] [failures only]
reviewerskentuckyfriedtakahe
bugs1207429
milestone43.0a2
Bug 1207429: P1. remove media.fragmented-mp4.exposed pref. r=kentuckyfriedtakahe
dom/media/DecoderTraits.cpp
dom/media/test/eme.js
dom/media/test/test_can_play_type_mpeg.html
mobile/android/app/mobile.js
modules/libpref/init/all.js
--- a/dom/media/DecoderTraits.cpp
+++ b/dom/media/DecoderTraits.cpp
@@ -344,18 +344,17 @@ IsDirectShowSupportedType(const nsACStri
 
 #ifdef MOZ_FMP4
 static bool
 IsMP4SupportedType(const nsACString& aType,
                    const nsAString& aCodecs = EmptyString())
 {
   // MP4Decoder/Reader is currently used for MSE and mp4 files local playback.
   bool haveAAC, haveMP3, haveH264;
-  return Preferences::GetBool("media.fragmented-mp4.exposed", false) &&
-         MP4Decoder::CanHandleMediaType(aType, aCodecs, haveAAC, haveH264, haveMP3);
+  return MP4Decoder::CanHandleMediaType(aType, aCodecs, haveAAC, haveH264, haveMP3);
 }
 #endif
 
 /* static */ bool
 DecoderTraits::IsMP4Type(const nsACString& aType)
 {
 #ifdef MOZ_FMP4
   return IsMP4SupportedType(aType);
--- a/dom/media/test/eme.js
+++ b/dom/media/test/eme.js
@@ -394,17 +394,16 @@ function SetupEME(test, token, params)
     }
   });
   return v;
 }
 
 function SetupEMEPref(callback) {
   var prefs = [
     [ "media.mediasource.enabled", true ],
-    [ "media.fragmented-mp4.exposed", true ],
     [ "media.eme.apiVisible", true ],
   ];
 
   if (/Linux/.test(manifestNavigator().userAgent)) {
     prefs.push([ "media.fragmented-mp4.ffmpeg.enabled", true ]);
   } else if (SpecialPowers.Services.appinfo.name == "B2G" ||
              !manifestVideo().canPlayType("video/mp4")) {
    // XXX remove once we have mp4 PlatformDecoderModules on all platforms.
--- a/dom/media/test/test_can_play_type_mpeg.html
+++ b/dom/media/test/test_can_play_type_mpeg.html
@@ -126,18 +126,17 @@ function IsLinuxGStreamer() {
 }
 
 function IsJellyBeanOrLater() {
   return androidVersion >= 16;
 }
 
 // Check whether we should expect the new MP4Reader-based support to work.
 function IsMP4ReaderAvailable() {
-  var prefs = getPref("media.fragmented-mp4.enabled") &&
-              getPref("media.fragmented-mp4.exposed");
+  var prefs = getPref("media.fragmented-mp4.enabled");
   return prefs && (IsWindowsVistaOrLater() || IsMacOSSnowLeopardOrLater() || IsJellyBeanOrLater());
 }
 
 var haveMp4 = IsWindowsVistaOrLater() ||
               getPref("media.omx.enabled") ||
               getPref("media.gstreamer.enabled") ||
               IsMP4ReaderAvailable();
 // TODO:  Add "getPref("media.plugins.enabled")" once MP4 works on Gingerbread.
--- a/mobile/android/app/mobile.js
+++ b/mobile/android/app/mobile.js
@@ -584,17 +584,16 @@ pref("media.cache_readahead_limit", 30);
 // On Android this is decided by a similar value which varies for
 // each OMX decoder |OMX_PARAM_PORTDEFINITIONTYPE::nBufferCountMin|. This
 // number must be less than the OMX equivalent or gecko will think it is
 // chronically starved of video frames. All decoders seen so far have a value
 // of at least 4.
 pref("media.video-queue.default-size", 3);
 
 // Enable the MediaCodec PlatformDecoderModule by default.
-pref("media.fragmented-mp4.exposed", true);
 pref("media.fragmented-mp4.enabled", true);
 pref("media.fragmented-mp4.android-media-codec.enabled", true);
 pref("media.fragmented-mp4.android-media-codec.preferred", true);
 
 // Enable MSE
 pref("media.mediasource.enabled", true);
 
 // optimize images memory usage
--- a/modules/libpref/init/all.js
+++ b/modules/libpref/init/all.js
@@ -312,22 +312,16 @@ pref("media.wmf.decoder.thread-count", -
 #endif
 #ifdef MOZ_DIRECTSHOW
 pref("media.directshow.enabled", true);
 #endif
 #ifdef MOZ_FMP4
 pref("media.fragmented-mp4.enabled", true);
 pref("media.fragmented-mp4.ffmpeg.enabled", false);
 pref("media.fragmented-mp4.gmp.enabled", false);
-#if defined(XP_WIN) && defined(MOZ_WMF) || defined(XP_MACOSX) || defined(MOZ_WIDGET_GONK)
-// Denotes that the fragmented MP4 parser can be created by <video> elements.
-pref("media.fragmented-mp4.exposed", true);
-#else
-pref("media.fragmented-mp4.exposed", false);
-#endif
 // Specifies whether the fragmented MP4 parser uses a test decoder that
 // just outputs blank frames/audio instead of actually decoding. The blank
 // decoder works on all platforms.
 pref("media.fragmented-mp4.use-blank-decoder", false);
 #endif
 #ifdef MOZ_RAW
 pref("media.raw.enabled", true);
 #endif