summaryrefslogtreecommitdiff
path: root/libavformat/avienc.c
Commit message (Collapse)AuthorAge
* avformat: remove obsolete commented-out DEBUG defineTobias Rapp2017-07-07
| | | | | Signed-off-by: Tobias Rapp <t.rapp@noa-archive.com> Signed-off-by: Derek Buitenhuis <derek.buitenhuis@gmail.com>
* Merge commit '67deba8a416d818f3d95aef0aa916589090396e2'Clément Bœsch2017-03-31
|\ | | | | | | | | | | | | * commit '67deba8a416d818f3d95aef0aa916589090396e2': Use avpriv_report_missing_feature() where appropriate Merged-by: Clément Bœsch <cboesch@gopro.com>
| * Use avpriv_report_missing_feature() where appropriateDiego Biurrun2016-11-08
| |
* | Merge commit '83548fe894cdb455cc127f754d09905b6d23c173'James Almer2017-03-21
|\| | | | | | | | | | | | | * commit '83548fe894cdb455cc127f754d09905b6d23c173': lavf: fix usage of AVIOContext.seekable Merged-by: James Almer <jamrial@gmail.com>
| * lavf: fix usage of AVIOContext.seekableAnton Khirnov2016-09-30
| | | | | | | | | | | | | | | | It is supposed to be a flag. The only currently defined value is AVIO_SEEKABLE_NORMAL, but other ones may be added in the future. However all the current lavf code treats this field as a bool (mainly for historical reasons). Change all those cases to properly check for AVIO_SEEKABLE_NORMAL.
* | avformat/avienc: add reserve_index_space optionTobias Rapp2017-01-31
| | | | | | | | | | | | | | | | | | | | Allows the user to reserve space for the ODML master index. A sufficient sized master index in the AVI header avoids storing follow-up master indexes within the 'movi' data later. If the option is omitted or zero the index size is estimated from output duration and bitrate. Reviewed-by: Michael Niedermayer <michael@niedermayer.cc> Signed-off-by: Tobias Rapp <t.rapp@noa-archive.com>
* | avformat/avlanguage: make av_convert_lang_to() internalJames Almer2016-07-19
| | | | | | | | | | | | | | The header was never installed and the function is only used in libavformat Reviewed-by: Paul B Mahol <onemda@gmail.com> Signed-off-by: James Almer <jamrial@gmail.com>
* | avformat/avienc: Fix memleaks on errorsMichael Niedermayer2016-05-22
| | | | | | | | | | | | Fixes CID1361951 Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
* | avformat/avienc: Rename reshuffles return variable to ensure it is not mixed upMichael Niedermayer2016-05-22
| | | | | | | | Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
* | Merge commit '9200514ad8717c63f82101dc394f4378854325bf'Derek Buitenhuis2016-04-10
|\| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * commit '9200514ad8717c63f82101dc394f4378854325bf': lavf: replace AVStream.codec with AVStream.codecpar This has been a HUGE effort from: - Derek Buitenhuis <derek.buitenhuis@gmail.com> - Hendrik Leppkes <h.leppkes@gmail.com> - wm4 <nfxjfg@googlemail.com> - Clément Bœsch <clement@stupeflix.com> - James Almer <jamrial@gmail.com> - Michael Niedermayer <michael@niedermayer.cc> - Rostislav Pehlivanov <atomnuker@gmail.com> Merged-by: Derek Buitenhuis <derek.buitenhuis@gmail.com>
| * lavf: replace AVStream.codec with AVStream.codecparAnton Khirnov2016-02-23
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Currently, AVStream contains an embedded AVCodecContext instance, which is used by demuxers to export stream parameters to the caller and by muxers to receive stream parameters from the caller. It is also used internally as the codec context that is passed to parsers. In addition, it is also widely used by the callers as the decoding (when demuxer) or encoding (when muxing) context, though this has been officially discouraged since Libav 11. There are multiple important problems with this approach: - the fields in AVCodecContext are in general one of * stream parameters * codec options * codec state However, it's not clear which ones are which. It is consequently unclear which fields are a demuxer allowed to set or a muxer allowed to read. This leads to erratic behaviour depending on whether decoding or encoding is being performed or not (and whether it uses the AVStream embedded codec context). - various synchronization issues arising from the fact that the same context is used by several different APIs (muxers/demuxers, parsers, bitstream filters and encoders/decoders) simultaneously, with there being no clear rules for who can modify what and the different processes being typically delayed with respect to each other. - avformat_find_stream_info() making it necessary to support opening and closing a single codec context multiple times, thus complicating the semantics of freeing various allocated objects in the codec context. Those problems are resolved by replacing the AVStream embedded codec context with a newly added AVCodecParameters instance, which stores only the stream parameters exported by the demuxers or read by the muxers.
* | lavf/avienc: Clear whole tag in avi_add_ientry()Mats Peterson2016-03-13
| | | | | | | | Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
* | lavf/avienc: Add xxpc entries to indexMats Peterson2016-03-13
| | | | | | | | Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
* | avformat/avienc: factor out avi_add_ientry()Mats Peterson2016-03-13
| | | | | | | | Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
* | lavf/avienc: Palette changing code only concerns AV_PIX_FMT_PAL8Mats Peterson2016-03-08
| | | | | | | | Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
* | avformat/avienc: Remove unneeded seekable testsMichael Niedermayer2016-03-06
| | | | | | | | | | Reviewed-by: Reimar Döffinger <Reimar.Doeffinger@gmx.de> Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
* | avformat/avienc: assert that bits_per_coded_sample is within the supported ↵Michael Niedermayer2016-03-05
| | | | | | | | | | | | range (out of array access otherwise) Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
* | lavf/avienc: Add support for palette side dataMats Peterson2016-03-05
| | | | | | | | Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
* | avformat/avienc: Fix assertion failure with 256 palette entriesMichael Niedermayer2016-02-21
| | | | | | | | Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
* | lavf/avienc: Add palette after BITMAPINFOHEADERMats Peterson2016-02-21
| | | | | | | | | | | | | | lavf/riffenc: Write space for palette tests/ref/vsynth: Update 1 bpp files for pal8 Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
* | avienc: Remove unused variable 'ret'Reto Kromer2016-02-20
| | | | | | | | | | Reviewed-by: Michael Niedermayer <michael@niedermayer.cc> Signed-off-by: Timothy Gu <timothygu99@gmail.com>
* | avformat/avienc: Store pal8 paletteMichael Niedermayer2016-02-19
| | | | | | | | | | | | | | This can be made more efficient, but first and the main goal of this change is to store it at all Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
* | avformat/avienc: Use avi_write_packet_internal() to store raw rgb in a more ↵Michael Niedermayer2016-02-18
| | | | | | | | | | | | spec compliant way Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
* | avformat/avienc: Split avi_write_packet_internal() outMichael Niedermayer2016-02-18
| | | | | | | | Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
* | avformat/avienc: add muxer option "write_channel_mask"Tobias Rapp2015-09-12
| | | | | | | | | | | | | | Allow writing an empty channel mask into the wave format header. Useful if the input file contains an unknown channel layout. Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
* | Replace av_dlog with ff_dlog.Ronald S. Bultje2015-08-18
| | | | | | | | | | ff_dlog checks compilability, and is non-public. av_dlog is deprecated and no longer exists if FF_API_DLOG=0.
* | avformat/avienc: Correct possible dereference of nullRoman Savchenko2015-05-29
| | | | | | | | Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
* | avformat/avienc: Avoid float usageMichael Niedermayer2015-05-23
| | | | | | | | | | | | reduces risk for rounding differences between platforms Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
* | avformat/avienc: Expand master ODML index when its end is reachedMichael Niedermayer2015-03-19
| | | | | | | | | | | | | | Fixes 256Gb limit Fixes Ticket4225 Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
* | avformat/avienc: Fix wrongly placed commentMichael Niedermayer2015-03-19
| | | | | | | | Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
* | avformat/avienc: factor out update_odml_entry()Michael Niedermayer2015-03-19
| | | | | | | | Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
* | avformat/avienc: factor write_odml_master() outMichael Niedermayer2015-03-19
| | | | | | | | Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
* | libavformat/avienc: Fix duration of audio segment in OpenDML master indexTobias Rapp2015-03-04
| | | | | | | | | | | | | | | | | | | | | | Fixes the duration field of the OpenDML master index "indx" chunk to contain the number of samples instead of the number of packets for (linear/PCM) audio streams. This matches the OpenDML V1.02 standard text which states that the duration field shall contain "time span in stream ticks". Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
* | Merge commit 'daf8cf358a098a903d59adb6c0d0cc3262a8c93e'Michael Niedermayer2015-02-14
|\| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * commit 'daf8cf358a098a903d59adb6c0d0cc3262a8c93e': avformat: Don't anonymously typedef structs Conflicts: libavformat/adtsenc.c libavformat/aiffenc.c libavformat/avidec.c libavformat/gif.c libavformat/iff.c libavformat/img2dec.c libavformat/jvdec.c libavformat/matroskadec.c libavformat/udp.c libavformat/wtvdec.c Merged-by: Michael Niedermayer <michaelni@gmx.at>
| * avformat: Don't anonymously typedef structsDiego Biurrun2015-02-14
| |
* | avformat/avienc: write last frame durationMichael Niedermayer2014-11-19
| | | | | | | | | | | | Fixes small part of Ticket 3052 Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
* | avformat/avienc: factor frame skip code outMichael Niedermayer2014-11-19
| | | | | | | | Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
* | libavformat/avienc: Make unchanged function arguments constMichael Niedermayer2014-09-24
| | | | | | | | Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
* | avformat/avienc: Dont search for startcodes in inserted empty avi framesMichael Niedermayer2014-09-17
| | | | | | | | Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
* | Merge commit '194be1f43ea391eb986732707435176e579265aa'Michael Niedermayer2014-06-18
|\| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * commit '194be1f43ea391eb986732707435176e579265aa': lavf: switch to AVStream.time_base as the hint for the muxer timebase Conflicts: doc/APIchanges libavformat/filmstripenc.c libavformat/movenc.c libavformat/mxfenc.c libavformat/oggenc.c libavformat/swf.h libavformat/version.h tests/ref/lavf/mkv Merged-by: Michael Niedermayer <michaelni@gmx.at>
| * lavf: switch to AVStream.time_base as the hint for the muxer timebaseAnton Khirnov2014-06-18
| | | | | | | | | | | | | | | | | | | | | | | | Previously, AVStream.codec.time_base was used for that purpose, which was quite confusing for the callers. This change also opens the path for removing AVStream.codec. The change in the lavf-mkv test is due to the native timebase (1/1000) being used instead of the default one (1/90000), so the packets are now sent to the crc muxer in the same order in which they are demuxed (previously some of them got reordered because of inexact timestamp conversion).
* | Merge commit 'd754ed41727b1fcbab335b510248a9758a73320c'Michael Niedermayer2014-06-18
|\| | | | | | | | | | | | | | | | | | | * commit 'd754ed41727b1fcbab335b510248a9758a73320c': riffenc: take an AVStream instead of an AVCodecContext Conflicts: libavformat/nutenc.c Merged-by: Michael Niedermayer <michaelni@gmx.at>
| * riffenc: take an AVStream instead of an AVCodecContextAnton Khirnov2014-06-18
| | | | | | | | | | | | It will be useful in the following commits. Also, rename the AVCodecContext pointer name from 'stream' to 'codec'.
* | Refuse to mux H.264 with fourcc H264 into avi without startcode.Carl Eugen Hoyos2014-05-23
| | | | | | | | Fixes ticket #3638.
* | Set dwSuggestBufferSize to largest chunk size for every stream in avi.Carl Eugen Hoyos2014-05-19
| | | | | | | | | | | | | | Fixes playback with WMP 9 for files with large (rawvideo) frames as explained in ticket #2145. Fixes ticket #2818.
* | Merge commit 'c3311d472a7528c67f76d0d061704ae70a99b32e'Michael Niedermayer2014-05-18
|\| | | | | | | | | | | | | | | | | | | * commit 'c3311d472a7528c67f76d0d061704ae70a99b32e': avienc: sanitize variable naming in write_header() Conflicts: libavformat/avienc.c Merged-by: Michael Niedermayer <michaelni@gmx.at>
| * avienc: sanitize variable naming in write_header()Anton Khirnov2014-05-18
| | | | | | | | | | | | Do not call an AVCodecContext 'stream', that is highly confusing. Also, add a local variable for the current AVStream in the loop over all streams.
* | ff_put_wav_header: add flag to force WAVEFORMATEXDaniel Verkamp2014-04-30
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Partially undoes commit 2c4e08d89327595f7f4be57dda4b3775e1198d5e: riff: always generate a proper WAVEFORMATEX structure in ff_put_wav_header A new flag, FF_PUT_WAV_HEADER_FORCE_WAVEFORMATEX, is added to force the use of WAVEFORMATEX rather than PCMWAVEFORMAT even for PCM codecs. This flag is used in the Matroska muxer (the cause of the original change) and in the ASF muxer, because the specifications for these formats indicate explicitly that WAVEFORMATEX should be used. Muxers for other formats will return to the original behavior of writing PCMWAVEFORMAT when writing a header for raw PCM. In particular, this causes raw PCM in WAV to generate the canonical 44-byte header expected by some tools. Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
* | Fix writing RGB 5:5:5 rawvideo into avi.Carl Eugen Hoyos2014-04-14
| | | | | | | | WMP expects bits per pixel to be set to 16 for RGB 5:5:5 rawvideo.
* | Warn if rawvideo and an unreadable pix_fmt are written.Carl Eugen Hoyos2014-04-11
| | | | | | | | | | | | Print an error if a combination of rawvideo and an unusual pix_fmt that will be impossible to decode are written to avi or mov. Fixes ticket #3545.