Bug 1178753 - Always enable async-video when OMTC is enabled. r=sotaro

This commit is contained in:
Nicolas Silva 2015-07-08 09:28:48 +02:00
parent f2a9973e32
commit d473777049
6 changed files with 2 additions and 40 deletions

View File

@ -2436,15 +2436,8 @@ ContentParent::InitInternal(ProcessPriority aInitialPriority,
DebugOnly<bool> opened = PCompositor::Open(this);
MOZ_ASSERT(opened);
#ifndef MOZ_WIDGET_GONK
if (gfxPrefs::AsyncVideoOOPEnabled()) {
opened = PImageBridge::Open(this);
MOZ_ASSERT(opened);
}
#else
opened = PImageBridge::Open(this);
MOZ_ASSERT(opened);
#endif
}
#ifdef MOZ_WIDGET_GONK
DebugOnly<bool> opened = PSharedBufferManager::Open(this);

View File

@ -38,23 +38,6 @@ MediaSystemResourceManager::Shutdown()
}
}
/* static */ bool
MediaSystemResourceManager::IsMediaSystemResourceManagerEnabled()
{
#ifdef MOZ_WIDGET_GONK
return true;
#else
// XXX MediaSystemResourceManager is enabled only when ImageBridge is enabled.
// MediaSystemResourceManager uses ImageBridge's thread.
if (gfxPrefs::AsyncVideoOOPEnabled() &&
gfxPrefs::AsyncVideoEnabled()) {
return true;
} else {
return false;
}
#endif
}
class RunnableCallTask : public Task
{
public:
@ -72,7 +55,6 @@ protected:
/* static */ void
MediaSystemResourceManager::Init()
{
MOZ_ASSERT(IsMediaSystemResourceManagerEnabled());
if (!ImageBridgeChild::IsCreated()) {
NS_WARNING("ImageBridge does not exist");
return;

View File

@ -57,8 +57,6 @@ private:
MediaSystemResourceManager();
virtual ~MediaSystemResourceManager();
static bool IsMediaSystemResourceManagerEnabled();
void OpenIPC();
void CloseIPC();
bool IsIpcClosed();

View File

@ -716,14 +716,10 @@ gfxPlatform::InitLayersIPC()
if (XRE_IsParentProcess())
{
mozilla::layers::CompositorParent::StartUp();
#ifndef MOZ_WIDGET_GONK
if (gfxPrefs::AsyncVideoEnabled()) {
mozilla::layers::ImageBridgeChild::StartUp();
}
#else
mozilla::layers::ImageBridgeChild::StartUp();
#ifdef MOZ_WIDGET_GONK
SharedBufferManagerChild::StartUp();
#endif
mozilla::layers::ImageBridgeChild::StartUp();
}
}

View File

@ -284,8 +284,6 @@ private:
DECL_GFX_PREF(Once, "layers.acceleration.force-enabled", LayersAccelerationForceEnabled, bool, false);
DECL_GFX_PREF(Once, "layers.async-pan-zoom.enabled", AsyncPanZoomEnabledDoNotUseDirectly, bool, true);
DECL_GFX_PREF(Once, "layers.async-pan-zoom.separate-event-thread", AsyncPanZoomSeparateEventThread, bool, false);
DECL_GFX_PREF(Once, "layers.async-video.enabled", AsyncVideoEnabled, bool, true);
DECL_GFX_PREF(Once, "layers.async-video-oop.enabled", AsyncVideoOOPEnabled, bool, true);
DECL_GFX_PREF(Live, "layers.bench.enabled", LayersBenchEnabled, bool, false);
DECL_GFX_PREF(Once, "layers.bufferrotation.enabled", BufferRotationEnabled, bool, true);
#ifdef MOZ_GFX_OPTIMIZE_MOBILE

View File

@ -4224,11 +4224,6 @@ pref("layers.offmainthreadcomposition.enabled", true);
// 0 -> full-tilt mode: Recomposite even if not transaction occured.
pref("layers.offmainthreadcomposition.frame-rate", -1);
// Asynchonous video compositing using the ImageBridge IPDL protocol.
// requires off-main-thread compositing.
pref("layers.async-video.enabled", true);
pref("layers.async-video-oop.enabled",true);
#ifdef MOZ_WIDGET_UIKIT
pref("layers.async-pan-zoom.enabled", true);
#endif