Bug 1251726 - Check if Compositor is set r=nical

This commit is contained in:
Sotaro Ikeda 2016-03-07 17:35:38 -08:00
parent b935d483a8
commit 81561bca72

View File

@ -543,9 +543,11 @@ BufferTextureHost::PrepareTextureSource(CompositableTextureSourceRef& aTexture)
bool compatibleFormats = texture
&& (mFormat == texture->GetFormat()
|| (mFormat == gfx::SurfaceFormat::YUV
&& mCompositor
&& mCompositor->SupportsEffect(EffectTypes::YCBCR)
&& texture->GetNextSibling())
|| (mFormat == gfx::SurfaceFormat::YUV
&& mCompositor
&& !mCompositor->SupportsEffect(EffectTypes::YCBCR)
&& texture->GetFormat() == gfx::SurfaceFormat::B8G8R8X8));