mirror of
https://gitlab.winehq.org/wine/wine-gecko.git
synced 2024-09-13 09:24:08 -07:00
Bug 1008211 - Backed out changeset 4e1e052624c2 because of a regression on B2G
This commit is contained in:
parent
297d80e262
commit
c140d86de1
@ -71,18 +71,17 @@ CanvasClient2D::Update(gfx::IntSize aSize, ClientCanvasLayer* aLayer)
|
||||
flags |= TextureFlags::NEEDS_Y_FLIP;
|
||||
}
|
||||
|
||||
gfx::SurfaceFormat surfaceFormat = gfx::ImageFormatToSurfaceFormat(format);
|
||||
if (aLayer->IsGLLayer()) {
|
||||
// We want a cairo backend here as we don't want to be copying into
|
||||
// an accelerated backend and we like LockBits to work. This is currently
|
||||
// the most effective way to make this work.
|
||||
mBuffer = CreateBufferTextureClient(gfx::ImageFormatToSurfaceFormat(format),
|
||||
flags,
|
||||
BackendType::CAIRO);
|
||||
mBuffer = CreateBufferTextureClient(surfaceFormat, flags, BackendType::CAIRO);
|
||||
} else {
|
||||
mBuffer = CreateTextureClientForDrawing(gfx::ImageFormatToSurfaceFormat(format),
|
||||
flags,
|
||||
gfxPlatform::GetPlatform()->GetPreferredCanvasBackend(),
|
||||
aSize);
|
||||
// XXX - We should use CreateTextureClientForDrawing, but we first need
|
||||
// to use double buffering.
|
||||
mBuffer = CreateBufferTextureClient(surfaceFormat, flags,
|
||||
gfxPlatform::GetPlatform()->GetPreferredCanvasBackend());
|
||||
}
|
||||
MOZ_ASSERT(mBuffer->CanExposeDrawTarget());
|
||||
mBuffer->AllocateForSurface(aSize);
|
||||
|
Loading…
Reference in New Issue
Block a user