[FFmpeg-devel] [RFC] rtpdec: Reordering RTP packets

Martin Storsjö martin
Sun May 16 16:25:30 CEST 2010


On Sun, 16 May 2010, Ronald S. Bultje wrote:

> On May 16, 2010, at 4:23 AM, Martin Storsj? <martin at martin.st> wrote:
> > On Sat, 15 May 2010, Ronald S. Bultje wrote:
> >> On Sat, May 15, 2010 at 6:02 PM, Martin Storsj? <martin at martin.st> 
> >>  wrote:
> >>> Even if this isn't intentional, it may be beneficial for us to do  
> >>> a little
> >>> reordering of packets, if using UDP transport.
> >>
> >> Absolutely.
> >>
> >> I'll review the patch later, but this is a big FIXME (and has been  
> >> for
> >> a long while), so this is very welcome.
> >
> > This patch still is quite a hack, to test that this cured the problems
> > with that particular video. This one always buffers a fixed number of
> > packets before returning any data. Preferrably, we would buffer up  
> > as many
> > as needed, and if we suddenly have many consecutive packets, we would
> > return the ones that are in order without trying to receive any more
> > packets inbetween. That requires some new interface between rtpdec and
> > rtsp, though.
> 
> Return 1 should be enough, with some smart code in rtpdec.c.

Yeah, I realized this a while after sending the last mail. :-)

> Also, logging on packet drops/skips would be useful.

Absolutely.

I'll try to do a more proper patch soon, this was mostly to get to know 
whether this is desired at all, and to see if Luca knows any good reason 
why the sender would intentionally send data this way.

// Martin



More information about the ffmpeg-devel mailing list