[FFmpeg-devel] [PATCH] libavformat/fifo: Fix initialization of underlying AVFormatContext

2017-07-06 Thread sebechlebskyjan
From: Jan Sebechlebsky Pass filename to AVFormatContext of underlying muxer. This commit fixes bug #6308. Signed-off-by: Jan Sebechlebsky --- libavformat/fifo.c | 7 --- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git

[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 @@

[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

[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 +

[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

[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

[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

[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

[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

[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

[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

[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

[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

[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() -

[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 +

[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

[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

[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 +-

[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

[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

[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

[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

[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

[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 |

[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 +

[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

[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

[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

[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

[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

[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

[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

[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 +

[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

[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

[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

[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

[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

[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

[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

[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. -

[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

[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 +

[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

[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

[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

[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

[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 @@

[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.

[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 ---

[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

[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

[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.

[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

[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.

[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

[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

[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

[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

[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

[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

[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

[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 @@

[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.

[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

[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

[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(+),

[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

[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

[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

[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

[FFmpeg-devel] [PATCH v2 03/10] avformat/tee: Support flushing by writing NULL pkt

2016-07-11 Thread sebechlebskyjan
From: Jan Sebechlebsky This will add support for flushing by writing NULL packet to the tee muxer, which propagates the action to slave muxers as expected. Signed-off-by: Jan Sebechlebsky --- Unfortunately, I've realized that I've

[FFmpeg-devel] [PATCH 5/7] avformat/utils: Add ff_format_output_open() function

2016-07-04 Thread sebechlebskyjan
From: Jan Sebechlebsky Add ff_format_output_open utility function to wrap io_open callback of AVFormatContext structure. Signed-off-by: Jan Sebechlebsky --- libavformat/internal.h | 10 ++ libavformat/utils.c| 10 ++ 2

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

2016-07-04 Thread sebechlebskyjan
From: Jan Sebechlebsky Signed-off-by: Jan Sebechlebsky --- libavformat/internal.h | 9 libavformat/utils.c| 56 ++ 2 files changed, 65 insertions(+) diff --git

[FFmpeg-devel] [PATCH 6/7] avformat/tee: Use ff_format_output_open() function

2016-07-04 Thread sebechlebskyjan
From: Jan Sebechlebsky Signed-off-by: Jan Sebechlebsky --- libavformat/tee.c | 11 +-- 1 file changed, 5 insertions(+), 6 deletions(-) diff --git a/libavformat/tee.c b/libavformat/tee.c index 996d64d..c60a77f 100644 ---

[FFmpeg-devel] [PATCH 7/7] libavformat: Add FIFO pseudo-muxer

2016-07-04 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.

[FFmpeg-devel] [PATCH 3/7] avformat/tee: Handle AV_NOPTS_VALUE correctly

2016-07-04 Thread sebechlebskyjan
From: Jan Sebechlebsky Do not rescale pts and dts if they are set to AV_NOPTS_VALUE. Signed-off-by: Jan Sebechlebsky --- libavformat/tee.c | 6 -- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/libavformat/tee.c

[FFmpeg-devel] [PATCH 4/7] avformat/tee: Support flushing by writing NULL pkt

2016-07-04 Thread sebechlebskyjan
From: Jan Sebechlebsky This will fix crash when caller attempts to flush by calling write_packet with NULL packet pointer and flushes slaves as expected. Signed-off-by: Jan Sebechlebsky --- libavformat/tee.c | 11 +++ 1 file

[FFmpeg-devel] [PATCH 4/4] avformat/tee: Support flushing by writing NULL pkt

2016-06-30 Thread sebechlebskyjan
From: Jan Sebechlebsky This will fix crash when caller attempts to flush by calling write_packet with NULL packet pointer and flushes slaves as expected. Signed-off-by: Jan Sebechlebsky --- libavformat/tee.c | 11 +++ 1 file

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

2016-06-30 Thread sebechlebskyjan
From: Jan Sebechlebsky Signed-off-by: Jan Sebechlebsky --- Nicolas - this is the second of the utility functions you asked for in reply to my fifo pseudo-muxer patch. I've tried to search for references to AVStream fields in muxers for

[FFmpeg-devel] [PATCH 3/4] avformat/tee: Handle AV_NOPTS_VALUE correctly

2016-06-30 Thread sebechlebskyjan
From: Jan Sebechlebsky Do not rescale pts and dts if they are set to AV_NOPTS_VALUE. Signed-off-by: Jan Sebechlebsky --- libavformat/tee.c | 6 -- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/libavformat/tee.c

[FFmpeg-devel] [PATCH 2/4] avformat/tee: Use ff_stream_encode_params_copy()

2016-06-30 Thread sebechlebskyjan
From: Jan Sebechlebsky Use ff_stream_encode_params_copy() to copy encoding-related fields (parameters) of stream. Signed-off-by: Jan Sebechlebsky --- libavformat/tee.c | 14 +++--- 1 file changed, 3 insertions(+), 11 deletions(-)

[FFmpeg-devel] [PATCH] libavformat: Add FIFO pseudo-muxer

2016-06-28 Thread sebechlebskyjan
From: Jan Sebechlebsky FIFO pseudo-muxer allows to separate decoder from the actual output by using 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.

[FFmpeg-devel] [GSoC][PATCH] Add FIFO muxer

2016-06-28 Thread sebechlebskyjan
From: Jan Sebechlebsky Hello, I'm sending the patch with implementation of discussed FIFO pseudo-muxer which is part of my GSoC project. The muxer allows to separate decoder from the actual muxer (or several muxers when combined with tee). Trasparent recovery from

[FFmpeg-devel] [PATCH v3] avformat/tee: Support arbitrary number of slaves

2016-06-25 Thread sebechlebskyjan
From: Jan Sebechlebsky Signed-off-by: Jan Sebechlebsky --- You're right. Should be fixed here. libavformat/tee.c | 26 -- 1 file changed, 16 insertions(+), 10 deletions(-) diff --git a/libavformat/tee.c

[FFmpeg-devel] [PATCH v2 3/3] avformat/segment: Use deinit function to deinitialize muxer

2016-06-20 Thread sebechlebskyjan
From: Jan Sebechlebsky This commit moves all deinitialization of SegmentContext to seg_free_context function and registers this function as .deinit function of segment muxer. This also fixes memory leaks caused by context not being deinitialized when write_header call

[FFmpeg-devel] [PATCH 1/3] avformat/segment: Check write_header return value immediately

2016-06-20 Thread sebechlebskyjan
From: Jan Sebechlebsky Check write_header return value immediately after call, so in the successive statements we can assume the write_header was successful. Signed-off-by: Jan Sebechlebsky --- This is needed for the next patch in

[FFmpeg-devel] Fix memory leaks in segment muxer

2016-06-20 Thread sebechlebskyjan
From: Jan Sebechlebsky Hello, I've observed several memory leaks in segment muxer in case the failure happens in seg_init (write_header call). I'm sending patchset to fix those. Regards, Jan Jan Sebechlebsky (3): avformat/segment: Check write_header return value

[FFmpeg-devel] [PATCH 3/3] avformat/segment: Use deinit function to deinitialize muxer

2016-06-20 Thread sebechlebskyjan
From: Jan Sebechlebsky This commit moves all deinitialization of SegmentContext to seg_free_context function and registers this function as .deinit function of segment muxer. This also fixes memory leaks caused by context not being deinitialized when write_header call

[FFmpeg-devel] [PATCH 2/3] avformat/segment: Ensure write_trailer is called

2016-06-20 Thread sebechlebskyjan
From: Jan Sebechlebsky Ensure that write_trailer is always called after successful write_header operation so underlying muxer is deinitialized. Signed-off-by: Jan Sebechlebsky --- This is a little tricky - we have to ensure that

[FFmpeg-devel] [PATCH v3] avformat/tee: Support arbitrary number of slaves

2016-06-16 Thread sebechlebskyjan
From: Jan Sebechlebsky Signed-off-by: Jan Sebechlebsky --- I've missed that - sorry, should be fixed in this patch. libavformat/tee.c | 26 +++--- 1 file changed, 15 insertions(+), 11 deletions(-) diff --git

[FFmpeg-devel] [PATCH v2] avformat/tee: Support arbitrary number of slaves

2016-06-12 Thread sebechlebskyjan
From: Jan Sebechlebsky Signed-off-by: Jan Sebechlebsky --- libavformat/tee.c | 24 +++- 1 file changed, 15 insertions(+), 9 deletions(-) diff --git a/libavformat/tee.c b/libavformat/tee.c index 806beaa..bf7438c 100644

[FFmpeg-devel] [PATCH] avformat/tee: Support arbitrary number of slaves

2016-06-10 Thread sebechlebskyjan
From: Jan Sebechlebsky Signed-off-by: Jan Sebechlebsky --- libavformat/tee.c | 27 +-- 1 file changed, 17 insertions(+), 10 deletions(-) diff --git a/libavformat/tee.c b/libavformat/tee.c index 806beaa..427e999

[FFmpeg-devel] [PATCH] avutil/threadmessage.h: Fix swapped comments

2016-06-10 Thread sebechlebskyjan
From: Jan Sebechlebsky Fix swapped descriptions of av_thread_message_queue_set_err_send and av_thread_message_queue_set_err_recv. Signed-off-by: Jan Sebechlebsky --- libavutil/threadmessage.h | 16 1 file changed, 8

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

2016-06-04 Thread sebechlebskyjan
From: Jan Sebechlebsky Signed-off-by: Jan Sebechlebsky --- I've rewritten the patch rapidly. Instead of using recursion it accumulates bitstream filtered packets in fifo buffer and dynamic array is used instead of linked list to store

[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

[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

[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

[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

[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

  1   2   >