5#include "fifechan/image.hpp"
9#include "fifechan/exception.hpp"
10#include "fifechan/imageloader.hpp"
17 Image::Image() =
default;
19 Image::~Image() =
default;
34 throwException(
"Trying to load an image but no image loader is set.");
Abstract interface for loading image assets.
static Image * load(std::string const &filename, bool convertToDisplayFormat=true)
Loads an image by using the class' image loader.
virtual void convertToDisplayFormat()=0
Converts the image, if possible, to display format.
static void setImageLoader(ImageLoader *imageLoader)
Sets the ImageLoader to be used for loading images.
static ImageLoader * mImageLoader
Holds the image loader to be used when loading images.
static ImageLoader * getImageLoader()
Gets the image loader used for loading images.