xbmc/xbmc — pull request #2373 by juanfont (2013-03-05 08:45:29+00:00)
Title: Realtime streaming and interactive TV optimization parameters in advancedsettings.xml

For those formats with no headers (ie. mpegts), ffmpeg probes¹ the stream during $max_analyze_duration² microseconds (5.0 seconds by default) or $probesize³ bytes (default 5MB) in order to obtain information (codec, bitrate,...) about the media. For real-time multimedia streaming applications and interative TV services 5 seconds (or 5MB) are too much, given that for most cases 60ms of $max_analyze_duration and 100KB of $probesize is enough. This patch allows you to set those parameters in advancedsettings.xml.

If this patch is approved, advancedsettings.xml wiki page (http://wiki.xbmc.org/index.php?title=Advancedsettings.xml) should be updated with the new options (included in the new 'ffmpeg' element). Example:

400000
200000

___________________________
¹: This probing is done at libavformat avformat_find_stream_info() method http://ffmpeg.org/doxygen/trunk/group__lavf__decoding.html#gad42172e27cddafb81096939783b157bb
²: max_analyze_duration http://ffmpeg.org/doxygen/trunk/structAVFormatContext.html#aa1f733fdfa1655d9e6ccc80f6b926274
³: probesize http://ffmpeg.org/doxygen/trunk/structAVFormatContext.html#afcff2757459cf56050b2d908f46957b0