Commit e42b1520 authored by Max Kellermann's avatar Max Kellermann

decoder/faad: eliminate the adts_find_frame() loop

This loop is completely unnecessary. We just need to find the first ADTS frame and feed it into NeAACDecInit().
parent da599e3f
......@@ -365,11 +365,8 @@ faad_stream_decode(Decoder &mpd_decoder, InputStream &is,
{
const float total_time = faad_song_duration(buffer, is);
while (!decoder_buffer_is_full(buffer) && !is.LockIsEOF() &&
decoder_get_command(mpd_decoder) == DecoderCommand::NONE) {
adts_find_frame(buffer);
decoder_buffer_fill(buffer);
}
if (adts_find_frame(buffer) == 0)
return;
/* initialize it */
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment