mirror of
https://github.com/RGBCube/serenity
synced 2025-07-27 09:57:35 +00:00
LibWeb/Painting: Do not paint paths not visible in viewport
Painting optimization to do less unnecessary work
This commit is contained in:
parent
708574d373
commit
3fb2b008a2
2 changed files with 20 additions and 0 deletions
|
@ -194,6 +194,7 @@ struct FillRectWithRoundedCorners {
|
|||
};
|
||||
|
||||
struct FillPathUsingColor {
|
||||
Gfx::IntRect bounding_rect;
|
||||
Gfx::Path path;
|
||||
Color color;
|
||||
Gfx::Painter::WindingRule winding_rule;
|
||||
|
@ -203,6 +204,7 @@ struct FillPathUsingColor {
|
|||
};
|
||||
|
||||
struct FillPathUsingPaintStyle {
|
||||
Gfx::IntRect bounding_rect;
|
||||
Gfx::Path path;
|
||||
NonnullRefPtr<Gfx::PaintStyle> paint_style;
|
||||
Gfx::Painter::WindingRule winding_rule;
|
||||
|
@ -213,6 +215,7 @@ struct FillPathUsingPaintStyle {
|
|||
};
|
||||
|
||||
struct StrokePathUsingColor {
|
||||
Gfx::IntRect bounding_rect;
|
||||
Gfx::Path path;
|
||||
Color color;
|
||||
float thickness;
|
||||
|
@ -222,6 +225,7 @@ struct StrokePathUsingColor {
|
|||
};
|
||||
|
||||
struct StrokePathUsingPaintStyle {
|
||||
Gfx::IntRect bounding_rect;
|
||||
Gfx::Path path;
|
||||
NonnullRefPtr<Gfx::PaintStyle> paint_style;
|
||||
float thickness;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue