Bug 1402004. Use A8 as the format for the dummy drawtarget. r=Gankro

I'm not sure why the original comment was there. Everything seemed
to work in local testing.
This commit is contained in:
Jeff Muizelaar 2017-09-26 23:58:58 -04:00
Родитель d432f7bf8f
Коммит 06e888a351
1 изменённых файлов: 1 добавлений и 2 удалений

Просмотреть файл

@ -622,9 +622,8 @@ WebRenderLayerManager::GenerateFallbackData(nsDisplayItem* aItem,
bool isOpaque = aItem->GetOpaqueRegion(aDisplayListBuilder, &snapped).Contains(clippedBounds);
RefPtr<gfx::DrawEventRecorderMemory> recorder = MakeAndAddRef<gfx::DrawEventRecorderMemory>();
// TODO: should use 'format' to replace gfx::SurfaceFormat::B8G8R8A8. Currently blob image doesn't support A8 format.
RefPtr<gfx::DrawTarget> dummyDt =
gfx::Factory::CreateDrawTarget(gfx::BackendType::SKIA, gfx::IntSize(1, 1), gfx::SurfaceFormat::B8G8R8A8);
gfx::Factory::CreateDrawTarget(gfx::BackendType::SKIA, gfx::IntSize(1, 1), format);
RefPtr<gfx::DrawTarget> dt = gfx::Factory::CreateRecordingDrawTarget(recorder, dummyDt, imageSize.ToUnknownSize());
PaintItemByDrawTarget(aItem, dt, aImageRect, aOffset, aDisplayListBuilder,
fallbackData->mBasicLayerManager, this);