删除冗余设计

This commit is contained in:
xiongziliang
2019-12-26 09:43:44 +08:00
parent 8b23f01509
commit 761a665b1b
11 changed files with 33 additions and 83 deletions

View File

@@ -40,8 +40,6 @@ AACFrame::Ptr AACRtmpDecoder::obtainFrame() {
}
bool AACRtmpDecoder::inputRtmp(const RtmpPacket::Ptr &pkt, bool key_pos) {
RtmpCodec::inputRtmp(pkt, false);
if (pkt->isCfgFrame()) {
_aac_cfg = pkt->getAacCfg();
return false;
@@ -79,8 +77,6 @@ AACRtmpEncoder::AACRtmpEncoder(const Track::Ptr &track) {
}
void AACRtmpEncoder::inputFrame(const Frame::Ptr &frame) {
RtmpCodec::inputFrame(frame);
if(_aac_cfg.empty()){
if(frame->prefixSize() >= 7){
//包含adts头,从adts头获取aac配置信息