Remove the remaining allocations in the AV paths

This commit is contained in:
Cameron Gutman 2014-07-12 13:38:28 -07:00
parent d2f8ee8b81
commit d1ef912984
3 changed files with 2 additions and 0 deletions

Binary file not shown.

View File

@ -159,6 +159,7 @@ public class AndroidCpuDecoderRenderer implements VideoDecoderRenderer {
du = depacketizer.pollNextDecodeUnit(); du = depacketizer.pollNextDecodeUnit();
if (du != null) { if (du != null) {
submitDecodeUnit(du); submitDecodeUnit(du);
depacketizer.freeDecodeUnit(du);
} }
long diff = nextFrameTime - System.currentTimeMillis(); long diff = nextFrameTime - System.currentTimeMillis();

View File

@ -177,6 +177,7 @@ public class MediaCodecDecoderRenderer implements VideoDecoderRenderer {
du = depacketizer.pollNextDecodeUnit(); du = depacketizer.pollNextDecodeUnit();
if (du != null) { if (du != null) {
submitDecodeUnit(du); submitDecodeUnit(du);
depacketizer.freeDecodeUnit(du);
} }
int outIndex = videoDecoder.dequeueOutputBuffer(info, 0); int outIndex = videoDecoder.dequeueOutputBuffer(info, 0);