Re: [FFmpeg-devel] [PATCHv6 4/4] libavcodec: v4l2: add support for v4l2 mem2mem codecs

2017-08-28 Thread Jorge Ramirez
On 08/25/2017 05:35 PM, wm4 wrote: +static V4L2Buffer* context_ops_dequeue_v4l2buf(V4L2Context *ctx, unsigned int timeout) +{ +struct v4l2_plane planes[VIDEO_MAX_PLANES]; +struct v4l2_buffer buf = { 0 }; +V4L2Buffer* avbuf = NULL; +struct pollfd pfd = { +.events = POLLIN

Re: [FFmpeg-devel] [PATCHv6 4/4] libavcodec: v4l2: add support for v4l2 mem2mem codecs

2017-08-28 Thread Jorge Ramirez
On 08/25/2017 05:35 PM, wm4 wrote: + +dirp = opendir("/dev"); +if (!dirp) +return AVERROR(errno); + +for (entry = readdir(dirp); entry; entry = readdir(dirp)) { + +if (strncmp(entry->d_name, "video", 5)) +continue; + +snprintf(node, sizeof(node), "/

Re: [FFmpeg-devel] [PATCHv6 4/4] libavcodec: v4l2: add support for v4l2 mem2mem codecs

2017-08-28 Thread Jorge Ramirez
On 08/25/2017 05:35 PM, wm4 wrote: +int avpriv_v4l2m2m_reinit(V4L2Context* ctx) +{ +V4L2m2mContext *s = container_of(ctx, V4L2m2mContext, capture); +int ret; + +av_log(ctx->log_ctx, AV_LOG_DEBUG, "%s reinit context\n", ctx->name); + +/* 1. streamoff */ +ret = avpriv_v4l2_conte

Re: [FFmpeg-devel] [PATCHv6 4/4] libavcodec: v4l2: add support for v4l2 mem2mem codecs

2017-08-28 Thread Jorge Ramirez
On 08/25/2017 05:35 PM, wm4 wrote: +/* + * increase the number of buffers to support h.264/h.265 + * default (configurable via option) is 16 + */ +switch (avctx->codec_id) { +case AV_CODEC_ID_H264: +case AV_CODEC_ID_HEVC: +output->num_buffers += 4; +bre

Re: [FFmpeg-devel] [PATCHv6 4/4] libavcodec: v4l2: add support for v4l2 mem2mem codecs

2017-08-28 Thread Jorge Ramirez
On 08/25/2017 05:35 PM, wm4 wrote: +#if CONFIG_VP8_V4L2M2M_DECODER +M2MDEC(vp8, "VP8", AV_CODEC_ID_VP8, NULL); +#endif + +#if CONFIG_VP9_V4L2M2M_DECODER +M2MDEC(vp9, "VP9", AV_CODEC_ID_VP9, NULL); +#endif + +#if CONFIG_HEVC_V4L2M2M_DECODER +M2MDEC(hevc, "HEVC", AV_CODEC_ID

Re: [FFmpeg-devel] [PATCH] avformat/hls: Fix DoS due to infinite loop

2017-08-28 Thread wm4
On Sun, 27 Aug 2017 19:16:03 +0200 Michael Niedermayer wrote: > On Sat, Aug 26, 2017 at 01:26:58AM +0200, Michael Niedermayer wrote: > > Fixes: loop.m3u > > > > The default max iteration count of 1000 is arbitrary and ideas for a better > > solution are welcome > > > > Found-by: Xiaohei and Wa

Re: [FFmpeg-devel] [PATCHv6 4/4] libavcodec: v4l2: add support for v4l2 mem2mem codecs

2017-08-28 Thread Alexis Ballier
Hi, On Sun, 27 Aug 2017 21:41:06 +0200 Jorge Ramirez wrote: > On 08/27/2017 09:09 PM, Jorge Ramirez wrote: > > On 08/25/2017 05:35 PM, wm4 wrote: > >>> +static int buffer_ops_v4l2buf_to_avframe(AVFrame *frame, > >>> V4L2Buffer *avbuf) +{ > >>> +int i, ret; > >>> + > >>> +av_frame_unre

Re: [FFmpeg-devel] [PATCH v15] avformat/dashdec: add dash demuxer base version

2017-08-28 Thread Rodger Combs
I would expect parsing the number internally and using the additional arg to be simpler and easier to verify than format string validation. > On Aug 28, 2017, at 04:28, samsamsam wrote: > > OK. I will. > What about adding validation of format instead of adding "something like > `"%0*"PRId64`"?

Re: [FFmpeg-devel] [PATCH] libavformat/mov: Always use av_realloc() for AVCodecParameters.extradata

2017-08-28 Thread wm4
On Sat, 26 Aug 2017 11:43:26 +0200 Michael Niedermayer wrote: > but the code removed in > 3835283293bfd38ba69203f4618f0f0f21377bcc > also would be a fix for this That code won't come back. ___ ffmpeg-devel mailing list ffmpeg-devel@ffmpeg.org http://ff

Re: [FFmpeg-devel] [PATCH] Use NULL_IF_CONFIG_SMALL for AVOption tables.

2017-08-28 Thread wm4
On Fri, 25 Aug 2017 16:20:28 -0700 Dale Curtis wrote: > Saves ~12kb of binary size and seems like a good use of > CONFIG_SMALL. I've only converted some of the largest > tables in this patch, there's way more to do if this is a > reasonable direction. > > - dale Seems way too intrusive and the

Re: [FFmpeg-devel] FFmpeg 3.4

2017-08-28 Thread wm4
On Sat, 26 Aug 2017 11:28:29 +0200 Michael Niedermayer wrote: > Hi all > > Its a while since FFmpeg 3.3, so its time again to make a new release > > I intend to make 3.4 in the next weeks > Name suggestions needed like always > At least the new channel mapping API from Libav should be part of

Re: [FFmpeg-devel] [PATCHv6 4/4] libavcodec: v4l2: add support for v4l2 mem2mem codecs

2017-08-28 Thread wm4
On Sun, 27 Aug 2017 21:41:06 +0200 Jorge Ramirez wrote: > On 08/27/2017 09:09 PM, Jorge Ramirez wrote: > > On 08/25/2017 05:35 PM, wm4 wrote: > >>> +static int buffer_ops_v4l2buf_to_avframe(AVFrame *frame, V4L2Buffer > >>> *avbuf) > >>> +{ > >>> +int i, ret; > >>> + > >>> +av_frame_unr

Re: [FFmpeg-devel] [PATCHv6 4/4] libavcodec: v4l2: add support for v4l2 mem2mem codecs

2017-08-28 Thread wm4
On Mon, 28 Aug 2017 10:21:54 +0200 Jorge Ramirez wrote: > On 08/25/2017 05:35 PM, wm4 wrote: > >> +int avpriv_v4l2m2m_reinit(V4L2Context* ctx) > >> +{ > >> +V4L2m2mContext *s = container_of(ctx, V4L2m2mContext, capture); > >> +int ret; > >> + > >> +av_log(ctx->log_ctx, AV_LOG_DEBUG, "

Re: [FFmpeg-devel] [PATCHv6 4/4] libavcodec: v4l2: add support for v4l2 mem2mem codecs

2017-08-28 Thread Jorge Ramirez
On 08/28/2017 11:26 AM, Alexis Ballier wrote: Hi, On Sun, 27 Aug 2017 21:41:06 +0200 Jorge Ramirez wrote: On 08/27/2017 09:09 PM, Jorge Ramirez wrote: On 08/25/2017 05:35 PM, wm4 wrote: +static int buffer_ops_v4l2buf_to_avframe(AVFrame *frame, V4L2Buffer *avbuf) +{ +int i, ret; + +

Re: [FFmpeg-devel] [PATCHv6 4/4] libavcodec: v4l2: add support for v4l2 mem2mem codecs

2017-08-28 Thread Mark Thompson
On 27/08/17 20:41, Jorge Ramirez wrote: > On 08/27/2017 09:09 PM, Jorge Ramirez wrote: >> On 08/25/2017 05:35 PM, wm4 wrote: +static int buffer_ops_v4l2buf_to_avframe(AVFrame *frame, V4L2Buffer *avbuf) +{ +int i, ret; + +av_frame_unref(frame); + +

Re: [FFmpeg-devel] [PATCH v15] avformat/dashdec: add dash demuxer base version

2017-08-28 Thread 刘歧
> 在 2017年8月28日,18:12,samsamsam 写道: > > Validation will be very simple. I am talking about something like this: > static int get_repl_pattern_and_format(const char *i_url, const char > *i_marker, char **o_pattern, char **o_format) > { > ... > +for(ptr=start + marker_len; ptr < (end - 1)

Re: [FFmpeg-devel] [PATCHv6 4/4] libavcodec: v4l2: add support for v4l2 mem2mem codecs

2017-08-28 Thread Jorge Ramirez
On 08/28/2017 12:04 PM, wm4 wrote: yes in response to your previous comment on the subject, I am trying to address that in v7 not releasing the context while there are buffers on the fly This is what I came up with (if you can suggest something better - ie, a way to block until the AVBufferR

Re: [FFmpeg-devel] [PATCHv6 4/4] libavcodec: v4l2: add support for v4l2 mem2mem codecs

2017-08-28 Thread Mark Thompson
On 25/08/17 16:35, wm4 wrote: > That looks generally OK. Is there any chance a hwaccel approach would > be possible instead? If I've learned anything about hardware decoding, > then that hwaccel is vastly superior to vendor-implemented full stream > decoders. Unfortunately I think the whole point

Re: [FFmpeg-devel] [PATCHv6 4/4] libavcodec: v4l2: add support for v4l2 mem2mem codecs

2017-08-28 Thread wm4
On Mon, 28 Aug 2017 12:33:38 +0200 Jorge Ramirez wrote: > On 08/28/2017 12:04 PM, wm4 wrote: > >> yes in response to your previous comment on the subject, I am trying to > >> address that in v7 not releasing the context while there are buffers on > >> the fly > >> This is what I came up with

Re: [FFmpeg-devel] [PATCH 13/18] lavc: Add mpeg2_metadata bitstream filter

2017-08-28 Thread Mark Thompson
On 21/08/17 19:21, Michael Niedermayer wrote: > On Sun, Aug 20, 2017 at 11:41:41PM +0100, Mark Thompson wrote: >> (cherry picked from commit b78c30d7ec26af67c00ce2002709a189f6a87a7e) >> --- >> configure | 1 + >> doc/bitstream_filters.texi | 36 >> libavcodec/Mak

Re: [FFmpeg-devel] FFmpeg 3.4

2017-08-28 Thread Paul B Mahol
On 8/28/17, wm4 wrote: > On Sat, 26 Aug 2017 11:28:29 +0200 > Michael Niedermayer wrote: > >> Hi all >> >> Its a while since FFmpeg 3.3, so its time again to make a new release >> >> I intend to make 3.4 in the next weeks >> Name suggestions needed like always >> > > At least the new channel mapp

Re: [FFmpeg-devel] [PATCH 02/18] h264: Add stream constraint values to the common header

2017-08-28 Thread Mark Thompson
On 21/08/17 18:04, Michael Niedermayer wrote: > On Mon, Aug 21, 2017 at 11:56:11AM +0100, Mark Thompson wrote: >> On 21/08/17 02:09, Michael Niedermayer wrote: >>> On Sun, Aug 20, 2017 at 11:41:30PM +0100, Mark Thompson wrote: With comments describing the derivation of each value. (c

Re: [FFmpeg-devel] [PATCH 0/2] Tile threading support for vp9

2017-08-28 Thread gh0st
Fixed in PATCHv3 On Mon, Aug 28, 2017 at 7:40 AM, Michael Niedermayer wrote: > On Mon, Aug 28, 2017 at 02:22:15AM +0700, Ilia Valiakhmetov wrote: > > These patches introduce tile threading support for vp9. > > > > Tile threading is ~45% faster at 2 threads vs 1. > > Frame threading is ~55% faste

Re: [FFmpeg-devel] [PATCH v15] avformat/dashdec: add dash demuxer base version

2017-08-28 Thread wm4
On Sun, 27 Aug 2017 22:19:31 +0800 Steven Liu wrote: > ffmpeg need a dash demuxer for demux the dash formats base on > https://github.com/samsamsam-iptvplayer/exteplayer3/blob/master/tmp/ffmpeg/patches/3.2.2/01_add_dash_demux.patch > > TODO: > 1. support multi bitrate dash > > v2 fixed: > 1

[FFmpeg-devel] [PATCH] avformat/utils: refine av_get_frame_filename2 function

2017-08-28 Thread Steven Liu
support parse the l for the %lld or %ld Signed-off-by: Steven Liu --- libavformat/utils.c | 4 1 file changed, 4 insertions(+) diff --git a/libavformat/utils.c b/libavformat/utils.c index 23865c88c4..c76a6cc5f8 100644 --- a/libavformat/utils.c +++ b/libavformat/utils.c @@ -4570,6 +4570,7 @

Re: [FFmpeg-devel] [PATCHv6 4/4] libavcodec: v4l2: add support for v4l2 mem2mem codecs

2017-08-28 Thread Jorge Ramirez
On 08/28/2017 12:47 PM, wm4 wrote: I guess that instead of polling for the AVBufferRef to be unreferenced, I can associate a sync (ie a sempahore) to each buffer, take it on release and post the semaphore on the AVBufferRefs being unreferenced. that is actually pretty clean in terms of cpu usage.

Re: [FFmpeg-devel] [PATCH] lavc/vaapi_encode_h265: Enable VBR mode

2017-08-28 Thread Mark Thompson
On 25/08/17 08:56, Jun Zhao wrote: > From 483204cf7c25077d556c86b9e70f591fc2c0d4a3 Mon Sep 17 00:00:00 2001 > From: Jun Zhao > Date: Fri, 25 Aug 2017 03:50:37 -0400 > Subject: [PATCH] lavc/vaapi_encode_h265: Enable VBR mode > > Follow vaapi_h264 style, enable the VBR mode. > > Signed-off-by: Jun

Re: [FFmpeg-devel] [V5 1/4] lavc/vaapi_encode: Change the slice/parameter buffers to dynamic alloc.

2017-08-28 Thread Mark Thompson
On 24/08/17 02:13, Jun Zhao wrote: > V5: - In h265_vaapi encoder, when setting slice number > max slice number > supported by driver, report error and return. Same as h264_vaapi. > - Clean the logic when setting first_slice_segment_in_pic_flags > V4: - Change the array malloc function.

[FFmpeg-devel] [PATCH] avfilter: add despill filter

2017-08-28 Thread Paul B Mahol
Signed-off-by: Paul B Mahol --- doc/filters.texi | 35 + libavfilter/Makefile | 1 + libavfilter/allfilters.c | 1 + libavfilter/vf_despill.c | 183 +++ 4 files changed, 220 insertions(+) create mode 100644 libavfilter/vf_despi

Re: [FFmpeg-devel] [PATCH]lavf/gdv: Improve palette saturation

2017-08-28 Thread Carl Eugen Hoyos
2017-08-27 9:03 GMT+02:00 Paul B Mahol : > On 8/26/17, Carl Eugen Hoyos wrote: >> Attached patch slightly improves the saturation of the >> gdv palette. >> >> Please comment, Carl Eugen > > Does this match how it is displayed by original game? The original game was written for a graphic adapter

Re: [FFmpeg-devel] FFmpeg 3.4

2017-08-28 Thread James Almer
On 8/28/2017 6:46 AM, wm4 wrote: > On Sat, 26 Aug 2017 11:28:29 +0200 > Michael Niedermayer wrote: > >> Hi all >> >> Its a while since FFmpeg 3.3, so its time again to make a new release >> >> I intend to make 3.4 in the next weeks >> Name suggestions needed like always >> > > At least the new c

Re: [FFmpeg-devel] fate/pixlet : add test for rgb

2017-08-28 Thread Martin Vignali
2017-04-03 2:21 GMT+02:00 Michael Niedermayer : > On Sun, Apr 02, 2017 at 11:29:38PM +0200, Martin Vignali wrote: > > Hello, > > > > In attach patch to add a fate test for pixlet decoder > > > > Sample can be found here : > > https://we.tl/HYuFmmmfIe > > file uploaded > Ping for the patch Martin

Re: [FFmpeg-devel] fate/cineform : add test for yuv 10b

2017-08-28 Thread Martin Vignali
2017-03-26 1:17 GMT+01:00 Michael Niedermayer : > On Sat, Mar 25, 2017 at 02:04:03PM +0100, Martin Vignali wrote: > > Hello, > > > > In attach patch to add fate test for cineform decoder > > > > Sample can be found here : > > https://we.tl/y06cKrKh3a > > > > there is two sample in the download lin

[FFmpeg-devel] [PATCH] libavformat/dv : read dv audio as BE

2017-08-28 Thread Александр Слободенюк
Fixing the FIXME issue, where BE audio inside the dv codec reads as LE after swapping it's bytes. It's was not very clear, because if we read it on BE machine we'll swap it twice. 0001-libavformat-dv-read-dv-audio-as-BE.patch Description: Binary data ___

Re: [FFmpeg-devel] [PATCH] libavformat/dv : read dv audio as BE

2017-08-28 Thread Carl Eugen Hoyos
2017-08-28 18:22 GMT+02:00 Александр Слободенюк : > Fixing the FIXME issue, where BE audio inside the dv codec reads as LE > after swapping it's bytes. It's was not very clear, because if we read > it on BE machine we'll swap it twice. > -static int dv_extract_audio(const uint8_t *frame, uint8_t *

Re: [FFmpeg-devel] [PATCHv6 4/4] libavcodec: v4l2: add support for v4l2 mem2mem codecs

2017-08-28 Thread Jorge Ramirez
On 08/25/2017 05:35 PM, wm4 wrote: + +#define SET_V4L2_EXT_CTRL(TYPE, ID, VALUE, NAME)\ +{ \ +struct v4l2_ext_control ctrl = { 0 }; \ +struct v4l2_ext_controls ctrls = { 0 };

Re: [FFmpeg-devel] [PATCH] libavformat/dv : read dv audio as BE

2017-08-28 Thread Carl Eugen Hoyos
2017-08-28 18:42 GMT+02:00 Carl Eugen Hoyos : > 2017-08-28 18:22 GMT+02:00 Александр Слободенюк > : >> Fixing the FIXME issue, where BE audio inside the dv codec reads as LE >> after swapping it's bytes. It's was not very clear, because if we read >> it on BE machine we'll swap it twice. > >> -stat

Re: [FFmpeg-devel] [PATCHv6 4/4] libavcodec: v4l2: add support for v4l2 mem2mem codecs

2017-08-28 Thread Jorge Ramirez
On 08/25/2017 05:35 PM, wm4 wrote: +static inline int v4l2_h264_profile_from_ff(int p) +{ +switch(p) { +case FF_PROFILE_H264_CONSTRAINED_BASELINE: +return MPEG_VIDEO(H264_PROFILE_CONSTRAINED_BASELINE); +case FF_PROFILE_H264_HIGH_444_PREDICTIVE: +return MPEG_VIDEO(H264_

Re: [FFmpeg-devel] Odp: Re: [PATCH v15] avformat/dashdec: add dash demuxer base version

2017-08-28 Thread samsamsam
OK. I will. What about adding validation of format instead of adding " something like `"%0*"PRId64`"? Dnia 28 sierpnia 2017 03:30 Rodger Combs napisał(a): If you know of such a vulnerability, report it toffmpeg-secur...@ffmpeg.org . New code with known vulnerabil

[FFmpeg-devel] Odp: Re: [PATCH v15] avformat/dashdec: add dash demuxer base version

2017-08-28 Thread samsamsam
Validation will be very simple. I am talking about something like this: static int get_repl_pattern_and_format(co char *i_url, const char *i_marker, char **o_pattern, char **o_format) { ... +    for(ptr=start + marker_len; ptr < (end - 1); ++ptr) {  /*there is need to check this conditi

[FFmpeg-devel] [PATCH] avfilter/mcdeint: remove usage of deprecated AVCodecContext.me_method

2017-08-28 Thread James Almer
Signed-off-by: James Almer --- Depends on patch "avcodec/snowenc: fix setting motion_est option" libavfilter/vf_mcdeint.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/libavfilter/vf_mcdeint.c b/libavfilter/vf_mcdeint.c index 26387b84e7..f07e1a0d60 100644 --- a/libavfilte

Re: [FFmpeg-devel] [PATCH] Use NULL_IF_CONFIG_SMALL for AVOption tables.

2017-08-28 Thread Dale Curtis
On Mon, Aug 28, 2017 at 2:28 AM, wm4 wrote: > > > Seems way too intrusive and the result makes AVOption tables even > uglier and harder to read. Agree it's ugly. Any suggestions? I tried some way of forcing the AVOption entry to have zero-storage (thus null always), but my language-fu was not st

Re: [FFmpeg-devel] [PATCH] Use NULL_IF_CONFIG_SMALL for AVOption tables.

2017-08-28 Thread Rostislav Pehlivanov
On 26 August 2017 at 00:20, Dale Curtis wrote: > Saves ~12kb of binary size and seems like a good use of > CONFIG_SMALL. I've only converted some of the largest > tables in this patch, there's way more to do if this is a > reasonable direction. > > - dale > > _

Re: [FFmpeg-devel] [PATCH] Use NULL_IF_CONFIG_SMALL for AVOption tables.

2017-08-28 Thread Carl Eugen Hoyos
2017-08-28 20:42 GMT+02:00 Rostislav Pehlivanov : > I disagree with this patch as well. > If you need more space savings use LTO. How is this related? > IMO we should drop CONFIG_SMALL for codec descriptions too. Did this ever hit you in any way? Carl Eugen ___

Re: [FFmpeg-devel] [PATCHv6 4/4] libavcodec: v4l2: add support for v4l2 mem2mem codecs

2017-08-28 Thread Jorge Ramirez
On 08/28/2017 02:16 PM, Jorge Ramirez wrote: On 08/28/2017 12:47 PM, wm4 wrote: I guess that instead of polling for the AVBufferRef to be unreferenced, I can associate a sync (ie a sempahore) to each buffer, take it on release and post the semaphore on the AVBufferRefs being unreferenced. that i

Re: [FFmpeg-devel] Odp: Re: [PATCH v15] avformat/dashdec: add dash demuxer base version

2017-08-28 Thread wm4
On Mon, 28 Aug 2017 11:28:33 +0200 samsamsam wrote: > OK. I will. What about adding validation of format instead of adding " > something like `"%0*"PRId64`"? Dnia 28 sierpnia 2017 03:30 > Rodger Combs napisał(a): If you know of such > a vulnerability, report it to

Re: [FFmpeg-devel] [PATCHv6 4/4] libavcodec: v4l2: add support for v4l2 mem2mem codecs

2017-08-28 Thread wm4
On Mon, 28 Aug 2017 21:24:26 +0200 Jorge Ramirez wrote: > On 08/28/2017 02:16 PM, Jorge Ramirez wrote: > > On 08/28/2017 12:47 PM, wm4 wrote: > >>> I guess that instead of polling for the AVBufferRef to be unreferenced, > >>> I can associate a sync (ie a sempahore) to each buffer, take it on >

Re: [FFmpeg-devel] [PATCH] Use NULL_IF_CONFIG_SMALL for AVOption tables.

2017-08-28 Thread wm4
On Mon, 28 Aug 2017 19:42:44 +0100 Rostislav Pehlivanov wrote: > On 26 August 2017 at 00:20, Dale Curtis wrote: > > > Saves ~12kb of binary size and seems like a good use of > > CONFIG_SMALL. I've only converted some of the largest > > tables in this patch, there's way more to do if this is a >

Re: [FFmpeg-devel] [PATCH] Use NULL_IF_CONFIG_SMALL for AVOption tables.

2017-08-28 Thread Dale Curtis
On Mon, Aug 28, 2017 at 12:56 PM, wm4 wrote: > > LTO seems unlikely to help in this situation - the linker can't know > whether struct members and their initializers are unused. > Correct. > > But I think there's much much bigger fish to fry to save space. For > example, I bet disabling unneede

Re: [FFmpeg-devel] [PATCH] Use NULL_IF_CONFIG_SMALL for AVOption tables.

2017-08-28 Thread wm4
On Mon, 28 Aug 2017 13:28:16 -0700 Dale Curtis wrote: > On Mon, Aug 28, 2017 at 12:56 PM, wm4 wrote: > > > > LTO seems unlikely to help in this situation - the linker can't know > > whether struct members and their initializers are unused. > > > > Correct. > > > > > > But I think there's mu

Re: [FFmpeg-devel] [PATCH] Use NULL_IF_CONFIG_SMALL for AVOption tables.

2017-08-28 Thread Marton Balint
On Mon, 28 Aug 2017, Dale Curtis wrote: On Mon, Aug 28, 2017 at 2:28 AM, wm4 wrote: Seems way too intrusive and the result makes AVOption tables even uglier and harder to read. Agree it's ugly. Any suggestions? I tried some way of forcing the AVOption entry to have zero-storage (thus nul

Re: [FFmpeg-devel] [PATCHv6 4/4] libavcodec: v4l2: add support for v4l2 mem2mem codecs

2017-08-28 Thread Jorge Ramirez
On 08/28/2017 09:53 PM, wm4 wrote: On Mon, 28 Aug 2017 21:24:26 +0200 Jorge Ramirez wrote: On 08/28/2017 02:16 PM, Jorge Ramirez wrote: On 08/28/2017 12:47 PM, wm4 wrote: I guess that instead of polling for the AVBufferRef to be unreferenced, I can associate a sync (ie a sempahore) to each b

Re: [FFmpeg-devel] [PATCHv6 4/4] libavcodec: v4l2: add support for v4l2 mem2mem codecs

2017-08-28 Thread Hendrik Leppkes
On Mon, Aug 28, 2017 at 11:36 PM, Jorge Ramirez wrote: >> >> But manually "nesting" AVBufferRefs to make any underlying state >> refcounted would also work. > > > I think so, context release now looks like this (it raises an ERROR to the > user) but will not lock or poll. > Thats not really what

Re: [FFmpeg-devel] [mov] Bail when invalid sample data is present.

2017-08-28 Thread Dale Curtis
On Fri, Aug 25, 2017 at 6:09 PM, Michael Niedermayer wrote: > > This changes the printed duration start time and bitrate for > MAV_0034.3G2 > see > https://trac.ffmpeg.org/ticket/2757 Thanks, I've restored the ability to query these types of files. That file also reveals the potential for a case

Re: [FFmpeg-devel] [PATCHv6 4/4] libavcodec: v4l2: add support for v4l2 mem2mem codecs

2017-08-28 Thread Jorge Ramirez
On 08/28/2017 11:42 PM, Hendrik Leppkes wrote: On Mon, Aug 28, 2017 at 11:36 PM, Jorge Ramirez wrote: But manually "nesting" AVBufferRefs to make any underlying state refcounted would also work. I think so, context release now looks like this (it raises an ERROR to the user) but will not lock

Re: [FFmpeg-devel] [PATCH] avformat/mov: prevent duplication of first fragment's ctts_data

2017-08-28 Thread Dale Curtis
lgtm, my patch is still necessary to ensure ctts samples aren't trampled when new headers do need to be read. This should prevent unnecessary work and spammy logs. - dale On Sat, Aug 5, 2017 at 6:04 PM, Daniel Glöckner wrote: > MP4 files with fragments might have the first moof box that is ment

Re: [FFmpeg-devel] [mov] Fix trampling of ctts during seeks when sidx support is enabled.

2017-08-28 Thread Dale Curtis
On Fri, Aug 25, 2017 at 10:18 AM, Michael Niedermayer < mich...@niedermayer.cc> wrote: > > hmm > > maybe i misunderstand but assuming we insert a block of dummy blank > entries (without breaking monotonicity) and keep a pointer to that > block > > then add entries with a av_add_index_entry() > and

[FFmpeg-devel] [mov] Remove concept of ctts entries with count > 1.

2017-08-28 Thread Dale Curtis
Previous ctts patches have all changed the system to always using count=1 since we expect ctts data to be 1:1 with samples. This deletes the concept of count>1 samples for clarity and performance. Requires "[mov] Bail when invalid sample data is present." to land first.\ - dale one_count_ctts.p

[FFmpeg-devel] [PATCH] Fix SIGBUS on ARM when compiled with binutils 2.29

2017-08-28 Thread James Cowgill
In binutils 2.29, the behavior of the ADR instruction changed so that 1 is added to the address of a Thumb function (previously nothing was added). This allows the loaded address to be passed to a BLX instruction and the correct mode change will occur. So that the behavior matches in binutils 2.29

[FFmpeg-devel] [PATCH 1/3] avformat/mxfenc: Allow overriding numerical color_siting value.

2017-08-28 Thread Michael Niedermayer
Signed-off-by: Michael Niedermayer --- libavformat/mxfenc.c | 7 ++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/libavformat/mxfenc.c b/libavformat/mxfenc.c index 12fc9abbc6..ccfa0d6341 100644 --- a/libavformat/mxfenc.c +++ b/libavformat/mxfenc.c @@ -322,6 +322,7 @@ typedef s

[FFmpeg-devel] [PATCH 2/3] avformat/mxfenc: Check that the video codec in D-10 is MPEG-2

2017-08-28 Thread Michael Niedermayer
Others do not work, but nothing rejects them prior to this patch if the parameters otherwise match Signed-off-by: Michael Niedermayer --- libavformat/mxfenc.c | 4 1 file changed, 4 insertions(+) diff --git a/libavformat/mxfenc.c b/libavformat/mxfenc.c index ccfa0d6341..71f4b5b905 100644 -

[FFmpeg-devel] [PATCH 3/3] avformat/mxfenc: Replace literal numbers by named enum values.

2017-08-28 Thread Michael Niedermayer
Signed-off-by: Michael Niedermayer --- libavformat/mxfenc.c | 83 ++-- 1 file changed, 61 insertions(+), 22 deletions(-) diff --git a/libavformat/mxfenc.c b/libavformat/mxfenc.c index 71f4b5b905..afa5ef7e28 100644 --- a/libavformat/mxfenc.c +++ b/l

Re: [FFmpeg-devel] [PATCH v4] avcodec/snowenc: fix setting motion_est option

2017-08-28 Thread Michael Niedermayer
On Sat, Aug 26, 2017 at 10:53:10PM -0300, James Almer wrote: > Remove usage of FF_MPV_COMMON_OPTS, and set SnowContext.motion_est directly. > Based on code from svq1enc.c > > Signed-off-by: James Almer > --- > libavcodec/snow.h| 3 ++- > libavcodec/snowenc.c | 11 +++ > 2 files chan

Re: [FFmpeg-devel] [PATCH v4] avcodec/snowenc: fix setting motion_est option

2017-08-28 Thread James Almer
On 8/28/2017 9:13 PM, Michael Niedermayer wrote: > On Sat, Aug 26, 2017 at 10:53:10PM -0300, James Almer wrote: >> Remove usage of FF_MPV_COMMON_OPTS, and set SnowContext.motion_est directly. >> Based on code from svq1enc.c >> >> Signed-off-by: James Almer >> --- >> libavcodec/snow.h| 3 ++-

[FFmpeg-devel] [PATCH] compat/cuda/ptx2c: strip CR from each line

2017-08-28 Thread Ricardo Constantino
Windows nvcc + cl.exe produce a .ctx file with CR+LF newlines which need to be stripped to work with gcc. --- compat/cuda/ptx2c.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/compat/cuda/ptx2c.sh b/compat/cuda/ptx2c.sh index 1f37023290..44b08b6ea2 100755 --- a/compat/cuda/p

Re: [FFmpeg-devel] [PATCH] avformat/hls: Fix DoS due to infinite loop

2017-08-28 Thread Michael Niedermayer
On Mon, Aug 28, 2017 at 11:21:39AM +0200, wm4 wrote: > On Sun, 27 Aug 2017 19:16:03 +0200 > Michael Niedermayer wrote: > > > On Sat, Aug 26, 2017 at 01:26:58AM +0200, Michael Niedermayer wrote: > > > Fixes: loop.m3u > > > > > > The default max iteration count of 1000 is arbitrary and ideas for a

[FFmpeg-devel] [PATCH] avformat/concatdec: add fallback for calculating file duration

2017-08-28 Thread Justin Ruggles
If a file does not have a known duration, this leads to the timestamps starting over for the next file, causing non-monotonic timestamps. To prevent this, track the duration during demuxing and use it to determine the current file duration before opening the next file. --- libavformat/concatdec.c

Re: [FFmpeg-devel] [PATCHv6 4/4] libavcodec: v4l2: add support for v4l2 mem2mem codecs

2017-08-28 Thread Jorge Ramirez
On 08/29/2017 12:18 AM, Hendrik Leppkes wrote: On Tue, Aug 29, 2017 at 12:07 AM, Jorge Ramirez wrote: On 08/28/2017 11:42 PM, Hendrik Leppkes wrote: On Mon, Aug 28, 2017 at 11:36 PM, Jorge Ramirez wrote: But manually "nesting" AVBufferRefs to make any underlying state refcounted would also w