summaryrefslogtreecommitdiff
path: root/libavformat/img2enc.c
Commit message (Collapse)AuthorAge
* avformat/img2enc: do not ignore IO errorsMarton Balint2021-12-12
| | | | Signed-off-by: Marton Balint <cus@passwd.hu>
* lavf/img2enc: avoid a useless copy of the urlAnton Khirnov2021-12-07
| | | | | img2enc keeps a private (and possibly truncated) copy of the url that is never modified. Just use AVFormatContext.url instead.
* avformat/img2enc: Don't use sizeof(AVPacket)Andreas Rheinhardt2021-10-03
| | | | Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
* Remove unnecessary avassert.h inclusionsAndreas Rheinhardt2021-07-22
| | | | Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
* avformat: Constify all muxer/demuxersAndreas Rheinhardt2021-04-27
| | | | | | | This is possible now that the next-API is gone. Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com> Signed-off-by: James Almer <jamrial@gmail.com>
* avcodec: add initial exr image encoderPaul B Mahol2021-02-18
|
* avcodec: add PFM image encoderPaul B Mahol2021-02-02
|
* ffplay, avcodec, avformat: Don't initialize before av_packet_ref()Andreas Rheinhardt2020-03-28
| | | | | | | It already initializes the packet. Reviewed-by: Anton Khirnov <anton@khirnov.net> Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@gmail.com>
* avformat/img2enc: add support for specifying protocol optionsMarton Balint2020-01-18
| | | | | | v2: simplified example Signed-off-by: Marton Balint <cus@passwd.hu>
* avformat: remove avio_flush() calls from the end of write_packet functionsMarton Balint2020-01-07
| | | | | | | | | | | | | | | | Removing explicit avio_flush() calls helps us to buffer more data and avoid flushing the IO context too often which causes reduced IO throughput for non-streamed file output. The user can control flushing behaviour at the end of every packet using the -flush_packets option, the default typically means to flush unless a non-streamed file output is used. Therefore this change should have no adverse effect on streaming, even if it is assumed that a new packet has a clean buffer so small seekbacks within the output buffer work even when the IO context is not seekable. Signed-off-by: Marton Balint <cus@passwd.hu>
* avformat/img2enc: fix writing multiple streams in write_muxed_fileMarton Balint2020-01-03
| | | | | | Maybe we should just reject multiple streams for the image2 muxer instead? Signed-off-by: Marton Balint <cus@passwd.hu>
* avformat/img2enc: minor simplificationMarton Balint2020-01-03
| | | | Signed-off-by: Marton Balint <cus@passwd.hu>
* avformat/img2enc: cleanup IO contexts on errorMarton Balint2020-01-03
| | | | Signed-off-by: Marton Balint <cus@passwd.hu>
* avformat/img2enc: reindent after last commitMarton Balint2020-01-03
| | | | Signed-off-by: Marton Balint <cus@passwd.hu>
* avformat/img2enc: factorize piped write_packetMarton Balint2020-01-03
| | | | Signed-off-by: Marton Balint <cus@passwd.hu>
* avformat/img2enc: factorize writing fully muxed fileMarton Balint2020-01-03
| | | | Signed-off-by: Marton Balint <cus@passwd.hu>
* avformat/img2enc: mention -frames:v in error messageLou Logan2019-01-22
| | | | | Signed-off-by: Lou Logan <lou@lrcd.com> Signed-off-by: Kieran O Leary <kieran.o.leary@gmail.com>
* avformat: migrate to AVFormatContext->urlMarton Balint2018-01-28
| | | | Signed-off-by: Marton Balint <cus@passwd.hu>
* avformat/img2enc: add frame_pts option for make output filenameSteven Liu2017-11-13
| | | | | | | | fix ticket id: #1452 when use frame_pts option, the output image name can be set with PTS of current frame. Signed-off-by: Steven Liu <lq@onvideo.cn>
* lavf/img2enc: remove redundant option 'updatefirst'Gyan Doshi2017-11-01
| | | | 'updatefirst' is an undocumented option redundant to older option 'update'. Since it doesn't serve as a shorthand, this patch removes it.
* avformat/img2enc: remove av_dup_packet() callJames Almer2017-09-25
| | | | | | It's unnecessary after a call to av_packet_ref(). Signed-off-by: James Almer <jamrial@gmail.com>
* avformat: replace all uses of av_copy_packet()James Almer2017-09-25
| | | | Signed-off-by: James Almer <jamrial@gmail.com>
* Add FITS MuxerParas Chadha2017-08-30
| | | | Signed-off-by: Paras Chadha <paraschadha18@gmail.com>
* Revert "img2 encoder: allow %t in filename, based on patch from Yuval Adam"Michael Niedermayer2016-11-01
| | | | | | | breaks API Found-by: jamrial This reverts commit 1a956c64c8eff5edecb004fc7aafd21207e6485c.
* img2 encoder: allow %t in filename, based on patch from Yuval Adamrogerdpack2016-11-01
| | | | | Signed-off-by: rogerdpack <rogerpack2005@gmail.com> Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
* avformat/img2enc: Use AV_FRAME_FILENAME_FLAGS_MULTIPLE, support tee:Michael Niedermayer2016-08-04
| | | | 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.
* | avformat/img2enc: remove unused variableMichael Niedermayer2016-02-14
| | | | | | | | Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
* | avformat/img2enc: disable atomic file creation by defaultMarton Balint2016-02-14
| | | | | | | | | | | | | | | | | | Currently it is broken when explicitly using the file protocol, it uses an insecure temporary file name, and in commit b4431c80 disabling the option by default was already considered. Also it is not very consistent to have such an option for one particular muxer. Signed-off-by: Marton Balint <cus@passwd.hu>
* | avformat/img2enc: return error if image rename failsMarton Balint2016-02-14
| | | | | | | | Signed-off-by: Marton Balint <cus@passwd.hu>
* | Merge commit '9f61abc8111c7c43f49ca012e957a108b9cc7610'Derek Buitenhuis2016-02-10
|\| | | | | | | | | | | | | | | | | This also deprecates our old duplicated callbacks. * commit '9f61abc8111c7c43f49ca012e957a108b9cc7610': lavf: allow custom IO for all files Merged-by: Derek Buitenhuis <derek.buitenhuis@gmail.com>
| * lavf: allow custom IO for all filesAnton Khirnov2016-01-24
| | | | | | | | | | | | | | | | | | | | | | | | | | | | Some (de)muxers open additional files beyond the main IO context. Currently, they call avio_open() directly, which prevents the caller from using custom IO for such streams. This commit adds callbacks to AVFormatContext that default to avio_open2()/avio_close(), but can be overridden by the caller. All muxers and demuxers using AVIO are switched to using those callbacks instead of calling avio_open()/avio_close() directly. (de)muxers that use the URLProtocol layer directly instead of AVIO remain unconverted for now. This should be fixed in later commits.
* | avutil: Rename FF_CEIL_COMPAT to AV_CEIL_COMPATDerek Buitenhuis2016-01-27
| | | | | | | | | | | | | | | | | | | | Libav, for some reason, merged this as a public API function. This will aid in future merges. A define is left for backwards compat, just in case some person used it, since it is in a public header. Signed-off-by: Derek Buitenhuis <derek.buitenhuis@gmail.com>
* | lavf/img2enc: add atomic_writing optionClément Bœsch2015-12-21
| | | | | | | | | | This behaviour change caused a regression on our side recently, we might want to disable the option by default.
* | avformat: use AV_OPT_TYPE_BOOL in a bunch of placesClément Bœsch2015-12-04
| |
* | avformat/img2enc: re enable atomic writes with split planesMichael Niedermayer2015-10-28
| | | | | | | | | | | | They work now after fixing the implementation Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
* | avformat/img2enc: Fix img2enc atomic implementation to work with split planesMichael Niedermayer2015-10-27
| | | | | | | | Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
* | avformat/img2enc: Disable rename&atomic writing for non file protocol and ↵Michael Niedermayer2015-10-27
| | | | | | | | | | | | | | | | | | split planes For protocols other than local files ff_rename() is not implemented For split planes support the implementation is simply wrong Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
* | Replace remaining occurances of av_free_packet with av_packet_unrefHendrik Leppkes2015-10-27
| |
* | Merge commit '22f4d9c303ede1a240538fd105c97047db40dc86'Hendrik Leppkes2015-10-27
|\| | | | | | | | | | | | | * commit '22f4d9c303ede1a240538fd105c97047db40dc86': img2enc: Make sure the images are atomically written Merged-by: Hendrik Leppkes <h.leppkes@gmail.com>
| * img2enc: Make sure the images are atomically writtenLuca Barbato2015-10-23
| | | | | | | | | | Users that want to generate a live-preview and serve it would otherwise get partial images.
* | Replace all remaining occurances of step/depth_minus1 and offset_plus1Hendrik Leppkes2015-09-08
| |
* | avformat: implement query_codec for the image2 muxer.tab2015-09-07
| | | | | | | | | | | | | | Allows avformat_query_codec to be used to check for valid image2 encoders. Reuses the existing ff_guess_image2_codec ID table. Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
* | 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/img2enc: Use avio_closep() to avoid leaving stale pointers in memoryMichael Niedermayer2015-01-08
| | | | | | | | Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
* | avformat/img2enc: Use localtime_r() for thread safteyMichael Niedermayer2014-11-02
| | | | | | | | Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
* | avformat/img2enc: remove webp extension as we have a dedicated webp muxerMichael Niedermayer2014-11-02
| | | | | | | | | | Found-by: jamrial Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
* | Allow .y as extension for image2.Carl Eugen Hoyos2014-04-05
| |