mirror of
https://gitlab.winehq.org/wine/wine-gecko.git
synced 2024-09-13 09:24:08 -07:00
Bug 1240630: [ffvpx] P2. Hook up FFVPX PDM to PDMFactory. r=kentuckyfriedtakahe
Add new preference media.ffvpx.enabled to control FFVPX PDM being enabled.
This commit is contained in:
parent
583e06278a
commit
5e509628ae
@ -9,6 +9,9 @@
|
||||
#ifdef XP_WIN
|
||||
#include "WMFDecoderModule.h"
|
||||
#endif
|
||||
#ifdef MOZ_FFVPX
|
||||
#include "FFVPXRuntimeLinker.h"
|
||||
#endif
|
||||
#ifdef MOZ_FFMPEG
|
||||
#include "FFmpegRuntimeLinker.h"
|
||||
#endif
|
||||
@ -53,6 +56,10 @@ bool PDMFactory::sAndroidMCDecoderEnabled = false;
|
||||
bool PDMFactory::sAndroidMCDecoderPreferred = false;
|
||||
#endif
|
||||
bool PDMFactory::sGMPDecoderEnabled = false;
|
||||
#ifdef MOZ_FFVPX
|
||||
bool PDMFactory::sFFVPXDecoderEnabled = false;
|
||||
using namespace ffvpx;
|
||||
#endif
|
||||
#ifdef MOZ_FFMPEG
|
||||
bool PDMFactory::sFFmpegDecoderEnabled = false;
|
||||
#endif
|
||||
@ -94,6 +101,10 @@ PDMFactory::Init()
|
||||
Preferences::AddBoolVarCache(&sFFmpegDecoderEnabled,
|
||||
"media.ffmpeg.enabled", false);
|
||||
#endif
|
||||
#ifdef MOZ_FFVPX
|
||||
Preferences::AddBoolVarCache(&sFFVPXDecoderEnabled,
|
||||
"media.ffvpx.enabled", false);
|
||||
#endif
|
||||
#ifdef XP_WIN
|
||||
Preferences::AddBoolVarCache(&sWMFDecoderEnabled,
|
||||
"media.wmf.enabled", false);
|
||||
@ -112,6 +123,9 @@ PDMFactory::Init()
|
||||
#ifdef MOZ_APPLEMEDIA
|
||||
AppleDecoderModule::Init();
|
||||
#endif
|
||||
#ifdef MOZ_FFVPX
|
||||
FFVPXRuntimeLinker::Link();
|
||||
#endif
|
||||
#ifdef MOZ_FFMPEG
|
||||
FFmpegRuntimeLinker::Link();
|
||||
#endif
|
||||
@ -262,6 +276,12 @@ PDMFactory::CreatePDMs()
|
||||
StartupPDM(m);
|
||||
}
|
||||
#endif
|
||||
#ifdef MOZ_FFVPX
|
||||
if (sFFVPXDecoderEnabled) {
|
||||
m = FFVPXRuntimeLinker::CreateDecoderModule();
|
||||
StartupPDM(m);
|
||||
}
|
||||
#endif
|
||||
#ifdef MOZ_FFMPEG
|
||||
if (sFFmpegDecoderEnabled) {
|
||||
m = FFmpegRuntimeLinker::CreateDecoderModule();
|
||||
|
@ -73,6 +73,9 @@ private:
|
||||
static bool sAndroidMCDecoderEnabled;
|
||||
#endif
|
||||
static bool sGMPDecoderEnabled;
|
||||
#ifdef MOZ_FFVPX
|
||||
static bool sFFVPXDecoderEnabled;
|
||||
#endif
|
||||
#ifdef MOZ_FFMPEG
|
||||
static bool sFFmpegDecoderEnabled;
|
||||
#endif
|
||||
|
@ -329,6 +329,9 @@ pref("media.wmf.skip-blacklist", false);
|
||||
#if defined(MOZ_FFMPEG)
|
||||
pref("media.ffmpeg.enabled", true);
|
||||
#endif
|
||||
#if defined(MOZ_FFVPX)
|
||||
pref("media.ffvpx.enabled", true);
|
||||
#endif
|
||||
pref("media.gmp.decoder.enabled", false);
|
||||
pref("media.gmp.decoder.aac", 0);
|
||||
pref("media.gmp.decoder.h264", 0);
|
||||
|
Loading…
Reference in New Issue
Block a user