X-Git-Url: http://code.vuplus.com/gitweb/?a=blobdiff_plain;f=lib%2Fgdi%2Flcd.h;h=99f921b525e16434bf6cb4dcf8c952b6a508f8d4;hb=88bae399660a892a61882f59251d9359750d3d3b;hp=f2e707f035b6801852f316a40da91b279f5e6e1f;hpb=1e88da3ea994175689ab4d8edbc1fd809f1d6ad8;p=vuplus_dvbapp diff --git a/lib/gdi/lcd.h b/lib/gdi/lcd.h index f2e707f..99f921b 100644 --- a/lib/gdi/lcd.h +++ b/lib/gdi/lcd.h @@ -12,38 +12,52 @@ class eLCD { +#ifdef SWIG + eLCD(eSize size); + ~eLCD(); +#else protected: eSize res; unsigned char *_buffer; int lcdfd; int _stride; int locked; +#endif public: int lock(); void unlock(); int islocked() { return locked; } - + bool detected() { return lcdfd >= 0; } +#ifndef SWIG eLCD(eSize size); virtual ~eLCD(); - __u8 *buffer() { return (__u8*)_buffer; } int stride() { return _stride; } eSize size() { return res; } virtual void update()=0; +#endif }; class eDBoxLCD: public eLCD { static eDBoxLCD *instance; unsigned char inverted; + int is_oled; +#ifdef SWIG + eDBoxLCD(); + ~eDBoxLCD(); +#endif public: - static eDBoxLCD *getInstance(); - int eDBoxLCD::setLCDContrast(int contrast); - int eDBoxLCD::setLCDBrightness(int brightness); - void setInverted( unsigned char ); +#ifndef SWIG eDBoxLCD(); ~eDBoxLCD(); +#endif + static eDBoxLCD *getInstance(); + int setLCDContrast(int contrast); + int setLCDBrightness(int brightness); + void setInverted( unsigned char ); + bool isOled() const { return !!is_oled; } void update(); };