avformat/avidec: Speed up keyframe detection code
authorMichael Niedermayer <michaelni@gmx.at>
Tue, 22 Apr 2014 02:00:32 +0000 (04:00 +0200)
committerMichael Niedermayer <michaelni@gmx.at>
Tue, 22 Apr 2014 02:33:20 +0000 (04:33 +0200)
Fixes Ticket3531

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
libavformat/avidec.c

index 84d6ed1..562a255 100644 (file)
@@ -1413,7 +1413,7 @@ FF_ENABLE_DEPRECATION_WARNINGS
                 AVIndexEntry *e;
                 int index;
 
-                index = av_index_search_timestamp(st, ast->frame_offset, 0);
+                index = av_index_search_timestamp(st, ast->frame_offset, AVSEEK_FLAG_ANY);
                 e     = &st->index_entries[index];
 
                 if (index >= 0 && e->timestamp == ast->frame_offset) {