[FFmpeg-cvslog] r25404 - trunk/libavformat/rtpdec.c

Martin Storsjö martin
Fri Oct 8 23:58:29 CEST 2010


On Fri, 8 Oct 2010, Ronald S. Bultje wrote:

> Hi,
> 
> On Fri, Oct 8, 2010 at 4:40 AM, mstorsjo <subversion at mplayerhq.hu> wrote:
> > Author: mstorsjo
> > Date: Fri Oct ?8 10:40:08 2010
> > New Revision: 25404
> >
> > Log:
> > rtpdec: Set prev_ret properly when parsing more data from mpegts RTP packets
> 
> I'm not a big fan of this, I'm quit sure most of these aren't strictly
> needed. Can't prev_ret be a cache variable only for the one case where
> prev_ret and the actual return value are different, as originally
> intended, and the rest be handled regardless of its value? We didn't
> need to store the last return value previously either, and it worked
> fine...

Yes, but earlier, we only had to ask the depacketizer to return more data, 
now we need to know whether to ask the depacketizer for more data, or to 
use the next packet from the queue. On the other hand, perhaps we could 
just skip that and always try the depacketizer first, then check the queue 
if the depacketizer didn't return anything.

Or just store the return value in a different way, on a different place 
(an outer wrapping level?) so that we don't need to litter the code with 
these statements.

I'll think about it.

// Martin



More information about the ffmpeg-cvslog mailing list