add addDelegate with std::function, remove FrameWriterInterfaceHelper

This commit is contained in:
cqm
2022-11-01 08:54:56 +08:00
parent d2c64b1f09
commit ac3d7bd21f
8 changed files with 25 additions and 23 deletions

View File

@@ -136,10 +136,10 @@ bool GB28181Process::inputRtp(bool, const char *data, size_t data_len) {
}
}
// 设置frame回调
_rtp_decoder[pt]->addDelegate(std::make_shared<FrameWriterInterfaceHelper>([this](const Frame::Ptr &frame) {
_rtp_decoder[pt]->addDelegate([this](const Frame::Ptr &frame) {
onRtpDecode(frame);
return true;
}));
});
}
return ref->inputRtp(TrackVideo, (unsigned char *)data, data_len);