/* compute the bitrate */
double bitrate = (double) filesize * 8.0 * AV_TIME_BASE /
(double) ic->duration;
- if (bitrate >= 0 && bitrate <= INT_MAX)
+ if (bitrate >= 0 && bitrate <= INT64_MAX)
ic->bit_rate = bitrate;
}
}
(double) st->duration / AV_TIME_BASE);
}
av_log(ic, AV_LOG_TRACE,
- "stream: start_time: %0.3f duration: %0.3f bitrate=%d kb/s\n",
+ "stream: start_time: %0.3f duration: %0.3f bitrate=%"PRId64" kb/s\n",
(double) ic->start_time / AV_TIME_BASE,
(double) ic->duration / AV_TIME_BASE,
- ic->bit_rate / 1000);
+ (int64_t)ic->bit_rate / 1000);
}
}
// new streams might appear, no options for those
int orig_nb_streams = ic->nb_streams;
int flush_codecs;
-#if FF_API_PROBESIZE_32
- int64_t max_analyze_duration = ic->max_analyze_duration2;
-#else
int64_t max_analyze_duration = ic->max_analyze_duration;
-#endif
int64_t max_stream_analyze_duration;
int64_t max_subtitle_analyze_duration;
-#if FF_API_PROBESIZE_32
- int64_t probesize = ic->probesize2;
-#else
int64_t probesize = ic->probesize;
-#endif
- if (!max_analyze_duration)
- max_analyze_duration = ic->max_analyze_duration;
- if (ic->probesize)
- probesize = ic->probesize;
flush_codecs = probesize > 0;
av_opt_set(ic, "skip_clear", "1", AV_OPT_SEARCH_CHILDREN);
max_analyze_duration = 5*AV_TIME_BASE;
max_subtitle_analyze_duration = 30*AV_TIME_BASE;
if (!strcmp(ic->iformat->name, "flv"))
- max_stream_analyze_duration = 30*AV_TIME_BASE;
+ max_stream_analyze_duration = 90*AV_TIME_BASE;
}
if (ic->pb)
if (t >= limit) {
av_log(ic, AV_LOG_VERBOSE, "max_analyze_duration %"PRId64" reached at %"PRId64" microseconds st:%d\n",
- max_analyze_duration,
+ limit,
t, pkt->stream_index);
if (ic->flags & AVFMT_FLAG_NOBUFFER)
av_packet_unref(pkt);