优化frame性能及整理代码

This commit is contained in:
xia-chu
2021-02-05 11:51:16 +08:00
parent c5cfbce241
commit 62ba87dd0f
33 changed files with 847 additions and 855 deletions

View File

@@ -74,9 +74,7 @@ AACRtpDecoder::AACRtpDecoder() {
void AACRtpDecoder::obtainFrame() {
//从缓存池重新申请对象,防止覆盖已经写入环形缓存的对象
_frame = ResourcePoolHelper<FrameImp>::obtainObj();
_frame->_prefix_size = 0;
_frame->_buffer.clear();
_frame = FrameImp::create();
_frame->_codec_id = CodecAAC;
}