2021-08-06 14:22:56 +02:00
|
|
|
#ifndef BWIDGETS_DRAW_HPP
|
|
|
|
#define BWIDGETS_DRAW_HPP
|
2021-07-18 18:26:12 +02:00
|
|
|
|
|
|
|
#include <cstdint>
|
|
|
|
#include <functional>
|
2021-08-10 23:48:19 +02:00
|
|
|
#include <memory>
|
2021-07-18 18:26:12 +02:00
|
|
|
|
|
|
|
struct SDL_PixelFormat;
|
|
|
|
struct SDL_Point;
|
|
|
|
|
2021-08-06 14:22:56 +02:00
|
|
|
namespace bwidgets
|
2021-07-18 18:26:12 +02:00
|
|
|
{
|
2021-08-06 14:22:56 +02:00
|
|
|
class Color;
|
|
|
|
class Renderer;
|
|
|
|
class Texture;
|
2021-07-18 18:26:12 +02:00
|
|
|
|
2021-08-06 14:22:56 +02:00
|
|
|
[[nodiscard]] auto aa(const Color&, int, float) noexcept -> Color;
|
2021-08-10 23:48:19 +02:00
|
|
|
[[nodiscard]] auto filled_circle(const Color&, int resolution,
|
2021-08-12 23:27:09 +02:00
|
|
|
Renderer*, int aa_pixels = 3)
|
2021-08-10 23:48:19 +02:00
|
|
|
-> std::shared_ptr<Texture>;
|
|
|
|
void set_pixels_color(
|
2021-08-12 15:55:47 +02:00
|
|
|
Texture*,
|
2021-08-10 23:48:19 +02:00
|
|
|
const std::function<uint32_t(const SDL_Point&, const SDL_PixelFormat*)>&);
|
2021-07-18 18:26:12 +02:00
|
|
|
}
|
|
|
|
|
|
|
|
#endif
|