On 05/11/2011 07:54 PM, Uoti Urpala wrote:
On Tue, 2011-05-10 at 15:02 +0200, Vladimir Pantelic wrote:
Uoti Urpala wrote:
Disabling the utils.c fallback for asf should be enough. I'm not posting
attached are 2 patches that both solve the issue, one makes ASF cleanup
after util.c falls back to binary search,
This makes little sense IMO. The seek method of the asf demuxer already
uses binary seeking machinery itself when appropriate. Trying to support
outside binary search calls that are known to have only negative effects
seems wrong.
atm the asf logic is:
if( index_exists ) {
index = search_by_index()
if( index < 0 ) {
return -1;
}
// index success
} else {
try binary search
...
}
maybe it should be:
if( index_exists ) {
index = search_by_index()
if( index >= 0 ) {
// index success
...
return ...;
}
}
// no index or index search fail, try binary
try binary search
...
and of course, no more fallback from util.c as in patch #2
the other one introduces a new
flag that prevents util.c from doing so.
But it still calls av_seek_frame_generic(). Is that really any more
appropriate, even if it doesn't happen to trigger visible problems now?
right, I was about to also add a AVFMT_NOGENSEARCH flag but then left it
out to have a "minimal" patch. the generic search again falls back to
the index and fails as much as the index search inside asf...
or one flag that disables both fallbacks.
_______________________________________________
libav-devel mailing list
[email protected]
https://lists.libav.org/mailman/listinfo/libav-devel