From 7a0191cbe968bd0a1454e88d7bfc1b3b861c4b04 Mon Sep 17 00:00:00 2001 From: Aliaksandr Kalenik Date: Wed, 29 Nov 2023 21:22:09 +0100 Subject: [PATCH] LibWeb: Clear texture allocated for stacking context painting In OpenGL newly allocated texture has undefined initial state so we need to clear it before stacking context painting. --- .../Libraries/LibWeb/Painting/PaintingCommandExecutorGPU.cpp | 1 + 1 file changed, 1 insertion(+) diff --git a/Userland/Libraries/LibWeb/Painting/PaintingCommandExecutorGPU.cpp b/Userland/Libraries/LibWeb/Painting/PaintingCommandExecutorGPU.cpp index 6a70322259..e46ce23400 100644 --- a/Userland/Libraries/LibWeb/Painting/PaintingCommandExecutorGPU.cpp +++ b/Userland/Libraries/LibWeb/Painting/PaintingCommandExecutorGPU.cpp @@ -106,6 +106,7 @@ CommandResult PaintingCommandExecutorGPU::push_stacking_context(float opacity, b auto canvas = AccelGfx::Canvas::create(source_paintable_rect.size()); painter->set_target_canvas(canvas); painter->translate(-source_paintable_rect.location().to_type()); + painter->clear(Color::Transparent); auto source_rect = source_paintable_rect.to_type().translated(-transform.origin); auto transformed_destination_rect = affine_transform.map(source_rect).translated(transform.origin);