mirror of
https://github.com/ZLMediaKit/ZLMediaKit.git
synced 2026-07-02 08:17:33 +08:00
重写jitter buffer算法,修复seq回环时可能丢包的bug
This commit is contained in:
@@ -652,15 +652,14 @@ void WebRtcTransportImp::onRtcConfigure(RtcConfigure &configure) const {
|
||||
|
||||
///////////////////////////////////////////////////////////////////
|
||||
|
||||
class RtpChannel
|
||||
: public RtpTrackImp
|
||||
, public std::enable_shared_from_this<RtpChannel> {
|
||||
class RtpChannel : public RtpTrackImp, public std::enable_shared_from_this<RtpChannel> {
|
||||
public:
|
||||
RtpChannel(EventPoller::Ptr poller, RtpTrackImp::OnSorted cb, function<void(const FCI_NACK &nack)> on_nack) {
|
||||
_poller = std::move(poller);
|
||||
_on_nack = std::move(on_nack);
|
||||
setOnSorted(std::move(cb));
|
||||
|
||||
//设置jitter buffer参数
|
||||
RtpTrackImp::setParams(1024, NackContext::kNackMaxMS, 512);
|
||||
_nack_ctx.setOnNack([this](const FCI_NACK &nack) { onNack(nack); });
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user