summaryrefslogtreecommitdiff
path: root/avconv.c
Commit message (Collapse)AuthorAge
* avconv: use avcodec_parameters_copy() with streamcopyAnton Khirnov2016-07-02
| | | | | | | | | This preserves all the information in the codec parameters. The wavpack ref changes are caused by the fact that now the sample format is set, so matroskaenc can use it to set the bit depth. Bug-Id: 945, along with the previous commit
* avconv: restructure sending EOF to filtersAnton Khirnov2016-06-28
| | | | | | | | | | | Be more careful when an input stream encounters EOF when its filtergraph has not been configured yet. The current code would immediately mark the corresponding output streams as finished, while there may still be buffered frames waiting for frames to appear on other filtergraph inputs. This should fix the random FATE failures for complex filtergraph tests after a3a0230a9870b9018dc7415ae5872784d524cfe5
* avconv: move flushing the queued frames to configure_filtergraph()Anton Khirnov2016-06-28
| | | | | This is a more appropriate place for it, and will also be useful in the following commit.
* avconv: pass the hwaccel frames context to the decoderAnton Khirnov2016-06-25
|
* avconv: init filtergraphs only after we have a frame on each inputAnton Khirnov2016-06-25
| | | | | | | | | This makes sure the actual stream parameters are used, which is important mainly for hardware decoding+filtering cases, which would previously require various weird workarounds to handle the fact that a fake software graph has to be constructed, but never used. This should also improve behaviour in rare cases where avformat_find_stream_info() does not provide accurate information.
* avconv: do packet ts rescaling in write_packet()Anton Khirnov2016-06-25
| | | | | This will be useful in the following commit, after which the muxer timebase is not always available when encoding.
* avconv: decouple configuring filtergraphs and setting output parametersAnton Khirnov2016-06-25
| | | | | | | | | | Currently, a filtergraph will pull in the output constraints from its corresponding decoder context, which breaks proper layering. Instead, explicitly send the constaints on the output parameters to the filtergraph. This is similar to what is done for filtergraph inputs in 30ab4c51a180610d9f1720c75518d763515c0d9f
* avconv: factor out initializing stream parameters for encodingAnton Khirnov2016-06-25
| | | | | | | | | | Setting the filter input parameters is moved to init_input_stream(), so that it is done before the decoder is opened, potentially overwriting the information from avformat_find_stream_info() with less accurate data. This commit temporarily disables QSV transcoding with hw frames. The functionality will be re-added in the following commits.
* avconv: decouple configuring filtergraphs and setting input parametersAnton Khirnov2016-06-25
| | | | | | | | | | | | Currently, calling configure_filtergraph() will pull in the input parameters from the corresponding decoder context. This has the following disadvantages: - the decoded frame is a more proper source for this information - a filter accessing decoder data breaks proper layering Add functions for explicitly sending the input stream parameters to a filtergraph input - currently from a frame and a decoder. The decoder one will be dropped in future commits after some more restructuring.
* avconv: buffer the packets written while the muxer is not initializedAnton Khirnov2016-06-25
|
* avconv: explicitly postpone writing the header until all streams are initializedAnton Khirnov2016-06-25
| | | | | This should have no practical effect for now, but will make a difference in the following commits.
* Use AVFrame.pts instead of deprecated pkt_pts.Anton Khirnov2016-06-21
|
* avconv: factor out initializing stream parameters for streamcopyAnton Khirnov2016-06-21
|
* avconv: initialize output framerate earlierAnton Khirnov2016-06-21
| | | | This will be needed in the following commits.
* avconv: do not set encoder options when streamcopy is usedAnton Khirnov2016-06-21
|
* avconv: refactor selecting an encoderAnton Khirnov2016-06-21
| | | | | Fail immediately if automatic encoder selection failed. Always set the stream_copy/encoding_needed flags in one place.
* avconv: fix handling attachments in init_output_streamAnton Khirnov2016-06-21
| | | | | | The current code assumes that encoding_needed is simply an inverse of stream_copy, which is not true for manually attached files (for which neither of those is true).
* avconv: create simple filtergraphs earlierAnton Khirnov2016-06-21
| | | | | | We already have all the necessary information in open_output_file(). This makes the information about the stream/filtergraph mappings available earlier.
* avconv: add a function for determining whether a filtergraph is simpleAnton Khirnov2016-06-21
| | | | This makes the code easier to read.
* avconv: Do not copy extradata if source buffer is emptyVittorio Giovara2016-06-06
| | | | | | | Fixes clang-usan runtime error "null pointer passed as argument 2, which is declared to never be null" while streamcopying. Signed-off-by: Vittorio Giovara <vittorio.giovara@gmail.com>
* avconv: Use more precise deprecation ifdefsDiego Biurrun2016-05-22
| | | | This fixes compilation with the libavcodec version bumped to 58.
* avconv: stop using AVStream.codecAnton Khirnov2016-05-22
| | | | | | | | It is now only used by the av_parser_change() call during streamcopy, so allocate a special AVCodecContext instance for this case. This instance should go away when the new parser API is finished. Signed-off-by: Diego Biurrun <diego@biurrun.de>
* Add some more deprecation guardsDiego Biurrun2016-05-11
| | | | Avoids unused function/label/variable warnings after the next version bump.
* cosmetics: Fix spelling mistakesVittorio Giovara2016-05-04
| | | | Signed-off-by: Diego Biurrun <diego@biurrun.de>
* avconv: Drop an unused variableLuca Barbato2016-04-01
|
* avconv: fix -frames for videoAnton Khirnov2016-03-30
| | | | | | For video, frame_number tracks the number of frames sent to the encoder. So it should be incremented when we submit a frame, not when we get a packet back.
* avconv: VAAPI hwcontext initialisation and hwaccel helperMark Thompson2016-03-30
| | | | Signed-off-by: Anton Khirnov <anton@khirnov.net>
* avconv: use new encode APIwm42016-03-23
| | | | | | | The flushing case is a bit strange; not simplifying it so the change is less noisy. Signed-off-by: Anton Khirnov <anton@khirnov.net>
* avconv: use new decode APIwm42016-03-23
| | | | Signed-off-by: Anton Khirnov <anton@khirnov.net>
* avconv: switch to the new BSF APIAnton Khirnov2016-03-20
|
* avconv: remove sub-frame warningwm42016-03-05
| | | | | | It's not practical to keep this with the new decode API. Signed-off-by: Anton Khirnov <anton@khirnov.net>
* avconv: convert to codecparAnton Khirnov2016-02-23
| | | | | The switch is not yet complete because the parsers and the bistream filters do not have a new AVCodecParam-based API yet.
* avconv: switch opening decoders and encodersAnton Khirnov2016-02-23
| | | | | | Open decoders first, next encoders. This makes sure that that subtitle_header is always set properly, without relying on avformat_find_stream_info() setting it.
* avconv: pass the hw context from filters to the encoderAnton Khirnov2016-02-14
|
* avconv: Drop an impossible checkLuca Barbato2016-01-04
| | | | | | EAGAIN is already managed in poll_filters(). Signed-off-by: Luca Barbato <lu_zero@gentoo.org>
* avconv: Simplify poll_filters() return value checkLuca Barbato2016-01-04
| | | | Signed-off-by: Luca Barbato <lu_zero@gentoo.org>
* avconv: pass the global codec side data to the muxerAnton Khirnov2015-12-06
|
* avconv: set packet duration for CFR video streamsAnton Khirnov2015-11-08
|
* avconv: support infinite loop for the loop optionAlexandra Hájková2015-10-26
| | | | Signed-off-by: Luca Barbato <lu_zero@gentoo.org>
* avpacket: Replace av_free_packet with av_packet_unrefLuca Barbato2015-10-26
| | | | | | | `av_packet_unref` matches the AVFrame ref-counted API and can be used as a drop in replacement. Deprecate `av_free_packet`.
* avformat: Always return ref-counted AVPacketLuca Barbato2015-10-26
| | | | And drop the av_dup_packet from the input_thread.
* avconv: add support for Intel QSV-accelerated transcodingAnton Khirnov2015-10-16
| | | | Signed-off-by: Luca Barbato <lu_zero@gentoo.org>
* avformat: Do not use AVFMT_RAWPICTURELuca Barbato2015-10-13
| | | | | There are no formats supporting it anymore and it is deprecated. Update the documentation accordingly.
* avconv: Add loop option.Alexandra Hájková2015-10-13
| | | | Signed-off-by: Anton Khirnov <anton@khirnov.net>
* lavc: Enable side data only packets by defaultVittorio Giovara2015-09-12
| | | | | | | | | Deprecate the now unused option, but temporarily retain the capability to disable the now default behaviour. Mention this change in the AVPacket documentation. Signed-off-by: Vittorio Giovara <vittorio.giovara@gmail.com>
* lavc: Consistently prefix input buffer definesVittorio Giovara2015-07-27
| | | | Signed-off-by: Vittorio Giovara <vittorio.giovara@gmail.com>
* lavc: AV-prefix all codec capabilitiesVittorio Giovara2015-07-27
| | | | | | Express bitfields more simply. Signed-off-by: Vittorio Giovara <vittorio.giovara@gmail.com>
* lavc: AV-prefix all codec flagsVittorio Giovara2015-07-27
| | | | | | Convert doxygen to multiline and express bitfields more simply. Signed-off-by: Vittorio Giovara <vittorio.giovara@gmail.com>
* Deprecate avctx.coded_frameVittorio Giovara2015-07-20
| | | | | | | | | | | | | | | | | The rationale is that coded_frame was only used to communicate key_frame, pict_type and quality to the caller, as well as a few other random fields, in a non predictable, let alone consistent way. There was agreement that there was no use case for coded_frame, as it is a full-sized AVFrame container used for just 2-3 int-sized properties, which shouldn't even belong into the AVCodecContext in the first place. The appropriate AVPacket flag can be used instead of key_frame, while quality is exported with the new AVPacketSideData quality factor. There is no replacement for the other fields as they were unreliable, mishandled or just not used at all. Signed-off-by: Vittorio Giovara <vittorio.giovara@gmail.com>
* Add a quality factor packet side dataVittorio Giovara2015-07-20
| | | | | | | | This is necessary to preserve the quality information currently exported with coded_frame. Add the new side data to every encoder that needs it, and use it in avconv. Signed-off-by: Vittorio Giovara <vittorio.giovara@gmail.com>