Unified CTOR to create empty bitmap.
Unified CTOR tor create bitmap from preexisting data.
Creates an empty bitmap. DEPRECATED!
Creates a bitmap from an array. DEPRECATED!
Creates an empty bitmap.
Creates a bitmap from an array.
CTOR for 1 bit bitmaps with no preexisting source.
CTOR to convert 8bit aligned bitmaps to 32/64bit ones.
CTOR for 1 bit bitmaps with a preexisting source. Alignment and padding is for size_t (32 and 64 bit, on their respected systems)
Generates a basic collision shape using
Offsets all indexes in the bitmap by a certain value. Keeps zeroth index (usually for transparency) if needed. Useful when converting bitmaps.
Returns the pixel at the given position.
Returns the pixel at the given position.
Returns the pixel at the given position.
Resizes the bitmap. NOTE: It's not for scaling.
Resizes the array behind the bitmap.
Returns a 2D slice (window) of the bitmap.
Writes the pixel at the given position.
Writes the pixel at the given position.
Writes the pixel at the given position.
Horizontal invertion for reading and writing
Vertical invertion for reading anr writing
Total length of a line in bits
Returns the width of the bitmap.
Returns the height of the bitmap.
Returns the palette pointer.
Sets the palette pointer. Make sure that you set it to a valid memory location. DEPRECATED!
Returns the wordlength of the type
Clears the whole bitmap to a transparent color.
Implements a bitmap with variable bit depth. Use the aliases to initialize them. Note for 16Bit bitmap: It's using the master palette, It's not implementing any 16 bit RGB or RGBA color space directly. Can implement such colorspaces via proper lookup tables. Note for 4Bit bitmap: It's width needs to be an even number (for rendering simplicity), otherwise it'll cause an exception.