完善mpegts/ps容器对aac音频的兼容: #1801

This commit is contained in:
ziyue 2022-07-29 18:05:16 +08:00
parent ace989d378
commit afcf247464

View File

@ -123,6 +123,7 @@ void DecoderImp::onStream(int stream, int codecid, const void *extra, size_t byt
break;
}
case PSI_STREAM_MPEG4_AAC :
case PSI_STREAM_AAC: {
onTrack(std::make_shared<AACTrack>());
break;
@ -182,6 +183,7 @@ void DecoderImp::onDecode(int stream,int codecid,int flags,int64_t pts,int64_t d
break;
}
case PSI_STREAM_MPEG4_AAC :
case PSI_STREAM_AAC: {
uint8_t *ptr = (uint8_t *)data;
if(!(bytes > 7 && ptr[0] == 0xFF && (ptr[1] & 0xF0) == 0xF0)){