[Live-devel] 答复: how to get dts in LIVE555 Streaming Media

夏江龙 xiajl at inspur.com
Thu Feb 26 02:16:55 PST 2015


Thanks for quick reply Ross,

It’s useful to me.

So how to compute dts? set dts=0,  auto increase(plus 1 on each h264 frame call back)?  Or set dts=0, dts+=1000/fps?

Because I want to package the h264 NAL units into  RTMP,  so I need the dts and pts information.

A thousand thanks.


发件人: live-devel [mailto:live-devel-bounces at ns.live555.com] 代表 Ross Finlayson
发送时间: 2015年2月26日 17:05
收件人: LIVE555 Streaming Media - development & use
主题: Re: [Live-devel] how to get dts in LIVE555 Streaming Media

I am using testRTSPClient to connect rtsp server,then get h264 video frame,in the "DummySink::afterGettingFrame()" function i already get h264 data and pts(presentationTime timestamp),however,i want to get dts(decoding time stamp) also,but where is the dts?

The DTS (decoding time stamp) is not carried in the RTP stream.  Instead, it is the job of the receiver’s decoder to compute this.

Note that the incoming H.264 NAL units (as in all RTP video streams) arrive in 'decoding order’ (i.e., the order in which they are to be fed into the decoder), not ‘display order'.  This means, for example, that it’s possible (if the video stream contains ‘B frames’) for the NAL units’ ‘presentation times’ to be in non-monotonic order (i.e., sometimes decreasing).

Because you know that the incoming NAL units are in ‘decoding order’, then your decoder should be able to compute the ‘decoding time stamp’ from the ‘presentation time stamp’, if desired.

Ross Finlayson
Live Networks, Inc.
http://www.live555.com/

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.live555.com/pipermail/live-devel/attachments/20150226/3ea4a6f3/attachment.html>


More information about the live-devel mailing list