17 #ifndef DGL_IMAGE_BASE_HPP_INCLUDED
18 #define DGL_IMAGE_BASE_HPP_INCLUDED
20 #include "Geometry.hpp"
28 kImageFormatGrayscale,
56 ImageBase(
const char* rawData, uint width, uint height, ImageFormat format);
114 void loadFromMemory(
const char* rawData, uint width, uint height, ImageFormat format = kImageFormatBGRA) noexcept;
122 ImageFormat format = kImageFormatBGRA) noexcept;
143 bool operator==(
const ImageBase& image)
const noexcept;
144 bool operator!=(
const ImageBase& image)
const noexcept;
156 #endif // DGL_IMAGE_HPP_INCLUDED
void loadFromMemory(const char *rawData, uint width, uint height, ImageFormat format=kImageFormatBGRA) noexcept
ImageBase & operator=(const ImageBase &image) noexcept
bool isInvalid() const noexcept
const char * getRawData() const noexcept
bool isValid() const noexcept
ImageFormat getFormat() const noexcept
const Size< uint > & getSize() const noexcept
Definition: ImageBase.hpp:44
uint getWidth() const noexcept
void drawAt(const GraphicsContext &context, int x, int y)
uint getHeight() const noexcept
void draw(const GraphicsContext &context)