2 * GraphLCD graphics library
4 * image.h - image and animation handling
6 * based on graphlcd plugin 0.1.1 for the Video Disc Recorder
7 * (c) 2001-2004 Carsten Siebholz <c.siebholz AT t-online.de>
9 * This file is released under the GNU General Public License. Refer
10 * to the COPYING file distributed with this package.
12 * (c) 2004 Andreas Regel <andreas.regel AT powarman.de>
15 #ifndef _GLCDGRAPHICS_IMAGE_H_
16 #define _GLCDGRAPHICS_IMAGE_H_
33 unsigned int curBitmap;
35 std::vector <cBitmap *> bitmaps;
40 unsigned int Width() const { return width; }
41 unsigned int Height() const { return height; }
42 unsigned int Count() const { return bitmaps.size(); }
43 unsigned int Delay() const { return delay; }
44 uint64_t LastChange() const { return lastChange; }
45 void First(uint64_t t) { lastChange = t; curBitmap = 0; }
46 bool Next(uint64_t t) { lastChange = t; curBitmap++; return curBitmap < bitmaps.size(); }
47 void SetWidth(unsigned int Width) { width = Width; }
48 void SetHeight(unsigned int Height) { height = Height; }
49 void SetDelay(unsigned int d) { delay = d; }
50 cBitmap * GetBitmap(unsigned int nr) const;
51 cBitmap * GetBitmap() const;
52 void AddBitmap(cBitmap * Bitmap) { bitmaps.push_back(Bitmap); }