[FFmpeg-devel] [PATCH v2] libavformat/tee: Add fifo support for tee

2016-10-17 Thread sebechlebskyjan
From: Jan Sebechlebsky Signed-off-by: Jan Sebechlebsky --- Thanks for noticing, I've fixed the patch (also some minor formatting issues I've noticed). doc/muxers.texi | 20 + libavformat/tee.c | 87 ++- 2 files changed, 106 i

[FFmpeg-devel] [PATCH v2] avformat/tee: Add FATE tests for tee

2016-10-30 Thread sebechlebskyjan
From: Jan Sebechlebsky This commit also adds new diff option for fate tests allowing do compare multiple tuples of files. Signed-off-by: Jan Sebechlebsky --- Changes since the last version: - fixed out of tree build (previous version refered to SRC_PATH instead of TARGET_PATH, thanks to M

[FFmpeg-devel] [PATCH v2 1/2] libavformat/tee: Add fifo support for tee

2016-12-22 Thread sebechlebskyjan
From: Jan Sebechlebsky Signed-off-by: Jan Sebechlebsky --- Changes since the last version of the patch: - Refactoring based on Nicolas's comments - Added TODO regarding boolean option parsing doc/muxers.texi | 20 + libavformat/tee.c | 87 ++

[FFmpeg-devel] [PATCH 0/2] Fifo support for tee

2016-12-22 Thread sebechlebskyjan
From: Jan Sebechlebsky Hello, I am re-sending the patch(es) adding support for fifo pseudo-muxer in tee muxer. I will apply the first one in few days (since it already has been reviewed by Nicolas, and it differs only in issues Nicolas pointed out in review and these should be fixed now). The s

[FFmpeg-devel] [PATCH 2/2] libavformat/tee: Add possibility to pass fifo options by using fifo_ prefix

2016-12-22 Thread sebechlebskyjan
From: Jan Sebechlebsky --- doc/muxers.texi | 9 + libavformat/tee.c | 20 2 files changed, 29 insertions(+) diff --git a/doc/muxers.texi b/doc/muxers.texi index ced223e..139ced0 100644 --- a/doc/muxers.texi +++ b/doc/muxers.texi @@ -1603,6 +1603,11 @@ outputs and

[FFmpeg-devel] [PATCH v2 1/7] avformat/utils: Add ff_stream_encode_params_copy()

2016-07-13 Thread sebechlebskyjan
From: Jan Sebechlebsky Signed-off-by: Jan Sebechlebsky --- Chanages from the last version of patch: -> dst->metadata dictionary is freed before entries are copied from src->metadata libavformat/internal.h | 9 libavformat/utils.c| 57

[FFmpeg-devel] [PATCH v2 3/7] avformat/tee: Rescale ts using av_packet_rescale_ts

2016-07-16 Thread sebechlebskyjan
From: Jan Sebechlebsky This ensures that AV_NOPTS_VALUE value is handled correctly. Signed-off-by: Jan Sebechlebsky --- libavformat/tee.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/libavformat/tee.c b/libavformat/tee.c index daddba5..b4158e1 100644 --- a/libavformat

[FFmpeg-devel] [PATCH 1/2] avcodec/mpeg4_unpack_bframes_bsf: Copy packet props

2016-07-22 Thread sebechlebskyjan
From: Jan Sebechlebsky mpeg4_unpack_bframes_bsf bitstream filters constructs resulting packet using av_packet_from_data() function. This function however modifies only buffer (data) and leaves other fields untouched, so the content of other fields of the output packet is undefined. It is working

[FFmpeg-devel] [PATCH 2/2] avcodec/mpeg4_unpack_bframes_bsf: Check av_packet_from_data() return value

2016-07-22 Thread sebechlebskyjan
From: Jan Sebechlebsky Signed-off-by: Jan Sebechlebsky --- libavcodec/mpeg4_unpack_bframes_bsf.c | 6 +- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/libavcodec/mpeg4_unpack_bframes_bsf.c b/libavcodec/mpeg4_unpack_bframes_bsf.c index aee8ccb..e227f58 100644 --- a/libavcodec

[FFmpeg-devel] [PATCH 1/2] avcodec/bsf: Check side data when setting BSF EOF flag.

2016-07-22 Thread sebechlebskyjan
From: Jan Sebechlebsky Set BSF EOF flag only if pkt == NULL or both data and side data are not present in packet. Signed-off-by: Jan Sebechlebsky --- I believe that side data should be checked too, and EOF flag set only when both data and side data are not present. I was testing new list

[FFmpeg-devel] [PATCH 2/2] avcodec/avcodec.h: Change av_bsf_send_packet() comment

2016-07-22 Thread sebechlebskyjan
From: Jan Sebechlebsky Specify av_bsf_packet() behaviour in case that the packet does not contain any data more precisely in the comment. Signed-off-by: Jan Sebechlebsky --- libavcodec/avcodec.h | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/libavcodec/avcodec.h b/li

[FFmpeg-devel] [PATCH v2] avcodec/bsf: Set EOF flag only if pkt == NULL

2016-07-22 Thread sebechlebskyjan
From: Jan Sebechlebsky Set BSF EOF flag only if pkt == NULL in av_bsf_send_packet(). Signed-off-by: Jan Sebechlebsky --- I agree, it seems cleaner that way. Thanks, please apply this version of patch then and ignore the patch changing the comment. Regards, Jan libavcodec/bsf.c | 2 +-

[FFmpeg-devel] [PATCH 0/2][GSoC] Add fifo pseudo-muxer

2016-07-25 Thread sebechlebskyjan
From: Jan Sebechlebsky Hello, I am sending next version of fifo pseudo-muxer. I will send patchset adding AVFMT_FLAG_NONBLOCK support requested by Nicolas later - it turned out that there are some more things to solve (av_write_frame does not support repeated calls in current state) and test.

[FFmpeg-devel] [PATCH v3 1/2] libavformat: Add fifo pseudo-muxer

2016-07-25 Thread sebechlebskyjan
From: Jan Sebechlebsky The fifo pseudo-muxer allows to separate encoder from the actual output by using a first-in-first-out queue and running actual muxer asynchronously in separate thread. It can be configured to attempt transparent recovery of output on failure. Signed-off-by: Jan Sebechlebs

[FFmpeg-devel] [PATCH 2/2] MAINTAINERS: Add myself as maintainer of fifo muxer

2016-07-25 Thread sebechlebskyjan
From: Jan Sebechlebsky Signed-off-by: Jan Sebechlebsky --- MAINTAINERS | 1 + 1 file changed, 1 insertion(+) diff --git a/MAINTAINERS b/MAINTAINERS index 6d4c9f9..0e66170 100644 --- a/MAINTAINERS +++ b/MAINTAINERS @@ -164,6 +164,7 @@ Codecs: exif.c, exif.hThilo Borgm

[FFmpeg-devel] [PATCH v3 2/2] avcodec/bsf: Forbid packet without payload in av_bsf_send_packet

2016-07-26 Thread sebechlebskyjan
From: Jan Sebechlebsky Signed-off-by: Jan Sebechlebsky --- libavcodec/avcodec.h | 3 ++- libavcodec/bsf.c | 3 +++ 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/libavcodec/avcodec.h b/libavcodec/avcodec.h index ca8dba8..36f7935 100644 --- a/libavcodec/avcodec.h +++ b/libavco

[FFmpeg-devel] [PATCH v3 1/2] avcodec/bsf: Set EOF flag only in pkt == NULL

2016-07-26 Thread sebechlebskyjan
From: Jan Sebechlebsky Set BSF EOF flag only if pkt == NULL in av_bsf_send_packet(). Signed-off-by: Jan Sebechlebsky --- libavcodec/bsf.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libavcodec/bsf.c b/libavcodec/bsf.c index 88b7f29..9b9ada7 100644 --- a/libavcodec/bsf.c

[FFmpeg-devel] [PATCH 3/5] avcodec/bsf: Add list BSF API

2016-07-28 Thread sebechlebskyjan
From: Jan Sebechlebsky --- libavcodec/avcodec.h | 74 ++ libavcodec/bsf.c | 284 +++ 2 files changed, 358 insertions(+) diff --git a/libavcodec/avcodec.h b/libavcodec/avcodec.h index 36f7935..39106ee 100644 --- a/libavcodec/avcode

[FFmpeg-devel] [PATCH 2/5] avcodec/bsf: Add ff_bsf_get_packet_ref() function

2016-07-28 Thread sebechlebskyjan
From: Jan Sebechlebsky Use of this function can save unnecessary malloc operation in bitstream filter. Signed-off-by: Jan Sebechlebsky --- libavcodec/bsf.c | 16 libavcodec/bsf.h | 11 +++ 2 files changed, 27 insertions(+) diff --git a/libavcodec/bsf.c b/libavcodec/bs

[FFmpeg-devel] [PATCH 5/5] avformat/tee: Use BSF list API

2016-07-28 Thread sebechlebskyjan
From: Jan Sebechlebsky Signed-off-by: Jan Sebechlebsky --- libavformat/tee.c | 123 +- 1 file changed, 58 insertions(+), 65 deletions(-) diff --git a/libavformat/tee.c b/libavformat/tee.c index b4158e1..1a055cd 100644 --- a/libavformat/tee.c

[FFmpeg-devel] [PATCH 4/5] avcodec/bsf: Add custom item name func for BSF list

2016-07-28 Thread sebechlebskyjan
From: Jan Sebechlebsky Add custom item name function for bsf list, which will construct string description of filter chain. This is done using lazy-initialization, so there is no overhead if item name is never accessed. Signed-off-by: Jan Sebechlebsky Conflicts: libavcodec/bsf.c --- T

[FFmpeg-devel] [PATCH 1/5] doc/bsfs: Fix bsf options divider in documentation

2016-07-28 Thread sebechlebskyjan
From: Jan Sebechlebsky The actual implementation uses ':' divider, not '/' as documented. Signed-off-by: Jan Sebechlebsky --- doc/bitstream_filters.texi | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/doc/bitstream_filters.texi b/doc/bitstream_filters.texi index 6c58d02..a8

[FFmpeg-devel] [PATCH 09/11] avformat/mux: Restore stream ts in av_write_packet on EAGAIN

2016-08-02 Thread sebechlebskyjan
From: Jan Sebechlebsky compute_muxer_pkt_fields() stores the last seen timestamps in stream and produces error if the same timestamp is presented again. This is a problem if muxer works in non-blocking mode and calls av_write_packet repeatedly with the same packet. This patch saves stream fields

[FFmpeg-devel] [PATCH 03/11] avformat/fifo: Add fate test

2016-08-02 Thread sebechlebskyjan
From: Jan Sebechlebsky Signed-off-by: Jan Sebechlebsky --- This adds two tests checking that the output of muxers is the same as when fifo is used and stand-alone test program which covers behaviour in failure scenarios. libavformat/Makefile | 1 + libavformat/tests/fifo_muxer.c

[FFmpeg-devel] [PATCH 10/11] avformat/fifo: Add AVFMT_FLAG_NONBLOCK support

2016-08-02 Thread sebechlebskyjan
From: Jan Sebechlebsky Add support for nonblocking calls. Signed-off-by: Jan Sebechlebsky --- libavformat/fifo.c | 70 +- 1 file changed, 59 insertions(+), 11 deletions(-) diff --git a/libavformat/fifo.c b/libavformat/fifo.c index bc8c973..e

[FFmpeg-devel] [PATCH 07/11] avformat/avformat.h: Add comments regarding AVFMT_FLAG_NONBLOCK.

2016-08-02 Thread sebechlebskyjan
From: Jan Sebechlebsky Add comments regarding AVFMG_FLAG_NONBLOCK usage with muxers. Signed-off-by: Jan Sebechlebsky --- libavformat/avformat.h | 9 - 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/libavformat/avformat.h b/libavformat/avformat.h index 9173908..6898c8c 100

[FFmpeg-devel] [PATCH 06/11] avformat: add av_abort_output() function

2016-08-02 Thread sebechlebskyjan
From: Jan Sebechlebsky Signed-off-by: Jan Sebechlebsky --- libavformat/avformat.h | 14 ++ libavformat/mux.c | 16 2 files changed, 30 insertions(+) diff --git a/libavformat/avformat.h b/libavformat/avformat.h index 9191c69..9173908 100644 --- a/libavformat/av

[FFmpeg-devel] [PATCH 04/11] avformat/muxers: Add non-blocking mode support for av_write_trailer

2016-08-02 Thread sebechlebskyjan
From: Jan Sebechlebsky This makes av_write_trailer not to free the resources if write_trailer call returns AVERROR(EAGAIN) allowing repeated calls of write_trailer of non-blocking muxer. Signed-off-by: Jan Sebechlebsky --- libavformat/avformat.h | 6 +- libavformat/mux.c | 3 +++ 2 fi

[FFmpeg-devel] [PATCH v4 01/11] avformat: Add fifo pseudo-muxer

2016-08-02 Thread sebechlebskyjan
From: Jan Sebechlebsky Signed-off-by: Jan Sebechlebsky --- Changes from the last version of patch: - I got rid of write header message, and pulled initial write_header call out of the while loop as Nicolas originaly suggested. Changelog| 1 + configure

[FFmpeg-devel] [PATCH 02/11] MAINTAINERS: Add myself as maintainer of fifo muxer

2016-08-02 Thread sebechlebskyjan
From: Jan Sebechlebsky Signed-off-by: Jan Sebechlebsky --- MAINTAINERS | 1 + 1 file changed, 1 insertion(+) diff --git a/MAINTAINERS b/MAINTAINERS index 932e6fb..9fab34d 100644 --- a/MAINTAINERS +++ b/MAINTAINERS @@ -164,6 +164,7 @@ Codecs: exif.c, exif.hThilo Borgm

[FFmpeg-devel] [PATCH 05/11] avformat/mux: Refactor muxer deinit from av_write_trailer

2016-08-02 Thread sebechlebskyjan
From: Jan Sebechlebsky Move muxer deinitialization and private resources freeing in a separate static function free_muxer(AVFormatContext*). Signed-off-by: Jan Sebechlebsky --- libavformat/mux.c | 31 --- 1 file changed, 20 insertions(+), 11 deletions(-) diff --git

[FFmpeg-devel] [PATCH 08/11] avformat/mux: Restore original ts in write_packet on error

2016-08-02 Thread sebechlebskyjan
From: Jan Sebechlebsky Restore original timestamps in write_packet() if the actual write operation was not successfull. This allows to pass the same packet to nonblocking muxer repeatedly without corrupting the timestamps. Signed-off-by: Jan Sebechlebsky --- libavformat/mux.c | 9 + 1

[FFmpeg-devel] [GSoC] fifo muxer

2016-08-02 Thread sebechlebskyjan
From: Jan Sebechlebsky Hello, I am resending fifo muxer related patchset, now also with patches adding support for nonblocking calls (AVFMT_FLAG_NONBLOCK) and fate tests. Regards, Jan Jan Sebechlebsky (11): avformat: Add fifo pseudo-muxer MAINTAINERS: Add myself as maintainer of fifo muxe

[FFmpeg-devel] [PATCH 11/11] avformat/fifo: Add test for nonblocking mode

2016-08-02 Thread sebechlebskyjan
From: Jan Sebechlebsky Signed-off-by: Jan Sebechlebsky --- libavformat/tests/fifo_muxer.c | 139 + tests/ref/fate/fifo-muxer-tst | 5 ++ 2 files changed, 144 insertions(+) diff --git a/libavformat/tests/fifo_muxer.c b/libavformat/tests/fifo_muxer.c in

[FFmpeg-devel] [PATCH v5 01/11] avformat: Add fifo pseudo-muxer

2016-08-04 Thread sebechlebskyjan
From: Jan Sebechlebsky Signed-off-by: Jan Sebechlebsky --- Changes from the last version of patch: - boolean AVOptions are now ints, this was the cause of fate test segfault reported by Michael Changelog| 1 + configure| 1 + doc/muxers.texi

[FFmpeg-devel] [PATCH v2 06/11] avformat: add avformat_write_abort() function

2016-08-04 Thread sebechlebskyjan
From: Jan Sebechlebsky Signed-off-by: Jan Sebechlebsky --- Changes from last version of patch: - removed AVFMT_FLAG_NONBLOCK check and modified comment so it states how function behaves with both blocking / non-blocking muxer libavformat/avformat.h | 15 +++ libavformat/mux.c

[FFmpeg-devel] [PATCH v2 07/11] avformat/avformat.h: Add comments regarding AVFMT_FLAG_NONBLOCK.

2016-08-04 Thread sebechlebskyjan
From: Jan Sebechlebsky Add comments regarding AVFMG_FLAG_NONBLOCK usage with muxers. Signed-off-by: Jan Sebechlebsky --- There are no changes in this patch, it is just rebased version because of change in previous patch. libavformat/avformat.h | 9 - 1 file changed, 8 insertions(+),

[FFmpeg-devel] [PATCH v2 10/11] avformat/fifo: Add AVFMT_FLAG_NONBLOCK support

2016-08-04 Thread sebechlebskyjan
From: Jan Sebechlebsky Add support for nonblocking calls. Signed-off-by: Jan Sebechlebsky --- Changes from the last version: - boolean flags accessed from both threads are ints now and are accessed with atomic operations. - pthread_tryjoin_np is replaced by flag set before fifo_consume

[FFmpeg-devel] [PATCH v2 11/11] avformat/fifo: Add test for nonblocking mode

2016-08-04 Thread sebechlebskyjan
From: Jan Sebechlebsky Signed-off-by: Jan Sebechlebsky --- Changes from last version: - av_abort_output was renamed to avformat_write_abort libavformat/tests/fifo_muxer.c | 139 + tests/ref/fate/fifo-muxer-tst | 5 ++ 2 files changed, 144 insertions

[FFmpeg-devel] [PATCH v2 3/5] avcodec/bsf: Add list BSF API

2016-08-05 Thread sebechlebskyjan
From: Jan Sebechlebsky --- Changes from last version: - fixed doxygen comments - added av_bsf_list_append2() function - changed names of array and length fields to follow naming convention - idx and flushed_idx is now unsigned - merged bsf_list_flush to bsf_list_filter to reduce code duplic

[FFmpeg-devel] [PATCH v2 4/5] avcodec/bsf: Add custom item name func for BSF list

2016-08-05 Thread sebechlebskyjan
From: Jan Sebechlebsky Add custom item name function for bsf list, which will construct string description of filter chain. This is done using lazy-initialization, so there is no overhead if item name is never accessed. Signed-off-by: Jan Sebechlebsky --- No changes from last version, just reb

[FFmpeg-devel] [PATCH v2 5/5] avformat/tee: Use BSF list API

2016-08-05 Thread sebechlebskyjan
From: Jan Sebechlebsky Signed-off-by: Jan Sebechlebsky --- No changes from the last version, just rebased after Michael's commit. libavformat/tee.c | 80 +++ 1 file changed, 57 insertions(+), 23 deletions(-) diff --git a/libavformat/tee.c b

[FFmpeg-devel] [PATCH v6 01/11] avformat: Add fifo pseudo-muxer

2016-08-09 Thread sebechlebskyjan
From: Jan Sebechlebsky Signed-off-by: Jan Sebechlebsky --- Changes since the last version done according Martons review: - Documentation fixes as requested - Rearanged message processing in while loop inside fifo_cosumer_thread, added FIFO_WRITE_HEADER message type, message is initialized

[FFmpeg-devel] [PATCH v2 03/11] avformat/fifo: Add fate test

2016-08-09 Thread sebechlebskyjan
From: Jan Sebechlebsky Signed-off-by: Jan Sebechlebsky --- Changes since the last version: - Removed empty lines at the end of fifo_muxer.c file libavformat/Makefile | 1 + libavformat/tests/fifo_muxer.c | 443 + tests/Makefile

[FFmpeg-devel] [PATCH v3 10/11] avformat/fifo: Add AVFMT_FLAG_NONBLOCK support

2016-08-09 Thread sebechlebskyjan
From: Jan Sebechlebsky Add support for nonblocking calls. Signed-off-by: Jan Sebechlebsky --- No changes since the last version of the patch, just rebased because of changes in the previous commit. libavformat/fifo.c | 61 -- 1 file change

[FFmpeg-devel] [PATCH v3 5/5] avformat/tee: Use BSF list API

2016-08-09 Thread sebechlebskyjan
From: Jan Sebechlebsky Signed-off-by: Jan Sebechlebsky --- Changes since the last version of patch: - removed parse_bsfs() function I accidentaly left out (it's replaced by av_bsf_list_parse_str()) libavformat/tee.c | 120 ++ 1 file chang

[FFmpeg-devel] [PATCH v7 01/11] avformat: Add fifo pseudo-muxer

2016-08-11 Thread sebechlebskyjan
From: Jan Sebechlebsky Signed-off-by: Jan Sebechlebsky --- Changes since the last version of the patch: - Fixed thread include (old patch included pthread.h directly) Changelog| 1 + configure| 1 + doc/muxers.texi | 93 +++ libavformat/Makef

[FFmpeg-devel] [PATCH v3 03/11] avformat/fifo: Add fate test

2016-08-11 Thread sebechlebskyjan
From: Jan Sebechlebsky Signed-off-by: Jan Sebechlebsky --- Changes since the last version of the patch: - Fixed whitespace and missing $(EXESUF) in fifo-muxer.mak - Fixed "overflow with packet dropping" test which skipped write_trailer call in case of failure. libavformat/Makefile

[FFmpeg-devel] [PATCH v2 04/11] avformat/muxers: Add non-blocking mode support for av_write_trailer

2016-08-11 Thread sebechlebskyjan
From: Jan Sebechlebsky This makes av_write_trailer not to free the resources if write_trailer call returns AVERROR(EAGAIN) allowing repeated calls of write_trailer of non-blocking muxer. Signed-off-by: Jan Sebechlebsky --- Changes since the last version of the patch: - Added assert to the par

[FFmpeg-devel] [PATCH v2 05/11] avformat/mux: Refactor muxer deinit from av_write_trailer

2016-08-11 Thread sebechlebskyjan
From: Jan Sebechlebsky Move muxer deinitialization and private resources freeing in a separate static function free_muxer(AVFormatContext*). Signed-off-by: Jan Sebechlebsky --- No changes since the last version, just rebased because of changes in previous patch. libavformat/mux.c | 31 +

[FFmpeg-devel] [PATCH v3 06/11] avformat: add avformat_write_abort() function

2016-08-11 Thread sebechlebskyjan
From: Jan Sebechlebsky Signed-off-by: Jan Sebechlebsky --- No changes since the last version of the patch, just rebased because of the changes in previous patches. libavformat/avformat.h | 15 +++ libavformat/mux.c | 13 + 2 files changed, 28 insertions(+) diff

[FFmpeg-devel] [PATCH v3 07/11] avformat/mux: Comment and assert AVFMT_FLAG_NONBLOCK

2016-08-11 Thread sebechlebskyjan
From: Jan Sebechlebsky Add comments regarding AVFMG_FLAG_NONBLOCK usage with muxers. Add assert forbiding use of nonblocking muxer with av_interleaved_write_frame. Signed-off-by: Jan Sebechlebsky --- Changes since the last version of the patch: - added assert to the beginning of av_interleave

[FFmpeg-devel] [PATCH v4 10/11] avformat/fifo: Add AVFMT_FLAG_NONBLOCK support

2016-08-11 Thread sebechlebskyjan
From: Jan Sebechlebsky Add support for nonblocking calls. Signed-off-by: Jan Sebechlebsky --- Changes since the last version: - fixed wrong flag passed to av_thread_message_queue_recv() - fixed memleak when queue is full in nonblocking mode libavformat/fifo.c | 61 +

[FFmpeg-devel] [PATCH v3 11/11] avformat/fifo: Add test for nonblocking mode

2016-08-11 Thread sebechlebskyjan
From: Jan Sebechlebsky Signed-off-by: Jan Sebechlebsky --- No changes since the last version of the patch, just rebased because of changes in previous fate test patch. libavformat/tests/fifo_muxer.c | 139 + tests/ref/fate/fifo-muxer-tst | 5 ++ 2

[FFmpeg-devel] [PATCH v4 03/11] avformat/fifo: Add fate test

2016-08-11 Thread sebechlebskyjan
From: Jan Sebechlebsky Signed-off-by: Jan Sebechlebsky --- Changes since the last version of patch: - Fixed make dependencies so the tests are not executed when required components are disabled libavformat/Makefile | 1 + libavformat/tests/fifo_muxer.c | 443 +

[FFmpeg-devel] [PATCH v5 03/11] avformat/fifo: Add fate test

2016-08-12 Thread sebechlebskyjan
From: Jan Sebechlebsky Signed-off-by: Jan Sebechlebsky --- Changes since the last version of the patch: - fixed print_deinit_summary to use int instead of uint8_t libavformat/Makefile | 1 + libavformat/tests/fifo_muxer.c | 443 + tests/Mak

[FFmpeg-devel] [PATCH v8 01/11] avformat: Add fifo pseudo-muxer

2016-08-14 Thread sebechlebskyjan
From: Jan Sebechlebsky Signed-off-by: Jan Sebechlebsky --- Changes since the last version of the patch: - Fixed documentation (apart from the Marton's suggestions I've also changed example, since it used block_on_overflow option from the earlier version of patch) - Changed max_recovery_

[FFmpeg-devel] [PATCH v5 10/11] avformat/fifo: Add AVFMT_FLAG_NONBLOCK support

2016-08-14 Thread sebechlebskyjan
From: Jan Sebechlebsky Add support for nonblocking calls. Signed-off-by: Jan Sebechlebsky --- No changes since the last version of the patch, just rebased because of changes in previous patch. libavformat/fifo.c | 61 -- 1 file changed, 55

[FFmpeg-devel] [PATCH v3 4/5] avcodec/bsf: Add custom item name func for BSF list

2016-08-15 Thread sebechlebskyjan
From: Jan Sebechlebsky Add custom item name function for bsf list, which will construct string description of filter chain. This is done using lazy-initialization, so there is no overhead if item name is never accessed. Signed-off-by: Jan Sebechlebsky Conflicts: libavcodec/bsf.c --- C

[FFmpeg-devel] [PATCH v3 2/5] avcodec/bsf: Add list BSF API

2016-08-15 Thread sebechlebskyjan
From: Jan Sebechlebsky --- Changes since the last version of the patch: - removed av_freep(&bsf->item_name) from bsf_list_close since it belongs to next commit libavcodec/avcodec.h | 85 libavcodec/bsf.c | 278 +++ 2 fil

[FFmpeg-devel] [PATCH] doc/APIchanges: Document addition of list BSF API in lavc

2016-08-15 Thread sebechlebskyjan
From: Jan Sebechlebsky Signed-off-by: Jan Sebechlebsky --- doc/APIchanges | 7 +++ 1 file changed, 7 insertions(+) diff --git a/doc/APIchanges b/doc/APIchanges index 209ab41..4868d58 100644 --- a/doc/APIchanges +++ b/doc/APIchanges @@ -15,6 +15,13 @@ libavutil: 2015-08-28 API change

[FFmpeg-devel] [PATCH v9 01/11] avformat: Add fifo pseudo-muxer

2016-08-16 Thread sebechlebskyjan
From: Jan Sebechlebsky Signed-off-by: Jan Sebechlebsky --- Changes since the last version of the patch: - fixed "s@item" in muxers.texi - fixed second -> seconds in FIFO_DEFAULT_RECOVERY_WAIT_TIME_USEC comment - removed AVFormat *oformat from FifoContext (it is local variable now) - if reco

[FFmpeg-devel] [PATCH v6 10/11] avformat/fifo: Add AVFMT_FLAG_NONBLOCK support

2016-08-16 Thread sebechlebskyjan
From: Jan Sebechlebsky Add support for nonblocking calls. Signed-off-by: Jan Sebechlebsky --- No chanes since the last version of patch, rebased because of changes in the patch adding fifo. libavformat/fifo.c | 62 -- 1 file changed, 56 in

[FFmpeg-devel] [PATCH] avformat: Document thread-safety requirement for interrupt callback

2016-08-16 Thread sebechlebskyjan
From: Jan Sebechlebsky Muxing might be running in a separate thread if actual muxer is run inside of fifo pseudo-muxer. Callback should be therefore thread-safe. Signed-off-by: Jan Sebechlebsky --- libavformat/avformat.h | 2 +- libavformat/avio.h | 2 ++ 2 files changed, 3 insertions(+),

[FFmpeg-devel] [PATCH v10 01/11] avformat: Add fifo pseudo-muxer

2016-08-16 Thread sebechlebskyjan
From: Jan Sebechlebsky Signed-off-by: Jan Sebechlebsky --- Changes since the last version of the patch: - Added note in fifo muxer documentation in muxers.texi regarding thread-safety requirement for callbacks in AVFormatContext Changelog| 1 + configure|

[FFmpeg-devel] [PATCH v2] doc/APIchanges: Document addition of list BSF API in lavc

2016-08-16 Thread sebechlebskyjan
From: Jan Sebechlebsky Signed-off-by: Jan Sebechlebsky --- I've noticed that conflicting patch was applied meanwhile, so I'm resending this. Please apply :) doc/APIchanges | 7 +++ 1 file changed, 7 insertions(+) diff --git a/doc/APIchanges b/doc/APIchanges index 74145b2..582563a 10064

[FFmpeg-devel] [PATCH v11 01/11] avformat: Add fifo pseudo-muxer

2016-08-18 Thread sebechlebskyjan
From: Jan Sebechlebsky Signed-off-by: Jan Sebechlebsky --- Conflicting patch was applied meanwhile, so I am resending this one. No changes since the last version. Changelog| 1 + configure| 1 + doc/muxers.texi | 95 +++ libavformat/Makefile

[FFmpeg-devel] [PATCH v12 01/11] avformat: Add fifo pseudo-muxer

2016-08-18 Thread sebechlebskyjan
From: Jan Sebechlebsky Signed-off-by: Jan Sebechlebsky --- Changes since the last version of the patch: - fixed mistakes in docs (missing "is", 2xmisspelled "unsuccessful") - removed braces around return statement in fifo_mux_init() - fixed "return 0;" -> "return ret;" in fifo_write_header()

[FFmpeg-devel] [PATCH v7 10/11] avformat/fifo: Add AVFMT_FLAG_NONBLOCK support

2016-08-18 Thread sebechlebskyjan
From: Jan Sebechlebsky Add support for nonblocking calls. Signed-off-by: Jan Sebechlebsky --- No changes since the last version of the patch, just rebased because of changes in previous fifo patch. libavformat/fifo.c | 62 -- 1 file change

[FFmpeg-devel] [PATCH v4 5/5] avformat/tee: Use BSF list API

2016-08-25 Thread sebechlebskyjan
From: Jan Sebechlebsky Signed-off-by: Jan Sebechlebsky --- I believe I have fixed handling input / output timebase and input parameters to bitstream filters list. libavformat/tee.c | 131 ++ 1 file changed, 64 insertions(+), 67 deletions(-)

[FFmpeg-devel] [PATCH] libavcodec/bsfs: Fix bsf option setting

2016-08-25 Thread sebechlebskyjan
From: Jan Sebechlebsky AV_OPT_SEARCH_CHILDREN flag must be passed to av_opt_set_dict() to set options for private context. Signed-off-by: Jan Sebechlebsky --- libavcodec/bsf.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libavcodec/bsf.c b/libavcodec/bsf.c index 2462e62.

[FFmpeg-devel] [PATCH v5 5/5] avformat/tee: Use BSF list API

2016-09-01 Thread sebechlebskyjan
From: Jan Sebechlebsky Signed-off-by: Jan Sebechlebsky --- Changes since the last version of the patch: - added check for avcodec_parameters_copy return value - fixed stray space - rewritten cycle receiving packets from bsf so case when av_interleaved_write_frame returns EAGAIN is trea

[FFmpeg-devel] [PATCH 2/2] avformat/tee: Add FATE tests for tee

2016-09-28 Thread sebechlebskyjan
From: Jan Sebechlebsky This commit also adds new diff option for fate tests allowing do compare multiple tuples of files. Signed-off-by: Jan Sebechlebsky --- tests/Makefile| 1 + tests/fate-run.sh | 7 tests/fate/tee-muxer.mak | 2

[FFmpeg-devel] [PATCH 1/2] avformat/tee: Copy interrupt callback and flags to slave

2016-09-28 Thread sebechlebskyjan
From: Jan Sebechlebsky Copy interrupt callback to slave format context to allow user to interrupt IO. Copy format flags as well. Signed-off-by: Jan Sebechlebsky --- libavformat/tee.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/libavformat/tee.c b/libavformat/tee.c index 518af4a..d59a

[FFmpeg-devel] [PATCH] libavformat/tee: Add fifo support for tee

2016-10-06 Thread sebechlebskyjan
From: Jan Sebechlebsky Signed-off-by: Jan Sebechlebsky --- This commit makes use of fifo muxer together with tee muxer easier, fifo muxer does not have to be explicitly specified for each slave. For the most simple use case it is sufficient to turn fifo muxer on for all slaves by switching on us

[FFmpeg-devel] [PATCH v3 1/3] Refactor close_slaves function in tee muxer

2016-03-29 Thread sebechlebskyjan
From: Jan Sebechlebsky Closing single slave operation is pulled out into separate function close_slave(TeeSlave*). Both close_slave and close_slaves function are moved before open_slave function. Signed-off-by: Jan Sebechlebsky --- libavformat/tee.c | 58 ++-

[FFmpeg-devel] [PATCH v3 2/3] Fix leak and crash in tee muxer when open_slave fails

2016-03-29 Thread sebechlebskyjan
From: Jan Sebechlebsky Calling close_slave in case error is to be returned from open_slave will free allocated resources. Since failure can happen before bsfs array is initialized, close_slave must check that bsfs is not NULL before accessing tee_slave->bsfs[i] element. Signed-off-by: Jan Sebec

[FFmpeg-devel] [PATCH v3 1/3] Refactor close_slaves function in tee muxer

2016-03-29 Thread sebechlebskyjan
From: Jan Sebechlebsky Closing single slave operation is pulled out into separate function close_slave(TeeSlave*). Both close_slave and close_slaves function are moved before open_slave function. Signed-off-by: Jan Sebechlebsky --- I've missed bad spacing in close_slave argument in previous ver

[FFmpeg-devel] [PATCH v3 3/3] Tee muxer improvement (handling slave failure)

2016-03-29 Thread sebechlebskyjan
From: Jan Sebechlebsky Adds per slave option 'onfail' to the tee muxer allowing an output to fail,so other slave outputs can continue. Signed-off-by: Jan Sebechlebsky --- doc/muxers.texi | 14 libavformat/tee.c | 96 +-- 2 files ch

[FFmpeg-devel] [PATCH v4 2/3] avformat/tee: Fix leaks in tee muxer when open_slave fails

2016-04-03 Thread sebechlebskyjan
From: Jan Sebechlebsky Calling close_slave in case error is to be returned from open_slave will free allocated resources. Since failure can happen before bsfs array is initialized, close_slave must check that bsfs is not NULL before accessing tee_slave->bsfs[i] element. Signed-off-by: Jan Sebec

[FFmpeg-devel] [PATCH v4 3/3] avformat/tee: Handling slave failure in tee muxer

2016-04-03 Thread sebechlebskyjan
From: Jan Sebechlebsky Adds per slave option 'onfail' to the tee muxer allowing an output to fail,so other slave outputs can continue. Signed-off-by: Jan Sebechlebsky --- I've just added topic to commit message title as Marton Balint suggested. doc/muxers.texi | 14 libavformat/te

[FFmpeg-devel] [PATCH v4 1/3] avformat/tee: Refactor close_slaves function in tee muxer

2016-04-03 Thread sebechlebskyjan
From: Jan Sebechlebsky Closing single slave operation is pulled out into separate function close_slave(TeeSlave*). Both close_slave and close_slaves function are moved before open_slave function. Signed-off-by: Jan Sebechlebsky --- I've fixed missing spaces and added topic to commit message ti

[FFmpeg-devel] [PATCH v5 1/3] avformat/tee: Refactor close_slaves function in tee muxer

2016-04-12 Thread sebechlebskyjan
From: Jan Sebechlebsky Closing single slave operation is pulled out into separate function close_slave(TeeSlave*). Both close_slave and close_slaves function are moved before open_slave function. Signed-off-by: Jan Sebechlebsky --- libavformat/tee.c | 58 ++-

[FFmpeg-devel] [PATCH v5 2/3] avformat/tee: Fix leaks in tee muxer when open_slave fails

2016-04-12 Thread sebechlebskyjan
From: Jan Sebechlebsky Calling close_slave in case error is to be returned from open_slave will free allocated resources. Since failure can happen before bsfs array is initialized, close_slave must check that bsfs is not NULL before accessing tee_slave->bsfs[i] element. Slave muxer expects writ

[FFmpeg-devel] [PATCH v5 3/3] avformat/tee: Handling slave failure in tee muxer

2016-04-12 Thread sebechlebskyjan
From: Jan Sebechlebsky Adds per slave option 'onfail' to the tee muxer allowing an output to fail,so other slave outputs can continue. Signed-off-by: Jan Sebechlebsky --- doc/muxers.texi | 14 libavformat/tee.c | 102 +- 2 files c

[FFmpeg-devel] [GSOC] Handling slave failure in tee muxer

2016-04-12 Thread sebechlebskyjan
Hello, I'm sorry for delay. I made a few modifications to the patchset from the last version apart from issues pointed by Marton: - I discovered another source of leaks - slave muxers often allocate memory in write_header call and free them in write_trailer. write_trailer is called if write_heade

[FFmpeg-devel] [PATCH v6 3/3] avformat/tee: Handling slave failure in tee muxer

2016-04-13 Thread sebechlebskyjan
From: Jan Sebechlebsky Adds per slave option 'onfail' to the tee muxer allowing an output to fail,so other slave outputs can continue. Signed-off-by: Jan Sebechlebsky --- Thanks for pointing on the problem with testing enum for negative value. I've fixed that, so parse_slave_failure_policy_o

[FFmpeg-devel] [PATCH v8 3/3][GSOC] avformat/tee: Handling slave failure in tee muxer

2016-04-17 Thread sebechlebskyjan
From: Jan Sebechlebsky Adds per slave option 'onfail' to the tee muxer allowing an output to fail,so other slave outputs can continue. Signed-off-by: Jan Sebechlebsky --- Sorry I've missed those. It is fixed in this patch. Regards, Jan S. doc/muxers.texi | 14 + libavformat/tee.

[FFmpeg-devel] [PATCH v9 3/3][GSOC] avformat/tee: Handling slave failure in tee muxer

2016-04-17 Thread sebechlebskyjan
From: Jan Sebechlebsky Adds per slave option 'onfail' to the tee muxer allowing an output to fail,so other slave outputs can continue. Signed-off-by: Jan Sebechlebsky --- This is embarassing, sorry for that! You're right in both, I've tried to merge my old file with the changes in previous p

[FFmpeg-devel] [PATCH v10 3/3][GSOC] avformat/tee: Handling slave failure in tee muxer

2016-04-20 Thread sebechlebskyjan
From: Jan Sebechlebsky Adds per slave option 'onfail' to the tee muxer allowing an output to fail,so other slave outputs can continue. Signed-off-by: Jan Sebechlebsky --- doc/muxers.texi | 14 libavformat/tee.c | 95 --- 2 files ch

Re: [FFmpeg-devel] [PATCH v9 3/3][GSOC] avformat/tee: Handling slave failure in tee muxer

2016-04-20 Thread sebechlebskyjan
Understood :) I've modified the patch so the error is printed in that case. I'm sending both yet unapplied patches (So you don't have to search in mailing list for the most recent version of second one). Can you apply them, if it's OK now? I guess I can then create patch to replace calls to depr

[FFmpeg-devel] [PATCH v10 2/3][GSOC] avformat/tee: Fix leaks in tee muxer when open_slave fails

2016-04-20 Thread sebechlebskyjan
From: Jan Sebechlebsky In open_slave failure can happen before bsfs array is initialized, close_slave must check that bsfs is not NULL before accessing tee_slave->bsfs[i] element. Slave muxer expects write_trailer to be called if it's write_header suceeded (so resources allocated in write_header

[FFmpeg-devel] [PATCH v11 3/3][GSOC] avformat/tee: Handling slave failure in tee muxer

2016-04-20 Thread sebechlebskyjan
From: Jan Sebechlebsky Adds per slave option 'onfail' to the tee muxer allowing an output to fail,so other slave outputs can continue. Signed-off-by: Jan Sebechlebsky --- Changes from last version: -> Use av_err2str in tee_process_slave_failure instead of combination of av_strerror

[FFmpeg-devel] [PATCH 1/2] avformat/tee: Fix TeeSlave.bsfs pointer array size

2016-05-01 Thread sebechlebskyjan
From: Jan Sebechlebsky TeeSlave.bsfs is array of pointers to AVBitStreamFilterContext, so element size should be really size of a pointer, not size of TeeSlave structure. Signed-off-by: Jan Sebechlebsky --- libavformat/tee.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/l

[FFmpeg-devel] [PATCH 2/2] avformat/tee: Use ref instead copy in write_packet

2016-05-01 Thread sebechlebskyjan
From: Jan Sebechlebsky Replace av_copy_packet and deprecated av_dup_packet by creating reference using av_packet_ref. Signed-off-by: Jan Sebechlebsky --- This should be effectively the same as calling av_packet_clone, but without dynamic memory allocation (reuses local AVPacket pkt). libav

[FFmpeg-devel] [PATCH] avcodec/mjpeg2jpeg_bsf: Check ff_bsf_get_packet success

2016-05-01 Thread sebechlebskyjan
From: Jan Sebechlebsky This fixes ticket #5487 - mjpeg2jpeg bitstream filter causes segmentation fault with header-less mjpeg. Signed-off-by: Jan Sebechlebsky --- libavcodec/mjpeg2jpeg_bsf.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/libavcodec/mjpeg2jpeg_bsf.c b/li

[FFmpeg-devel] [PATCH v2] avcodec/mjpeg2jpeg_bsf: Check ff_bsf_get_packet success

2016-05-01 Thread sebechlebskyjan
From: Jan Sebechlebsky This fixes ticket #5487 - mjpeg2jpeg bitstream filter causes segmentation fault with header-less mjpeg. Signed-off-by: Jan Sebechlebsky --- libavcodec/mjpeg2jpeg_bsf.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/libavcodec/mjpeg2jpeg_bsf.c b/libavcodec/mjpeg2jp

[FFmpeg-devel] [PATCH v2 1/2] avformat/tee: Fix TeeSlave.bsfs pointer array size

2016-05-03 Thread sebechlebskyjan
From: Jan Sebechlebsky TeeSlave.bsfs is array of pointers to AVBitStreamFilterContext, so element size should be really size of a pointer, not size of TeeSlave structure. Signed-off-by: Jan Sebechlebsky --- I've rewritten sizeof as suggested :) libavformat/tee.c | 2 +- 1 file changed, 1 ins

[FFmpeg-devel] [PATCH] avformat/tee: Move to new BSF API

2016-05-10 Thread sebechlebskyjan
From: Jan Sebechlebsky Signed-off-by: Jan Sebechlebsky --- libavformat/tee.c | 171 -- 1 file changed, 139 insertions(+), 32 deletions(-) diff --git a/libavformat/tee.c b/libavformat/tee.c index 806beaa..ff0918b 100644 --- a/libavformat/tee.c

[FFmpeg-devel] [PATCH] libavutil/fifo: Fix fifo grow step

2016-06-03 Thread sebechlebskyjan
From: Jan Sebechlebsky Fifo was reallocating always to twice of the requested size. This fixes it to reallocate to requested size, or twice of the original size - whichever is greater. Signed-off-by: Jan Sebechlebsky --- I believe the intended behaviour was as described in commit message and

  1   2   >