aboutsummaryrefslogtreecommitdiffstats
path: root/libavformat/utils.c
Commit message (Collapse)AuthorAgeFilesLines
...
| * lavf: remove disabled FF_API_SET_PTS_INFO cruftAnton Khirnov2012-01-271-8/+0
| |
| * lavf: remove disabled FF_API_SEEK_PUBLIC cruftAnton Khirnov2012-01-271-25/+0
| |
| * lavf: remove disabled FF_API_NEW_STREAM cruftAnton Khirnov2012-01-271-10/+0
| |
| * lavf: remove disabled FF_API_PKT_DUMP cruftAnton Khirnov2012-01-271-16/+0
| |
| * lavf: remove disabled FF_API_FIND_INFO_TAG cruftAnton Khirnov2012-01-271-9/+0
| |
| * lavf: remove disabled FF_API_PARSE_DATE cruftAnton Khirnov2012-01-271-11/+0
| |
| * lavf: remove disabled FF_API_DUMP_FORMAT cruftAnton Khirnov2012-01-271-10/+0
| |
| * lavf: remove disabled FF_API_FORMAT_PARAMETERS cruftAnton Khirnov2012-01-271-155/+0
| | | | | | | | | | Also remove now unused AVFormatParameters struct and AVOutputFormat.set_parameters().
| * lavf: remove AVFormatParameters from AVFormatContext.read_header signatureAnton Khirnov2012-01-271-2/+1
| |
* | Merge remote-tracking branch 'qatar/master'n0.11-devMichael Niedermayer2012-01-271-5/+12
|\| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * qatar/master: smacker: Sanity check huffman tables found in the headers. smacker: remove dead store qdm2: Check data block size for bytes to bits overflow. mxfdec: Fix files with essence containers larger than 2 GiB. mxfdec: Employ correct printf conversion specifiers for POSIX int types. vc1: always read the bfraction element for interlaced fields fate: add XWD image regression test lavf: prevent infinite loops while flushing in avformat_find_stream_info matroskadec: Pad AAC extradata. ismindex: Fix build on mingw Conflicts: libavformat/mxfdec.c libavformat/utils.c tests/lavf-regression.sh Merged-by: Michael Niedermayer <michaelni@gmx.at>
| * lavf: prevent infinite loops while flushing in avformat_find_stream_infoJanne Grunau2012-01-261-8/+14
| | | | | | | | | | | | | | | | | | If no data was seen for a stream decoder are returning 0 when fed with empty packets for flushing. We can stop flushing when the decoder does not return delayed delayed frames anymore. Changes try_decode_frame() return value to got_picture or negative error. CC: libav-stable@libav.org
* | Merge remote-tracking branch 'qatar/master'Michael Niedermayer2012-01-261-1/+9
|\| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * qatar/master: (22 commits) wma: Clip WMA1 and WMA2 frame length to 11 bits. movenc: Don't require frame_size to be set for modes other than mov doc: Update APIchanges with info on muxer flushing movenc: Reindent a block tools: Remove some unnecessary #undefs. rv20: prevent calling ff_h263_decode_mba() with unset height/width tools: K&R reformatting cosmetics Ignore generated aviocat and ismindex tools. build: Automatically include architecture-specific library Makefile snippets. indeo5: prevent null pointer dereference on broken files pktdumper: Use usleep instead of sleep cosmetics: Remove some unnecessary block braces. Drop unnecessary prefix from *sink* variable and struct names. Add a tool for creating smooth streaming manifests movdec: Calculate an average bit rate for fragmented streams, too movenc: Write the sample rate instead of time scale in the stsd atom movenc: Add a separate ismv/isma (smooth streaming) muxer movenc: Allow the caller to decide on fragmentation libavformat: Add a flag for muxers that support write_packet(NULL) for flushing movenc: Add support for writing fragmented mov files ... Conflicts: Changelog cmdutils.c cmdutils.h doc/APIchanges ffmpeg.c ffplay.c libavfilter/Makefile libavformat/Makefile libavformat/avformat.h libavformat/movenc.c libavformat/movenc.h libavformat/version.h tools/graph2dot.c Merged-by: Michael Niedermayer <michaelni@gmx.at>
| * libavformat: Add a flag for muxers that support write_packet(NULL) for flushingMartin Storsjö2012-01-251-1/+9
| | | | | | | | Signed-off-by: Martin Storsjö <martin@martin.st>
* | Merge remote-tracking branch 'qatar/master'Michael Niedermayer2012-01-211-10/+18
|\| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * qatar/master: Add a tool that uses avio to read and write, doing a plain copy of data ARM: fix build with FFT enabled and MDCT disabled lavf: force single-threaded decoding in avformat_find_stream_info avidec: migrate last of lavf from FF_ER_* to AV_EF_* avserver: fix build after the next bump. Conflicts: libavformat/Makefile libavformat/avidec.c libavformat/utils.c Merged-by: Michael Niedermayer <michaelni@gmx.at>
| * lavf: force single-threaded decoding in avformat_find_stream_infoJanne Grunau2012-01-201-3/+20
| | | | | | | | | | | | | | The H.264 decoder needs SPS and PPS for initialization during multi-threaded decoding. When probed single-threaded SPS and PPS are copied to extradata and are available for proper initialization of the decoder before the first frame is decoded.
* | Merge remote-tracking branch 'qatar/master'Michael Niedermayer2012-01-191-3/+6
|\| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * qatar/master: avprobe, cmdutils: K&R formatting cosmetics tests: K&R formatting cosmetics for test programs lavf: free packets for muxers implementing interleave_packet(). lavf: fix and extend av_interleaved_write_frame() doxy. mov: Remove dead stores for spherical coordinates for channel position. error_resilience: K&R formatting cosmetics RELEASE_NOTES: mention hiding private symbols in shared builds. RELEASE_NOTES: mention some notable API changes in 0.8 Conflicts: cmdutils.h doc/RELEASE_NOTES ffprobe.c libavcodec/error_resilience.c Merged-by: Michael Niedermayer <michaelni@gmx.at>
| * lavf: free packets for muxers implementing interleave_packet().Anton Khirnov2012-01-181-3/+6
| | | | | | | | Fixes a memleak.
* | Merge remote-tracking branch 'qatar/master'Michael Niedermayer2012-01-131-1/+3
|\| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * qatar/master: (21 commits) utils: Check for extradata size overflows. ARM: rv34: fix asm syntax in dc transform functions avio: Fix the value of the deprecated URL_FLAG_NONBLOCK rv34: fix and optimise frame dependency checking rv34: NEON optimised dc only inverse transform avprobe: use avio_size() instead of deprecated AVFormatContext.file_size. ffmenc: remove references to deprecated AVFormatContext.timestamp. lavf: undeprecate read_seek(). avserver: remove code using deprecated CODEC_CAP_PARSE_ONLY. lavc: replace some remaining FF_I_TYPE with AV_PICTURE_TYPE_I lavc: ifdef out parse_only AVOption nellymoserdec: SAMPLE_FMT -> AV_SAMPLE_FMT mpegvideo_enc: ifdef out/replace references to deprecated codec flags. riff: remove references to sonic codec ids indeo4: add some missing static and const qualifiers rv34: DC-only inverse transform avconv: use AVFrame.width/height/format instead of corresponding AVCodecContext fields lavfi: move version macros to a new installed header version.h vsrc_buffer: release the buffer on uninit. rgb2rgb: rgb12tobgr12() ... Conflicts: avconv.c doc/APIchanges ffprobe.c libavfilter/Makefile libavfilter/avfilter.h libswscale/rgb2rgb.c libswscale/rgb2rgb.h Merged-by: Michael Niedermayer <michaelni@gmx.at>
| * utils: Check for extradata size overflows.Alex Converse2012-01-121-1/+3
| |
* | lavf: Add forgotten line from 212fd3a1f1121a9db20c478f1fccf15e8bb53c94Michael Niedermayer2012-01-091-0/+2
| | | | | | | | | | | | This fixes a tiny memleak. Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
* | lavf: Do not attempt to use frame multi threading when probing.Michael Niedermayer2012-01-071-2/+9
| | | | | | | | | | | | | | | | | | This fixes various problems with getting stream info. For example playback of the file of Ticket88. Multithreaded find_stream_info should be reenabled once it works correctly This partly reverts 212fd3a1f1121a9db20c478f1fccf15e8bb53c94 Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
* | Flush decoders correctly in avformat_find_stream_info().Reimar Döffinger2012-01-061-23/+28
| | | | | | | | | | | | | | | | | | | | The decoders should not only be flushed on EOF or error, but also when e.g. probe size was reached. It is best to just always flush by default and only disable it explicitly when we know that we have everything we need. Fixes trac ticket #879. Signed-off-by: Reimar Döffinger <Reimar.Doeffinger@gmx.de>
* | Merge remote-tracking branch 'qatar/master'Michael Niedermayer2012-01-061-37/+44
|\| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * qatar/master: (21 commits) ipmovie: do not read audio packets before the codec is known truemotion2: check size before GetBitContext initialisation avio: Only do implicit network initialization for network protocols avio: Add an URLProtocol flag for indicating that a protocol uses network adpcm: ADPCM Electronic Arts has always two channels matroskadec: Fix a bug where a pointer was cached to an array that might later move due to a realloc() fate: Add missing reference file from 9b4767e4. mov: Support MOV_CH_LAYOUT_USE_DESCRIPTIONS for labeled descriptions. 4xm: Prevent buffer overreads. mjpegdec: parse RSTn to prevent skipping other data in mjpeg_decode_scan vp3: add fate test for non-zero last coefficient vp3: fix streams with non-zero last coefficient swscale: remove unused U/V arguments from yuv2rgb_write(). timer: K&R formatting cosmetics lavf: cosmetics, reformat av_read_frame(). lavf: refactor av_read_frame() to make it easier to understand. Report an error if pitch_lag is zero in AMR-NB decoder. Revert "4xm: Prevent buffer overreads." 4xm: Prevent buffer overreads. 4xm: pass the correct remaining buffer size to decode_i2_frame(). ... Conflicts: libavcodec/4xm.c libavcodec/mjpegdec.c libavcodec/truemotion2.c libavformat/ipmovie.c libavformat/mov_chan.c Merged-by: Michael Niedermayer <michaelni@gmx.at>
| * lavf: cosmetics, reformat av_read_frame().Anton Khirnov2012-01-051-12/+11
| |
| * lavf: refactor av_read_frame() to make it easier to understand.Anton Khirnov2012-01-051-25/+33
| |
* | lavf: use avg_frame_rate and packet number to exit find_stream_infoMichael Niedermayer2012-01-051-2/+7
| | | | | | | | | | | | | | qatar does this too but clobbers the AVPacket.duration by approximate values. Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
* | lavf: revert commit bb99ae3ae924c942a634bec7711ec7ee11c38eb9Michael Niedermayer2012-01-051-3/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | Author: Michael Niedermayer <michaelni@gmx.at> Date: Thu Nov 3 22:38:10 2011 +0100 lavf: fix null pointer dereference in rdt Signed-off-by: Michael Niedermayer <michaelni@gmx.at> This is no longer needed and causes various problems with RTSP Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
* | lavf: Fix try_decode_frame() so it doesnt loop infinitely.Michael Niedermayer2012-01-041-0/+2
| | | | | | | | Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
* | Merge remote-tracking branch 'qatar/master'Michael Niedermayer2012-01-041-19/+19
|\| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * qatar/master: fate: add dxtory test adx_parser: rewrite. adxdec: Validate channel count to fix a division by zero. adxdec: Do not require extradata. cmdutils: K&R reformatting cosmetics alacdec: implement the 2-pass prediction type. alacenc: implement the 2-pass prediction type. alacenc: do not generate invalid multi-channel ALAC files alacdec: fill in missing or guessed info about the extradata format. utvideo: proper median prediction for interlaced videos lavu: bump lavu minor for av_popcount64 dca: K&R formatting cosmetics dct: K&R formatting cosmetics lavf: flush decoders in avformat_find_stream_info(). win32: detect number of CPUs using affinity Add av_popcount64 snow: Restore three mistakenly removed casts. Conflicts: cmdutils.c doc/APIchanges libavcodec/adx_parser.c libavcodec/adxdec.c libavcodec/alacenc.c libavutil/avutil.h tests/fate/screen.mak Merged-by: Michael Niedermayer <michaelni@gmx.at>
| * lavf: flush decoders in avformat_find_stream_info().Anton Khirnov2012-01-031-19/+19
| | | | | | | | | | This means that avformat_find_stream_info() now works properly with multiple threads, so there's no need to force thread count to 1.
* | Merge remote-tracking branch 'qatar/master'Michael Niedermayer2012-01-011-5/+16
|\| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * qatar/master: FATE: add tests for dfa mpegaudiodec: fix seeking. mpegaudiodec: fix compilation when testing the unchecked bitstream reader threads: add sysconf based number of CPUs detection threads: always include necessary headers for number of CPUs detection threads: default to automatic thread count detection Changelog: restore version <next> header cook: K&R formatting cosmetics Conflicts: Changelog libavcodec/version.h Merged-by: Michael Niedermayer <michaelni@gmx.at>
| * threads: default to automatic thread count detectionJanne Grunau2011-12-311-4/+15
| |
* | lavf: ffio_limit(), treat avio_size()==0 as error.Michael Niedermayer2011-12-311-1/+1
| | | | | | | | | | | | | | | | This works around issues arising from inputs that claim to have a filesize of 0. Reported-by: buzz_ Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
* | avio: Fix ffio_limit() when due to seeking past the end less than 0 bytes ↵Michael Niedermayer2011-12-251-1/+2
| | | | | | | | | | | | remain. Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
* | libavformat: increase LIBAVFORMAT_VERSION_MICRO to 100Michael Niedermayer2011-12-221-0/+2
| | | | | | | | Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
* | Merge remote-tracking branch 'qatar/master'Michael Niedermayer2011-12-221-0/+43
|\| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * qatar/master: (27 commits) asfdec: add side data to ASFStream packet instead of output packet. idroqdec: set AVFMTCTX_NOHEADER and create streams as they occur. nellymoserdec: Indicate that the decoder can handle changed parameters libavcodec: Apply parameter change side data when decoding audio flvdec: Add param change side data if the sample rate or channels have changed libavformat: Add a utility function for adding parameter change side data libavcodec: Define a side data type for parameter changes aacdec: Handle new extradata passed as side data flvdec: Export new AAC/H.264 extradata as side data on the next packet libavcodec: Define a side data type for new extradata flacdec: skip all track indices at once instead of looping. mxf: Add PictureEssenceCoding UL for V210. mxfdec: consider QuantizationBits between 17 and 24 to be pcm_s24* mxfenc: Add support for MPEG-2 MP@HL-14 in mxf container. mxf: H.264/MPEG-4 AVC Intra support configure: Show whether the safe bitstream reader is enabled x86: Tighten register constraints for decode_significance*_x86. Replace Subversion revisions in comments by Git hashes. h264_cabac: synchronize decode_significance_*_x86 conditionals w32threads: wait for the waked thread in pthread_cond_signal. ... Conflicts: libavcodec/avcodec.h libavcodec/version.h libavformat/flvdec.c libavformat/utils.c tests/ref/lavfi/pixdesc tests/ref/lavfi/pixfmts_copy tests/ref/lavfi/pixfmts_null tests/ref/lavfi/pixfmts_scale tests/ref/lavfi/pixfmts_vflip Merged-by: Michael Niedermayer <michaelni@gmx.at>
| * libavformat: Add a utility function for adding parameter change side dataMartin Storsjö2011-12-211-0/+43
| | | | | | | | Signed-off-by: Martin Storsjö <martin@martin.st>
* | lavf: split out ffio_limit()Michael Niedermayer2011-12-191-4/+8
| | | | | | | | Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
* | Merge remote-tracking branch 'qatar/master'Michael Niedermayer2011-12-191-9/+7
|\| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * qatar/master: APIchanges: fill in revision for AVFrame.age deprecation avcodec: deprecate AVFrame.age 4xm: remove unneeded check for remaining unused data. lavf: force threads to 1 in avformat_find_stream_info() swscale: fix overflows in vertical scaling at top/bottom edges. lavf: add OpenMG audio muxer. omadec: split data that will be used in the muxer to a separate file. lavf: rename oma.c -> omadec.c tmv decoder: set correct pix_fmt Conflicts: Changelog doc/APIchanges libavcodec/mpegvideo.c libavcodec/version.h libavformat/oma.c libavformat/version.h libswscale/swscale.c Merged-by: Michael Niedermayer <michaelni@gmx.at>
| * lavf: force threads to 1 in avformat_find_stream_info()Anton Khirnov2011-12-181-0/+5
| | | | | | | | | | Fixes avformat_find_stream_info() on streams with number of frames < thread count.
* | lavf: print an error if a packet has been truncated due to filesizeMichael Niedermayer2011-12-161-2/+4
| | | | | | | | | | | | in av_get_packet() Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
* | lavf: Update AVIOContext.maxsize when hitting the end.Michael Niedermayer2011-12-161-3/+10
| | | | | | | | Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
* | lavf: add internal AVIOContext.maxsizeMichael Niedermayer2011-12-161-1/+9
| | | | | | | | | | | | This allows simple and generic limiting of allocations used for packets. Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
* | lavf: update rfps debug code.Michael Niedermayer2011-12-151-2/+2
| | | | | | | | Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
* | lavf: Fix fps misdetection when codec_info_duration is 0 and only a few ↵Michael Niedermayer2011-12-151-0/+2
| | | | | | | | | | | | frames are used to estimate fps. Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
* | Prevent segfault if iformat was not yet initialized.Panagiotis H.M. Issaris2011-12-141-2/+2
| | | | | | | | Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
* | Merge remote-tracking branch 'qatar/master'Michael Niedermayer2011-12-131-1/+1
|\| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * qatar/master: ulti: Fix invalid reads lavf: dealloc private options in av_write_trailer yadif: support 10bit YUV vc1: mark with ER_MB_ERROR bits overconsumption lavc: introduce ER_MB_END and ER_MB_ERROR error_resilience: use the ER_ namespace build: move inclusion of subdir.mak to main subdir loop rv34: NEON optimised 4x4 dequant rv34: move 4x4 dequant to RV34DSPContext aacdec: Use intfloat.h rather than local punning union. Conflicts: libavcodec/h264.c libavcodec/vc1dec.c libavfilter/vf_yadif.c libavformat/Makefile Merged-by: Michael Niedermayer <michaelni@gmx.at>
| * lavf: dealloc private options in av_write_trailerLuca Barbato2011-12-131-1/+1
| | | | | | | | Fix the iformat/oformat typo.
* | Merge remote-tracking branch 'qatar/master'Michael Niedermayer2011-12-131-1/+15
|\| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * qatar/master: doxygen: misc consistency, spelling and wording fixes vcr1: drop unnecessary emms_c() calls without MMX code Replace all uses of av_close_input_file() with avformat_close_input(). lavf: add avformat_close_input(). lavf: deprecate av_close_input_stream(). lavf doxy: add some basic demuxing documentation. lavf doxy: add some general lavf information. lavf doxy: add misc utility functions to a group. lavf doxy: add av_guess_codec/format to the encoding group. lavf doxy: add core functions to a doxy group. Add basic libavdevice documentation. lavc: convert error_recognition to err_recognition. avconv: update -map option help text x86: Require 7 registers for the cabac asm x86: bswap: remove test for bswap instruction bswap: make generic implementation more compiler-friendly h264: remove useless cast proresdec: fix decode_slice() prototype Conflicts: configure doc/APIchanges ffprobe.c libavcodec/avcodec.h libavcodec/celp_math.h libavcodec/h264.c libavfilter/src_movie.c libavformat/anm.c libavformat/avformat.h libavformat/version.h libavutil/avstring.h libavutil/bswap.h Merged-by: Michael Niedermayer <michaelni@gmx.at>
| * lavf: add avformat_close_input().Anton Khirnov2011-12-121-0/+9
| | | | | | | | | | | | | | It sets the supplied AVFormatContext pointer to NULL after freeing it, which is safer and its name is consistent with other lavf functions. Also deprecate av_close_input_file().