#include <ImageBase.hpp>
Public Member Functions | |
virtual | ~ImageBase () |
bool | isValid () const noexcept |
uint | getWidth () const noexcept |
uint | getHeight () const noexcept |
const Size< uint > & | getSize () const noexcept |
const char * | getRawData () const noexcept |
void | draw () |
void | drawAt (const int x, const int y) |
void | drawAt (const Point< int > &pos) |
ImageBase & | operator= (const ImageBase &image) noexcept |
bool | operator== (const ImageBase &image) const noexcept |
bool | operator!= (const ImageBase &image) const noexcept |
Protected Member Functions | |
ImageBase () | |
ImageBase (const char *const rawData, const uint width, const uint height) | |
ImageBase (const char *const rawData, const Size< uint > &size) | |
ImageBase (const ImageBase &image) | |
virtual void | _drawAt (const Point< int > &pos)=0 |
Protected Attributes | |
const char * | fRawData |
Size< uint > | fSize |
Base DGL Image class.
This is an Image class that handles raw image data in pixels. It is an abstract class that provides the common methods to build on top. Cairo and OpenGL Image classes are based upon this one.
|
protected |
Constructor for a null Image.
|
protected |
Constructor using raw image data.
|
protected |
Constructor using raw image data.
|
protected |
Constructor using another image data.
|
virtual |
Destructor.
|
noexcept |
Check if this image is valid.
|
noexcept |
Get width.
|
noexcept |
Get height.
|
noexcept |
Get size.
|
noexcept |
Get the raw image data.
void ImageBase::draw | ( | ) |
Draw this image at (0, 0) point.
void ImageBase::drawAt | ( | const int | x, |
const int | y | ||
) |
Draw this image at (x, y) point.
void ImageBase::drawAt | ( | const Point< int > & | pos | ) |
Draw this image at position pos.