This commit is contained in:
xiongziliang
2020-04-18 16:05:49 +08:00
23 changed files with 896 additions and 65 deletions

View File

@@ -75,6 +75,9 @@ using namespace toolkit;
#define FLV_CODEC_AAC 10
#define FLV_CODEC_H264 7
#define FLV_CODEC_H265 12
#define FLV_CODEC_G711A 7
#define FLV_CODEC_G711U 8
namespace mediakit {

View File

@@ -61,7 +61,7 @@ bool RtmpDemuxer::inputRtmp(const RtmpPacket::Ptr &pkt) {
void RtmpDemuxer::makeVideoTrack(const AMFValue &videoCodec) {
//生成Track对象
_videoTrack = dynamic_pointer_cast<VideoTrack>(Factory::getTrackByAmf(videoCodec));
_videoTrack = dynamic_pointer_cast<VideoTrack>(Factory::getVideoTrackByAmf(videoCodec));
if (_videoTrack) {
//生成rtmpCodec对象以便解码rtmp
_videoRtmpDecoder = Factory::getRtmpCodecByTrack(_videoTrack);
@@ -78,7 +78,7 @@ void RtmpDemuxer::makeVideoTrack(const AMFValue &videoCodec) {
void RtmpDemuxer::makeAudioTrack(const AMFValue &audioCodec) {
//生成Track对象
_audioTrack = dynamic_pointer_cast<AudioTrack>(Factory::getTrackByAmf(audioCodec));
_audioTrack = dynamic_pointer_cast<AudioTrack>(Factory::getAudioTrackByAmf(audioCodec));
if (_audioTrack) {
//生成rtmpCodec对象以便解码rtmp
_audioRtmpDecoder = Factory::getRtmpCodecByTrack(_audioTrack);