summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--tools/udp_buffer.h13
-rw-r--r--xine_input_vdr_net.h16
2 files changed, 19 insertions, 10 deletions
diff --git a/tools/udp_buffer.h b/tools/udp_buffer.h
index 6284349a..25f8ca17 100644
--- a/tools/udp_buffer.h
+++ b/tools/udp_buffer.h
@@ -4,7 +4,7 @@
* See the main source file 'xineliboutput.c' for copyright information and
* how to reach the author.
*
- * $Id: udp_buffer.h,v 1.3 2006-12-14 12:30:25 phintuka Exp $
+ * $Id: udp_buffer.h,v 1.4 2009-02-10 15:15:04 phintuka Exp $
*
*/
@@ -14,7 +14,7 @@
#include <stdint.h>
#include "../xine_input_vdr_net.h" // frame headers
-
+#include "ts.h"
#define UDP_BUFFER_SIZE 0x100 // 2^n
#define UDP_BUFFER_MASK 0xff // 2^n - 1
@@ -109,7 +109,14 @@ class cUdpBackLog
// RTP header
header->rtp_hdr.raw[0] = RTP_VERSION_BYTE | RTP_HDREXT_BIT;
- header->rtp_hdr.raw[1] = RTP_PAYLOAD_TYPE;
+#if VDRVERSNUM >= 10701
+ if (DATA_IS_TS(Data))
+ header->rtp_hdr.raw[1] = RTP_PAYLOAD_TYPE_TS;
+ else
+ header->rtp_hdr.raw[1] = RTP_PAYLOAD_TYPE_PES;
+#else
+ header->rtp_hdr.raw[1] = RTP_PAYLOAD_TYPE_PES;
+#endif
header->rtp_hdr.seq = htons(m_RtpSeqNo & 0xFFFF);
/*header->rtp_hdr.ts = htonl((uint32_t)(RtpScr.Now() & 0xffffffff));*/
/*header->rtp_hdr.ssrc = htonl(m_ssrc);*/
diff --git a/xine_input_vdr_net.h b/xine_input_vdr_net.h
index da93476d..54dd00e5 100644
--- a/xine_input_vdr_net.h
+++ b/xine_input_vdr_net.h
@@ -4,7 +4,7 @@
* See the main source file 'xineliboutput.c' for copyright information and
* how to reach the author.
*
- * $Id: xine_input_vdr_net.h,v 1.9 2007-03-29 14:22:27 phintuka Exp $
+ * $Id: xine_input_vdr_net.h,v 1.10 2009-02-10 15:15:03 phintuka Exp $
*
*/
@@ -146,13 +146,15 @@ typedef struct stream_rtp_header_impl {
} PACKED stream_rtp_header_impl_t;
-#define RTP_VERSION 2
-#define RTP_MARKER_BIT 0x80
-#define RTP_HDREXT_BIT 0x10
-#define RTP_PAYLOAD_TYPE 96 /* application */
+#define RTP_VERSION 2
+#define RTP_MARKER_BIT 0x80
+#define RTP_HDREXT_BIT 0x10
+#define RTP_PAYLOAD_TYPE_PES 96 /* application */
+#define RTP_PAYLOAD_TYPE_TS 33 /* MPEG-TS */
-#define RTP_VERSION_BYTE (RTP_VERSION<<6)
-#define RTP_PAYLOAD_TYPE_M (RTP_PAYLOAD_TYPE|RTP_MARKER_BIT)
+#define RTP_VERSION_BYTE (RTP_VERSION<<6)
+#define RTP_PAYLOAD_TYPE_PES_M (RTP_PAYLOAD_TYPE_PES|RTP_MARKER_BIT)
+#define RTP_PAYLOAD_TYPE_TS_M (RTP_PAYLOAD_TYPE_TS |RTP_MARKER_BIT)
#define RTP_HEADER_EXT_X_SIZE 3 /* dwords, not counting stream_rtp_header_ext_t */
#define RTP_HEADER_EXT_X_TYPE 0x54d3