summaryrefslogtreecommitdiff
path: root/device.h
diff options
context:
space:
mode:
authorKlaus Schmidinger <vdr@tvdr.de>2004-10-16 09:36:28 +0200
committerKlaus Schmidinger <vdr@tvdr.de>2004-10-16 09:36:28 +0200
commit6415cc900de3361925d22f879077be687fce3858 (patch)
tree98ab10cda016e125e33966e371ccfe01e5fd9bd1 /device.h
parent15030f6acece1060f9736f875fe3abbcf9392263 (diff)
downloadvdr-6415cc900de3361925d22f879077be687fce3858.tar.gz
vdr-6415cc900de3361925d22f879077be687fce3858.tar.bz2
Improved buffer handling
Diffstat (limited to 'device.h')
-rw-r--r--device.h16
1 files changed, 7 insertions, 9 deletions
diff --git a/device.h b/device.h
index 10bca28c..bec6bf5b 100644
--- a/device.h
+++ b/device.h
@@ -4,7 +4,7 @@
* See the main source file 'vdr.c' for copyright information and
* how to reach the author.
*
- * $Id: device.h 1.44 2004/06/19 08:50:37 kls Exp $
+ * $Id: device.h 1.45 2004/09/24 14:07:22 kls Exp $
*/
#ifndef __DEVICE_H
@@ -15,6 +15,7 @@
#include "filter.h"
#include "nit.h"
#include "pat.h"
+#include "ringbuffer.h"
#include "sdt.h"
#include "sections.h"
#include "thread.h"
@@ -437,20 +438,17 @@ public:
/// sure the returned data points to a TS packet and automatically
/// re-synchronizes after broken packets.
-class cTSBuffer {
+class cTSBuffer : public cThread {
private:
int f;
- int size;
int cardIndex;
- int tsRead;
- int tsWrite;
- uchar *buf;
- bool firstRead;
- int Used(void) { return tsRead <= tsWrite ? tsWrite - tsRead : size - tsRead + tsWrite; }
+ bool active;
+ bool delivered;
+ cRingBufferLinear *ringBuffer;
+ virtual void Action(void);
public:
cTSBuffer(int File, int Size, int CardIndex);
~cTSBuffer();
- int Read(void);
uchar *Get(void);
};