Very simple library for controlling small graphic LCDs

Dependents:   LCD

Embed: (wiki syntax)

« Back to documentation index

bitmapImage Class Reference

bitmapImage Class Reference

bitmapImage class More...

#include <bitmap.h>

Public Member Functions

 bitmapImage (char *inputFilename)
 Open BMP bitmap file.
void drawImage (gfxLcd *glcd, int xOffset, int yOffset)
 Draw bitmap to the LCD.

Data Fields

sBitmapInfo fileInfo
 File info.

Detailed Description

bitmapImage class

This class is used for drawing BMP images.

Definition at line 21 of file bitmap.h.


Constructor & Destructor Documentation

bitmapImage ( char *  inputFilename )

Open BMP bitmap file.

Parameters:
*inputFilenamePath to BMP file.

Definition at line 8 of file bitmap.cpp.


Member Function Documentation

void drawImage ( gfxLcd glcd,
int  xOffset,
int  yOffset 
)

Draw bitmap to the LCD.

Note:
There is no image buffer in this class instead the image is read from the fs every time it's drawn. This should be still fast enough as mBeds flash is still faster than the LCD.
Warning:
This class doesn't understand padding so images must be resized to size where paddings isn't needed. Also because of one bit BMP format the iamge width should be divisiable by 8.
Parameters:
*glcdReference to gfxLcd object.
xOffsetStart drawing from point x.
yOffsetStart drawing from point y.

Definition at line 52 of file bitmap.cpp.


Field Documentation

File info.

Definition at line 35 of file bitmap.h.