From 8d2d1e135cb1da6580e8cd3d20e8ac633d5bd2ff Mon Sep 17 00:00:00 2001 From: xiongziliang <771730766@qq.com> Date: Wed, 29 Sep 2021 00:25:34 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E6=94=B9rtsp=E7=82=B9=E6=92=ADntp?= =?UTF-8?q?=E6=97=B6=E9=97=B4=E6=88=B3?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/Rtsp/RtspMuxer.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/Rtsp/RtspMuxer.cpp b/src/Rtsp/RtspMuxer.cpp index 037567e1..831dd198 100644 --- a/src/Rtsp/RtspMuxer.cpp +++ b/src/Rtsp/RtspMuxer.cpp @@ -28,8 +28,8 @@ void RtspMuxer::onRtp(RtpPacket::Ptr in, bool is_key) { //rtp拦截入口,此处统一赋值ntp in->ntp_stamp = _ntp_stamp[in->type]; } else { - //点播情况下设置ntp时间戳为rtp时间戳 - in->ntp_stamp = in->getStamp() * uint64_t(1000) / in->sample_rate; + //点播情况下设置ntp时间戳为rtp时间戳加基准ntp时间戳 + in->ntp_stamp = _ntp_stamp_start + (in->getStamp() * uint64_t(1000) / in->sample_rate); } _rtpRing->write(std::move(in), is_key); }