Speed up SimpleDecodingSource

SimpleDecodingSource was waiting up to 5 milliseconds for each input
buffer, when it should not have been waiting at all, and instead
just check if there's an output buffer. This greatly increases
throughput for files with small buffers such as audio files, e.g.
a 6x speedup was observed for ogg and mp3 test streams.

Test: stagefright
Change-Id: If9fc91b823442926e8452d0e6cf95735b7248596
gugelfrei
Marco Nelissen 5 years ago
parent a161bbe3bd
commit 78c670e69c

@ -36,7 +36,7 @@
using namespace android;
const int64_t kTimeoutWaitForOutputUs = 500000; // 0.5 seconds
const int64_t kTimeoutWaitForInputUs = 5000; // 5 milliseconds
const int64_t kTimeoutWaitForInputUs = 0; // don't wait
const int kTimeoutMaxRetries = 20;
//static

Loading…
Cancel
Save