整理MediaSource派生类

修复转协议或录制时忽然Track的问题
This commit is contained in:
xiongziliang
2019-12-26 11:53:19 +08:00
parent 806747a9d5
commit 3830792c57
15 changed files with 172 additions and 150 deletions

View File

@@ -263,7 +263,7 @@ void RtspSession::handleReq_ANNOUNCE(const Parser &parser) {
_strSession = makeRandStr(12);
_aTrackInfo = sdpParser.getAvailableTrack();
_pushSrc = std::make_shared<RtspToRtmpMediaSource>(_mediaInfo._vhost,_mediaInfo._app,_mediaInfo._streamid);
_pushSrc = std::make_shared<RtspMediaSourceImp>(_mediaInfo._vhost,_mediaInfo._app,_mediaInfo._streamid);
_pushSrc->setListener(dynamic_pointer_cast<MediaSourceEvent>(shared_from_this()));
_pushSrc->setSdp(sdpParser.toString());