summaryrefslogtreecommitdiff
path: root/Userland/Libraries/LibWeb/Layout/ImageBox.cpp
diff options
context:
space:
mode:
authorSam Atkins <atkinssj@serenityos.org>2021-09-20 19:55:40 +0100
committerAndreas Kling <kling@serenityos.org>2021-09-20 22:18:20 +0200
commita50f4d2fc9d38fa93e2dc2e63248060f8cbd34a8 (patch)
tree9e43eb68be27f8387cbb311bccc9e822c1dcd02c /Userland/Libraries/LibWeb/Layout/ImageBox.cpp
parent1c807410cd06ded77b964ed6e9097e6d5451f791 (diff)
downloadserenity-a50f4d2fc9d38fa93e2dc2e63248060f8cbd34a8.zip
LibWeb: Enable bilinear blending for bitmaps
This is slower, but looks a lot nicer. :^)
Diffstat (limited to 'Userland/Libraries/LibWeb/Layout/ImageBox.cpp')
-rw-r--r--Userland/Libraries/LibWeb/Layout/ImageBox.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/Userland/Libraries/LibWeb/Layout/ImageBox.cpp b/Userland/Libraries/LibWeb/Layout/ImageBox.cpp
index ff24df84de..92e3aef9e1 100644
--- a/Userland/Libraries/LibWeb/Layout/ImageBox.cpp
+++ b/Userland/Libraries/LibWeb/Layout/ImageBox.cpp
@@ -96,7 +96,7 @@ void ImageBox::paint(PaintContext& context, PaintPhase phase)
alt = image_element.src();
context.painter().draw_text(enclosing_int_rect(absolute_rect()), alt, Gfx::TextAlignment::Center, computed_values().color(), Gfx::TextElision::Right);
} else if (auto bitmap = m_image_loader.bitmap(m_image_loader.current_frame_index())) {
- context.painter().draw_scaled_bitmap(enclosing_int_rect(absolute_rect()), *bitmap, bitmap->rect());
+ context.painter().draw_scaled_bitmap(enclosing_int_rect(absolute_rect()), *bitmap, bitmap->rect(), 1.0f, Gfx::Painter::ScalingMode::BilinearBlend);
}
}
}