2024-07-05 13:36:55 +00:00
|
|
|
/*
|
|
|
|
* Copyright (c) 2024, Andreas Kling <andreas@ladybird.org>
|
|
|
|
*
|
|
|
|
* SPDX-License-Identifier: BSD-2-Clause
|
|
|
|
*/
|
|
|
|
|
|
|
|
#include <LibGfx/Painter.h>
|
|
|
|
#include <LibGfx/PainterSkia.h>
|
2024-09-25 13:44:58 +00:00
|
|
|
#include <LibGfx/PaintingSurface.h>
|
2024-07-05 13:36:55 +00:00
|
|
|
|
|
|
|
namespace Gfx {
|
|
|
|
|
|
|
|
Painter::~Painter() = default;
|
|
|
|
|
|
|
|
NonnullOwnPtr<Painter> Painter::create(NonnullRefPtr<Gfx::Bitmap> target_bitmap)
|
|
|
|
{
|
2024-09-25 13:44:58 +00:00
|
|
|
auto painting_surface = PaintingSurface::wrap_bitmap(target_bitmap);
|
|
|
|
return make<PainterSkia>(painting_surface);
|
2024-07-05 13:36:55 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
}
|