[vlc-devel] [PATCH] speex: Fix DecodeRtpSpeexPacket function PTS handling error
Yupeng Chang
changyp6 at gmail.com
Wed Jul 29 12:48:31 CEST 2015
Hi
Thank you for reviewing my patch.
Please see my reply in blue below.
On Wed, Jul 29, 2015 at 5:01 PM, Rémi Denis-Courmont <remi at remlab.net>
wrote:
> Hello,
>
> Le 2015-07-28 21:55, Yupeng Chang a écrit :
>>
>> at line 708, the orginal code is
>> if ( !date_Get( &p_sys->end_date ) )
>> date_Set( &p_sys->end_date, p_speex_bit_block->i_dts );
>>
>> This is not correct.
>> When end_date is 0, the first packet's PTS will be set to end_date,
>> after RTCP sync,
>> the packet's PTS/DTS will be much different than the first packet's
>> PTS/DTS,
>> if the end_date is not updated, decoder will always report error message
>
>
> I think this code was copied from the non-RTP version above. I think you
are
> right that it will break if the first RTCP SR compound is received after
the
> first RTP packet (or if NTP/RTP time correlation is modified later).
>
> In my opinion, Speex over RTP should not be treated as a codec of its own
> anyway. RTP depayloading and RTCP processing belongs in the demuxer.
>
>> After I remove if ( !date_Get( &p_sys->end_date ) ), speex RTP playing
>> back works perfect with VLC.
>
>
> That would probably work as a stop-gap solution. But then I guess you
should
> remove the date_Increment() call. In fact, you should probably remove
> date_*() calls completely and just copy the i_pts value from input block
to
> output block.
OK, I'll remove date_*() calls and make a new patch.
> Ideally, the RTP processing would be moved out of the codec plugin into
the
> RTP plugin, though. Are you using live555?
I haven't studied VLC source code, so I'm lack of some architecture
knowledge of some plugins.
I think I can refine my patch and give a quick fix on this obvious bug.
I implemented my own RTSP server, and I use VLC as the standard client
player to test my RTSP server.
So, I don't use live555 library.
> --
> Rémi Denis-Courmont
> http://www.remlab.net/
>
> _______________________________________________
> vlc-devel mailing list
> To unsubscribe or modify your subscription options:
> https://mailman.videolan.org/listinfo/vlc-devel
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.videolan.org/pipermail/vlc-devel/attachments/20150729/fff96609/attachment.html>
More information about the vlc-devel
mailing list