[FFmpeg-devel] [PATCH] raw_read_header fix
Alex Beregszaszi
alex
Sat Jul 14 01:39:59 CEST 2007
Hi,
> I've seen those too. The reason the main ffmpeg program doesn't crash
> is that it sets a default sample rate of 44.1 kHz before opening the
> input file.
>
> I'm not sure what the best solution to this is.
I'm investigating since then and my findings are that avoiding time_base
related computations in av_find_stream_info will try decoding.
- if (av_rescale_q(codec_info_duration[st->index], st->time_base,
AV_TIME_BASE_Q) >= ic->max_analyze_duration) {
+ if (st->time_base.den &&
av_rescale_q(codec_info_duration[st->index], st->time_base,
AV_TIME_BASE_Q) >= ic->max_analyze_duration) {
Well, if try_decode_frame fails, why shouldn't we give up? And ulaw/alaw
decoder should fail if no sampling rate is specified as there is no way
for storing such information in the format itself.
--
Alex
More information about the ffmpeg-devel
mailing list