修复Rtmp复用器循环引用的bug

This commit is contained in:
xiongziliang
2018-10-29 10:53:08 +08:00
parent 05b51585cb
commit 3bf1a9fddb
4 changed files with 15 additions and 3 deletions

View File

@@ -45,6 +45,10 @@ RtmpDemuxer::RtmpDemuxer(const AMFValue &val) {
}
}
int RtmpDemuxer::getTrackCount(const AMFValue &metedata) {
return (int)(metedata["videocodecid"].type() != AMF_NULL) + (int)(metedata["audiocodecid"].type() != AMF_NULL);
}
bool RtmpDemuxer::inputRtmp(const RtmpPacket::Ptr &pkt) {
switch (pkt->typeId) {
case MSG_VIDEO: {