mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2024-11-24 16:40:21 +00:00
8a07131229
We actually include what we use where we use it. This change aims to improve the speed of incremental builds.
33 lines
951 B
C++
33 lines
951 B
C++
/*
|
|
* Copyright (c) 2021, Ali Mohammad Pur <mpfard@serenityos.org>
|
|
* Copyright (c) 2022, Ben Maxwell <macdue@dueutil.tech>
|
|
* Copyright (c) 2022, Torsten Engelmann <engelTorsten@gmx.de>
|
|
*
|
|
* SPDX-License-Identifier: BSD-2-Clause
|
|
*/
|
|
|
|
#if defined(AK_COMPILER_GCC)
|
|
# pragma GCC optimize("O3")
|
|
#endif
|
|
|
|
#include <LibGfx/AntiAliasingPainter.h>
|
|
|
|
namespace Gfx {
|
|
|
|
void AntiAliasingPainter::stroke_path(DeprecatedPath const& path, Color color, float thickness)
|
|
{
|
|
if (thickness <= 0)
|
|
return;
|
|
// FIXME: Cache this? Probably at a higher level such as in LibWeb?
|
|
fill_path(path.stroke_to_fill(thickness), color);
|
|
}
|
|
|
|
void AntiAliasingPainter::stroke_path(DeprecatedPath const& path, Gfx::PaintStyle const& paint_style, float thickness, float opacity)
|
|
{
|
|
if (thickness <= 0)
|
|
return;
|
|
// FIXME: Cache this? Probably at a higher level such as in LibWeb?
|
|
fill_path(path.stroke_to_fill(thickness), paint_style, opacity);
|
|
}
|
|
|
|
}
|