epaper

Dependents:   epaper_mbed_test_copy1

Fork of EaEpaper by Peter Drescher

Committer:
dreschpe
Date:
Sat Nov 09 23:37:43 2013 +0000
Revision:
0:fedcef5319f5
Lib for using a E-Paper display from Pervasive Displays.; There is a interface board from Embedded Artists.; It can handle graphic and text drawing and is using external fonts.

Who changed what in which revision?

UserRevisionLine numberNew contents of line
dreschpe 0:fedcef5319f5 1 /* mbed GraphicsDisplay Display Library Base Class
dreschpe 0:fedcef5319f5 2 * Copyright (c) 2007-2009 sford
dreschpe 0:fedcef5319f5 3 * Released under the MIT License: http://mbed.org/license/mit
dreschpe 0:fedcef5319f5 4 *
dreschpe 0:fedcef5319f5 5 * A library for providing a common base class for Graphics displays
dreschpe 0:fedcef5319f5 6 * To port a new display, derive from this class and implement
dreschpe 0:fedcef5319f5 7 * the constructor (setup the display), pixel (put a pixel
dreschpe 0:fedcef5319f5 8 * at a location), width and height functions. Everything else
dreschpe 0:fedcef5319f5 9 * (locate, printf, putc, cls, window, putp, fill, blit, blitbit)
dreschpe 0:fedcef5319f5 10 * will come for free. You can also provide a specialised implementation
dreschpe 0:fedcef5319f5 11 * of window and putp to speed up the results
dreschpe 0:fedcef5319f5 12 */
dreschpe 0:fedcef5319f5 13
dreschpe 0:fedcef5319f5 14 #ifndef MBED_GRAPHICSDISPLAY_H
dreschpe 0:fedcef5319f5 15 #define MBED_GRAPHICSDISPLAY_H
dreschpe 0:fedcef5319f5 16
dreschpe 0:fedcef5319f5 17 #include "TextDisplay.h"
dreschpe 0:fedcef5319f5 18
dreschpe 0:fedcef5319f5 19 class GraphicsDisplay : public TextDisplay {
dreschpe 0:fedcef5319f5 20
dreschpe 0:fedcef5319f5 21 public:
dreschpe 0:fedcef5319f5 22
dreschpe 0:fedcef5319f5 23 GraphicsDisplay(const char* name);
dreschpe 0:fedcef5319f5 24
dreschpe 0:fedcef5319f5 25 virtual void pixel(int x, int y, int colour) = 0;
dreschpe 0:fedcef5319f5 26 virtual int width() = 0;
dreschpe 0:fedcef5319f5 27 virtual int height() = 0;
dreschpe 0:fedcef5319f5 28
dreschpe 0:fedcef5319f5 29 virtual void window(int x, int y, int w, int h);
dreschpe 0:fedcef5319f5 30 virtual void putp(int colour);
dreschpe 0:fedcef5319f5 31
dreschpe 0:fedcef5319f5 32 virtual void cls();
dreschpe 0:fedcef5319f5 33 virtual void fill(int x, int y, int w, int h, int colour);
dreschpe 0:fedcef5319f5 34 virtual void blit(int x, int y, int w, int h, const int *colour);
dreschpe 0:fedcef5319f5 35 virtual void blitbit(int x, int y, int w, int h, const char* colour);
dreschpe 0:fedcef5319f5 36
dreschpe 0:fedcef5319f5 37 virtual void character(int column, int row, int value);
dreschpe 0:fedcef5319f5 38 virtual int columns();
dreschpe 0:fedcef5319f5 39 virtual int rows();
dreschpe 0:fedcef5319f5 40
dreschpe 0:fedcef5319f5 41 protected:
dreschpe 0:fedcef5319f5 42
dreschpe 0:fedcef5319f5 43 // pixel location
dreschpe 0:fedcef5319f5 44 short _x;
dreschpe 0:fedcef5319f5 45 short _y;
dreschpe 0:fedcef5319f5 46
dreschpe 0:fedcef5319f5 47 // window location
dreschpe 0:fedcef5319f5 48 short _x1;
dreschpe 0:fedcef5319f5 49 short _x2;
dreschpe 0:fedcef5319f5 50 short _y1;
dreschpe 0:fedcef5319f5 51 short _y2;
dreschpe 0:fedcef5319f5 52
dreschpe 0:fedcef5319f5 53 };
dreschpe 0:fedcef5319f5 54
dreschpe 0:fedcef5319f5 55 #endif