summaryrefslogtreecommitdiff
path: root/dvbosd.h
diff options
context:
space:
mode:
authorKlaus Schmidinger <kls (at) cadsoft (dot) de>2000-10-03 18:00:00 +0200
committerKlaus Schmidinger <kls (at) cadsoft (dot) de>2000-10-03 18:00:00 +0200
commitef8fe3f04c30caedeb17b11ac275581539f039c7 (patch)
tree40a00f075c4fc94b95fd070077e89a1916923789 /dvbosd.h
parent7e4b4d290570aee1d24241b0e0ac10e7c8148a36 (diff)
downloadvdr-patch-lnbsharing-ef8fe3f04c30caedeb17b11ac275581539f039c7.tar.gz
vdr-patch-lnbsharing-ef8fe3f04c30caedeb17b11ac275581539f039c7.tar.bz2
Version 0.65vdr-0.65
- Modified LIRC interface to better handle repeat function. - Faster OSD by first writing into a bitmap and then sending the entire bitmap to the DVB driver at once (requires the patch 'dvb.c.071.diff' to be applied against the version 0.71 DVB driver file 'dvb.c'). - When switching channels the channel is now immediately displayed, and the current/next information is shown as soon as it becomes available. - No longer displaying the year in the 'Recordings' menu to saves space for the title. - The 'Recordings' menu now displays a '*' to indicate new recordings. - Added the description of the timers.conf file to the FORMATS file (thanks to Bastian Guse). - Displaying as much as possible of the current/next info (dropping characters that would display only partially). - In normal viewing mode the '0' key now toggles between the current and the previous channel.
Diffstat (limited to 'dvbosd.h')
-rw-r--r--dvbosd.h74
1 files changed, 74 insertions, 0 deletions
diff --git a/dvbosd.h b/dvbosd.h
new file mode 100644
index 0000000..f7a5363
--- /dev/null
+++ b/dvbosd.h
@@ -0,0 +1,74 @@
+/*
+ * dvbosd.h: Interface to the DVB On Screen Display
+ *
+ * See the main source file 'vdr.c' for copyright information and
+ * how to reach the author.
+ *
+ * $Id: dvbosd.h 1.1 2000/10/01 15:00:00 kls Exp $
+ */
+
+#ifndef __DVBOSD_H
+#define __DVBOSD_H
+
+// FIXME: these should be defined in ../DVB/driver/dvb.h!!!
+typedef unsigned int __u32;
+typedef unsigned short __u16;
+typedef unsigned char __u8;
+
+#if defined(DEBUG_OSD) || defined(REMOTE_KBD)
+#include <ncurses.h>
+#endif
+#include <stdio.h>
+#include <dvb.h>
+#include "font.h"
+
+enum eDvbColor {
+#ifndef DEBUG_OSD
+ clrTransparent,
+#endif
+ clrBackground,
+#ifdef DEBUG_OSD
+ clrTransparent = clrBackground,
+ clrBlack = clrBackground,
+#else
+ clrBlack,
+#endif
+ clrRed,
+ clrGreen,
+ clrYellow,
+ clrBlue,
+ clrMagenta,
+ clrCyan,
+ clrWhite,
+ };
+
+class cBitmap {
+private:
+ cFont *font;
+protected:
+ int width, height;
+ char *bitmap;
+ int dirtyX1, dirtyY1, dirtyX2, dirtyY2;
+ void Clean(void);
+public:
+ cBitmap(int Width, int Height);
+ virtual ~cBitmap();
+ void SetFont(eDvbFont Font);
+ bool Dirty(void);
+ void SetPixel(int x, int y, eDvbColor Color);
+ void Text(int x, int y, const char *s, eDvbColor ColorFg = clrWhite, eDvbColor ColorBg = clrBackground);
+ void Fill(int x1, int y1, int x2, int y2, eDvbColor Color);
+ void Clear(void);
+ };
+
+class cDvbOsd : public cBitmap {
+private:
+ int videoDev;
+ void Cmd(OSD_Command cmd, int color = 0, int x0 = 0, int y0 = 0, int x1 = 0, int y1 = 0, const void *data = NULL);
+public:
+ cDvbOsd(int VideoDev, int x1, int y1, int x2, int y2, int Bpp);
+ ~cDvbOsd();
+ void Flush(void);
+ };
+
+#endif //__DVBOSD_H