8#include <nlohmann/json.hpp>
30 this->
m_shape = std::move(p.m_shape);
37 this->
m_shape = std::move(p.m_shape);
49 nlohmann::json json =
"{}"_json;
63 const auto& col = json.at(
"colour");
70 const auto& pj = json.at(
"pos");
void g(const std::uint8_t g) noexcept
Green.
void a(const std::uint8_t a) noexcept
Alpha.
void r(const std::uint8_t r) noexcept
Red.
void b(const std::uint8_t b) noexcept
Blue.
void deserialize(const nlohmann::json &json) override
Deserializes from object.
graphics::Point m_shape
Shape.
virtual ~Point()
Destructor.
Point & operator=(Point &&)
Move assignment operator.
nlohmann::json serialize() override
Serializes object.
void create(const glm::vec2 &pos)
Initial point positon.
const glm::vec2 & pos() const
Get pos.
Colour m_colour
Used by all primitives.