完善相对时间戳逻辑, 完善同步机制, 解决相对时间戳不同步的问题
默认禁止时间戳回退并设置最大跳跃幅度为300毫秒 rtsp恢复产生ntp时间戳 由于绝对时间戳可能跳跃回退,之前在求相对时间戳时会导致音视频不同步。 现在求相对时间戳逻辑经过修改,已经支持同步功能,所以恢复rtp ntp时间戳逻辑 Signed-off-by: Nashira <nashira@nashira.cn>
This commit is contained in:
parent
e81ff307c7
commit
1136bf4a00
|
|
@ -131,7 +131,9 @@ void RtspSession::onWholeRtspPacket(Parser &parser) {
|
||||||
string method = parser.method(); //提取出请求命令字
|
string method = parser.method(); //提取出请求命令字
|
||||||
_cseq = atoi(parser["CSeq"].data());
|
_cseq = atoi(parser["CSeq"].data());
|
||||||
if (_content_base.empty() && method != "GET") {
|
if (_content_base.empty() && method != "GET") {
|
||||||
_content_base = parser.url();
|
RtspUrl rtsp = RtspUrl();
|
||||||
|
rtsp.parse(parser.url());
|
||||||
|
_content_base = rtsp._url;
|
||||||
_media_info.parse(parser.fullUrl());
|
_media_info.parse(parser.fullUrl());
|
||||||
_media_info.schema = RTSP_SCHEMA;
|
_media_info.schema = RTSP_SCHEMA;
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue