[vlc-devel] commit: RTP: avoid loosing the first received packet ( Rémi Denis-Courmont )
git version control
git at videolan.org
Sun Jun 29 19:40:00 CEST 2008
vlc | branch: master | Rémi Denis-Courmont <rdenis at simphalempin.com> | Sun Jun 29 20:41:33 2008 +0300| [425a85df64f1c1671ea9536f0140a611a1e0d7a5]
RTP: avoid loosing the first received packet
> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=425a85df64f1c1671ea9536f0140a611a1e0d7a5
---
modules/demux/rtpsession.c | 7 +++++++
1 files changed, 7 insertions(+), 0 deletions(-)
diff --git a/modules/demux/rtpsession.c b/modules/demux/rtpsession.c
index 62c24fd..ccad284 100644
--- a/modules/demux/rtpsession.c
+++ b/modules/demux/rtpsession.c
@@ -268,6 +268,13 @@ rtp_receive (demux_t *demux, rtp_session_t *session, block_t *block)
tab[session->srcc++] = src;
}
+ /* Be optimistic for the first packet. Certain codec, such as Vorbis
+ * do not like loosing the first packet(s), so we cannot just wait
+ * for proper sequence synchronization. And we don't want to assume that
+ * the sender starts at seq=0 either. */
+ if (src->blocks == NULL)
+ src->max_seq = seq - p_sys->max_dropout;
+
/* Check sequence number */
/* NOTE: the sequence number is per-source,
* but is independent from the payload type. */
More information about the vlc-devel
mailing list