Re: [FFmpeg-devel] [PATCH v2 0/7] HEVC native support for Screen content coding

2020-09-10 Thread Xiang, Haihao

Hi James,

Your concerns about SCC PPS were addressed in the new version. 
http://ffmpeg.org/pipermail/ffmpeg-devel/2020-July/266037.html
http://ffmpeg.org/pipermail/ffmpeg-devel/2020-July/266038.html

Could you please take a look when you have time?

Thanks
Haihao


> Resend Linjie's patchset with the updates.
> 
> As a part of the support for VA-API HEVC SCC decoding (gen12, Tiger
> Lake+).
> 
> The full support could be accessed in:
> https://github.com/intel-media-ci/ffmpeg/pull/231
> 
> The VAAPI part would be provided later once the implementations of
> native parsing and reference management are all decent.
> 
> Linjie Fu (7):
>   lavc/avcodec: Add FF_PROFILE_HEVC_SCC for screen content coding
>   lavc/hevc_ps: Add sps parse support for HEVC SCC extension syntax
>   lavc/hevc_ps: Add pps parse support for HEVC SCC extension
>   lavc/hevc_ps: Add slice parse support for HEVC SCC extension
>   lavc/hevcdec: Fix the parsing for use_integer_mv_flag
>   lavc/hevcdec: Set max_num_merge_cand to uint8_t
>   lavc/hevc: Update reference list for SCC
> 
>  libavcodec/avcodec.h   |   1 +
>  libavcodec/hevc.h  |   3 ++
>  libavcodec/hevc_ps.c   | 118 +++--
>  libavcodec/hevc_ps.h   |  32 +++
>  libavcodec/hevc_refs.c |  27 +-
>  libavcodec/hevcdec.c   |  17 +-
>  libavcodec/hevcdec.h   |   7 ++-
>  libavcodec/profiles.c  |   1 +
>  8 files changed, 197 insertions(+), 9 deletions(-)
> 
___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
https://ffmpeg.org/mailman/listinfo/ffmpeg-devel

To unsubscribe, visit link above, or email
ffmpeg-devel-requ...@ffmpeg.org with subject "unsubscribe".

Re: [FFmpeg-devel] [PATCH] avfilter: add http video filter.

2020-09-10 Thread Timo Rothenpieler

Entirely outside of this filter being acceptable at all,
pulling in libcurl is not an option without major safeguards for every 
single overlapping tls library both ffmpeg and curl support.
If both are using the same library, there is a huge potential for 
libcurl being linked at all breaks ffmpegs ability to talk TLS.


On top of that, ffmpeg already has code to talk to http servers, so 
pulling in a library to do it is even less acceptable.


I also really fail to see the utility of this filter. What's stopping 
you from just making ffmpeg output raw frames and then sending them off 
via the curl cli tool or whatever else?

___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
https://ffmpeg.org/mailman/listinfo/ffmpeg-devel

To unsubscribe, visit link above, or email
ffmpeg-devel-requ...@ffmpeg.org with subject "unsubscribe".

[FFmpeg-devel] [PATCH] avfilter: add http video filter.

2020-09-10 Thread Alex
Signed-off-by: alex_qt <3.1...@ukr.net>
---
 Changelog|   1 +
 configure|   4 +
 doc/filters.texi |  28 +
 libavfilter/Makefile |   1 +
 libavfilter/allfilters.c |   1 +
 libavfilter/version.h|   2 +-
 libavfilter/vf_http.c| 221 +++
 7 files changed, 257 insertions(+), 1 deletion(-)
 create mode 100644 libavfilter/vf_http.c


diff --git a/Changelog b/Changelog
index cd8be931ef..777cca679a 100644
--- a/Changelog
+++ b/Changelog
@@ -22,6 +22,7 @@ version :
 - MODS demuxer
 - PhotoCD decoder
 - MCA demuxer
+- http video filter, send raw frames to remote url for postprocessing
 
 
 version 4.3:
diff --git a/configure b/configure
index ae8c6e61c8..f5131d4669 100755
--- a/configure
+++ b/configure
@@ -325,6 +325,7 @@ External library support:
   --enable-vulkan  enable Vulkan code [no]
   --disable-xlib   disable xlib [autodetect]
   --disable-zlib   disable zlib [autodetect]
+  --enable-libcurl enable http filter that send raw frames to remote server
 
   The following libraries provide various hardware acceleration features:
   --disable-amfdisable AMF video encoding code [autodetect]
@@ -1827,6 +1828,7 @@ EXTERNAL_LIBRARY_LIST="
 opengl
 pocketsphinx
 vapoursynth
+libcurl
 "
 
 HWACCEL_AUTODETECT_LIBRARY_LIST="
@@ -3650,6 +3652,7 @@ vpp_qsv_filter_select="qsvvpp"
 xfade_opencl_filter_deps="opencl"
 yadif_cuda_filter_deps="ffnvcodec"
 yadif_cuda_filter_deps_any="cuda_nvcc cuda_llvm"
+http_filter_deps="libcurl"
 
 # examples
 avio_list_dir_deps="avformat avutil"
@@ -6367,6 +6370,7 @@ enabled libmysofa && { check_pkg_config libmysofa libmysofa mysofa.h mys
 enabled libnpp&& { check_lib libnpp npp.h nppGetLibVersion -lnppig -lnppicc -lnppc -lnppidei ||
check_lib libnpp npp.h nppGetLibVersion -lnppi -lnppc -lnppidei ||
die "ERROR: libnpp not found"; }
+enabled libcurl   && require "libcurl >= 7.68.0" curl/curl.h curl_easy_init -lcurl
 enabled libopencore_amrnb && require libopencore_amrnb opencore-amrnb/interf_dec.h Decoder_Interface_init -lopencore-amrnb
 enabled libopencore_amrwb && require libopencore_amrwb opencore-amrwb/dec_if.h D_IF_init -lopencore-amrwb
 enabled libopencv && { check_headers opencv2/core/core_c.h &&
diff --git a/doc/filters.texi b/doc/filters.texi
index cbb16f22b2..660ef8b4d9 100644
--- a/doc/filters.texi
+++ b/doc/filters.texi
@@ -12078,6 +12078,34 @@ For example, to horizontally flip the input video with @command{ffmpeg}:
 ffmpeg -i in.avi -vf "hflip" out.avi
 @end example
 
+@anchor{http}
+@section http
+
+Send raw frame data to the remote server for postprocessing and await response as new frame in same format and size. To enable filter configure ffmpeg with @code{./configure --enable-libcurl}.
+
+The filter accepts the following options:
+
+@table @option
+@item url
+Specify remote server url location.
+
+@item content_type
+Specify content-type header in request header, default to "application/octet-stream".
+@end table
+
+Simple demo http server for postprocessing frames can be found here: @url{https://github.com/devalexqt/simple_ffmpeg_http_filter_server}
+
+@subsection Examples
+@itemize
+
+@item
+Send raw frames to "http://localhost:3000/frame?param=abc;
+
+@example
+ffmpeg -i input.mp4 -vf format=rgb24,http=url="http\\\://localhost\\\:3000/frame?param=abc":content_type=application/octet-stream -t 10 out.mp4
+@end example
+@end itemize
+
 @section histeq
 This filter applies a global color histogram equalization on a
 per-frame basis.
diff --git a/libavfilter/Makefile b/libavfilter/Makefile
index e6d3c283da..38eb1f4204 100644
--- a/libavfilter/Makefile
+++ b/libavfilter/Makefile
@@ -467,6 +467,7 @@ OBJS-$(CONFIG_YAEPBLUR_FILTER)   += vf_yaepblur.o
 OBJS-$(CONFIG_ZMQ_FILTER)+= f_zmq.o
 OBJS-$(CONFIG_ZOOMPAN_FILTER)+= vf_zoompan.o
 OBJS-$(CONFIG_ZSCALE_FILTER) += vf_zscale.o
+OBJS-$(CONFIG_HTTP_FILTER)   += vf_http.o
 
 OBJS-$(CONFIG_ALLRGB_FILTER) += vsrc_testsrc.o
 OBJS-$(CONFIG_ALLYUV_FILTER) += vsrc_testsrc.o
diff --git a/libavfilter/allfilters.c b/libavfilter/allfilters.c
index fa91e608e4..8626fbc331 100644
--- a/libavfilter/allfilters.c
+++ b/libavfilter/allfilters.c
@@ -445,6 +445,7 @@ extern AVFilter ff_vf_yaepblur;
 extern AVFilter ff_vf_zmq;
 extern AVFilter ff_vf_zoompan;
 extern AVFilter ff_vf_zscale;
+extern AVFilter ff_vf_http;
 
 extern AVFilter ff_vsrc_allrgb;
 extern AVFilter ff_vsrc_allyuv;
diff --git a/libavfilter/version.h b/libavfilter/version.h
index 308fbe07c3..b8ba489da7 100644
--- a/libavfilter/version.h
+++ b/libavfilter/version.h
@@ -30,7 +30,7 @@
 #include "libavutil/version.h"
 
 #define LIBAVFILTER_VERSION_MAJOR   7
-#define LIBAVFILTER_VERSION_MINOR  87
+#define LIBAVFILTER_VERSION_MINOR  88
 

[FFmpeg-devel] [PATCH 3/3] avfilter/formats: Remove pointless checks

2020-09-10 Thread Andreas Rheinhardt
ff_formats_ref() takes a pointer to an AVFilterFormats and a pointer to
a pointer to an AVFilterFormats as arguments and adds the latter as an
owner to the list pointed to by the former; the latter is hereby always
the address of a list contained in an AVFilterFormatsConfig and can
therefore not be NULL. So remove the check for whether it is NULL; also
do the same for ff_channel_layouts_ref().

Also do the same for the unref functions where argument is never NULL
because it is always the address of an existing lvalue.

Signed-off-by: Andreas Rheinhardt 
---
 libavfilter/formats.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/libavfilter/formats.c b/libavfilter/formats.c
index 98ff82a887..43c90b9a27 100644
--- a/libavfilter/formats.c
+++ b/libavfilter/formats.c
@@ -269,7 +269,7 @@ do {\
 do {   \
 int idx = -1;  \
\
-if (!ref || !*ref) \
+if (!*ref) \
 return;\
\
 FIND_REF_INDEX(ref, idx);  \
@@ -495,7 +495,7 @@ AVFilterChannelLayouts *ff_all_channel_counts(void)
 #define FORMATS_REF(f, ref, unref_fn)  
 \
 void *tmp; 
 \

 \
-if (!f || !ref)
 \
+if (!f)
 \
 return AVERROR(ENOMEM);
 \

 \
 tmp = av_realloc_array(f->refs, sizeof(*f->refs), f->refcount + 1);
 \
-- 
2.20.1

___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
https://ffmpeg.org/mailman/listinfo/ffmpeg-devel

To unsubscribe, visit link above, or email
ffmpeg-devel-requ...@ffmpeg.org with subject "unsubscribe".

[FFmpeg-devel] [PATCH 2/3] avfilter/af_aformat, formats: Unify freeing AVFilterFormatsConfig

2020-09-10 Thread Andreas Rheinhardt
AVFilterFormats and AVFilterChannelLayouts always exist together, namely
in the aformat filter as well as in AVFilterLinks. Now that they are
grouped together in a single structure in AVFilterLinks, the same can be
done in aformat and then this structure can be freed on its own,
replacing the freeing functions for AVFilterFormats and
AVFilterChannelLayouts structures (which still exist as static functions
in formats.c).

Signed-off-by: Andreas Rheinhardt 
---
Btw: There are several quite common combinations of functions like e.g.
ff_make_format_list() and ff_formats_ref(). Should they be factored out
in new functions or not?

 libavfilter/af_aformat.c|  26 -
 libavfilter/avfilter.c  |   8 +--
 libavfilter/avfiltergraph.c |   8 +--
 libavfilter/formats.c   | 105 +++-
 libavfilter/formats.h   |  13 ++---
 5 files changed, 76 insertions(+), 84 deletions(-)

diff --git a/libavfilter/af_aformat.c b/libavfilter/af_aformat.c
index e669f2de83..a8dbdd8147 100644
--- a/libavfilter/af_aformat.c
+++ b/libavfilter/af_aformat.c
@@ -36,9 +36,7 @@
 typedef struct AFormatContext {
 const AVClass   *class;
 
-AVFilterFormats *formats;
-AVFilterFormats *sample_rates;
-AVFilterChannelLayouts *channel_layouts;
+AVFilterFormatsConfig config;
 
 char *formats_str;
 char *sample_rates_str;
@@ -100,11 +98,11 @@ static av_cold int init(AVFilterContext *ctx)
 {
 AFormatContext *s = ctx->priv;
 
-PARSE_FORMATS(s->formats_str, enum AVSampleFormat, s->formats,
+PARSE_FORMATS(s->formats_str, enum AVSampleFormat, s->config.formats,
   ff_add_format, av_get_sample_fmt, AV_SAMPLE_FMT_NONE, 
"sample format");
-PARSE_FORMATS(s->sample_rates_str, int, s->sample_rates, ff_add_format,
+PARSE_FORMATS(s->sample_rates_str, int, s->config.samplerates, 
ff_add_format,
   get_sample_rate, 0, "sample rate");
-PARSE_FORMATS(s->channel_layouts_str, uint64_t, s->channel_layouts,
+PARSE_FORMATS(s->channel_layouts_str, uint64_t, s->config.channel_layouts,
   ff_add_channel_layout, av_get_channel_layout, 0,
   "channel layout");
 
@@ -115,9 +113,7 @@ static av_cold void uninit(AVFilterContext *ctx)
 {
 AFormatContext *s = ctx->priv;
 
-ff_formats_unref(>formats);
-ff_formats_unref(>sample_rates);
-ff_channel_layouts_unref(>channel_layouts);
+ff_filter_formats_config_unref(>config);
 }
 
 static int query_formats(AVFilterContext *ctx)
@@ -125,19 +121,19 @@ static int query_formats(AVFilterContext *ctx)
 AFormatContext *s = ctx->priv;
 int ret;
 
-ret = ff_set_common_formats(ctx, s->formats ? s->formats :
+ret = ff_set_common_formats(ctx, s->config.formats ? s->config.formats :
 
ff_all_formats(AVMEDIA_TYPE_AUDIO));
-s->formats = NULL;
+s->config.formats = NULL;
 if (ret < 0)
 return ret;
-ret = ff_set_common_samplerates(ctx, s->sample_rates ? s->sample_rates :
+ret = ff_set_common_samplerates(ctx, s->config.samplerates ? 
s->config.samplerates :
  ff_all_samplerates());
-s->sample_rates = NULL;
+s->config.samplerates = NULL;
 if (ret < 0)
 return ret;
-ret = ff_set_common_channel_layouts(ctx, s->channel_layouts ? 
s->channel_layouts :
+ret = ff_set_common_channel_layouts(ctx, s->config.channel_layouts ? 
s->config.channel_layouts :
 
ff_all_channel_counts());
-s->channel_layouts = NULL;
+s->config.channel_layouts = NULL;
 return ret;
 }
 
diff --git a/libavfilter/avfilter.c b/libavfilter/avfilter.c
index 8ff22c71e3..06cf564270 100644
--- a/libavfilter/avfilter.c
+++ b/libavfilter/avfilter.c
@@ -746,12 +746,8 @@ static void free_link(AVFilterLink *link)
 
 av_buffer_unref(>hw_frames_ctx);
 
-ff_formats_unref(>incfg.formats);
-ff_formats_unref(>outcfg.formats);
-ff_formats_unref(>incfg.samplerates);
-ff_formats_unref(>outcfg.samplerates);
-ff_channel_layouts_unref(>incfg.channel_layouts);
-ff_channel_layouts_unref(>outcfg.channel_layouts);
+ff_filter_formats_config_unref(>incfg);
+ff_filter_formats_config_unref(>outcfg);
 avfilter_link_free();
 }
 
diff --git a/libavfilter/avfiltergraph.c b/libavfilter/avfiltergraph.c
index f6b572b3de..831fc2b985 100644
--- a/libavfilter/avfiltergraph.c
+++ b/libavfilter/avfiltergraph.c
@@ -727,12 +727,8 @@ static int pick_format(AVFilterLink *link, AVFilterLink 
*ref)
 link->channels = 
av_get_channel_layout_nb_channels(link->channel_layout);
 }
 
-ff_formats_unref(>incfg.formats);
-ff_formats_unref(>outcfg.formats);
-ff_formats_unref(>incfg.samplerates);
-ff_formats_unref(>outcfg.samplerates);
-ff_channel_layouts_unref(>incfg.channel_layouts);
-ff_channel_layouts_unref(>outcfg.channel_layouts);
+

[FFmpeg-devel] [PATCH 1/3] avfilter/formats: Don't typedef structure a second time

2020-09-10 Thread Andreas Rheinhardt
Before commit 2f76476549a01ae2c4ec2a440e4b14c5aba64869, avfilter.h
contained no typedef for AVFilterChannelLayouts; all references to it
were done using its struct tag. formats.h meanwhile contained the
definition of the struct and a typedef for it. Said commit now added a
typedef in avfilter.h, too, bringing it in line with AVFilterFormats;
yet this means that there are two typedefs for AVFilterChannelLayouts
(in contrast to AVFilterFormats which is only typedef'ed in avfilter.h).

The problem is that older versions of GCC don't like this and error out:
http://fate.ffmpeg.org/history.cgi?slot=x86_64-openbsd5.6-gcc4.2-conf2
is one of the FATE boxes that now fail to compile. So just remove the
typedef in formats.h.

Signed-off-by: Andreas Rheinhardt 
---
 libavfilter/formats.h | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/libavfilter/formats.h b/libavfilter/formats.h
index 8378be4b9b..0520bf42a9 100644
--- a/libavfilter/formats.h
+++ b/libavfilter/formats.h
@@ -83,7 +83,7 @@ struct AVFilterFormats {
  *   channel count with unknown disposition with the same number of channels
  *   (e.g. AV_CH_LAYOUT_STEREO and FF_COUNT2LAYOUT(2).
  */
-typedef struct AVFilterChannelLayouts {
+struct AVFilterChannelLayouts {
 uint64_t *channel_layouts;  ///< list of channel layouts
 intnb_channel_layouts;  ///< number of channel layouts
 char all_layouts;   ///< accept any known channel layout
@@ -91,7 +91,7 @@ typedef struct AVFilterChannelLayouts {
 
 unsigned refcount;  ///< number of references to this list
 struct AVFilterChannelLayouts ***refs; ///< references to this list
-} AVFilterChannelLayouts;
+};
 
 /**
  * Encode a channel count as a channel layout.
-- 
2.20.1

___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
https://ffmpeg.org/mailman/listinfo/ffmpeg-devel

To unsubscribe, visit link above, or email
ffmpeg-devel-requ...@ffmpeg.org with subject "unsubscribe".

[FFmpeg-devel] [PATCH] avcodec/mobiclip: Check quantizer before table setup

2020-09-10 Thread Michael Niedermayer
Fixes: index -1 out of bounds for type 'const uint8_t [6][16]'
Fixes: out of array read
Fixes: shift exponent -21 is negative
Fixes: 
25422/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_MOBICLIP_fuzzer-5748258226569216
Fixes: shift exponent 8039082 is too large for 32-bit type 'int'
Fixes: 
25430/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_MOBICLIP_fuzzer-5698567770210304

Found-by: continuous fuzzing process 
https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg
Signed-off-by: Michael Niedermayer 
---
 libavcodec/mobiclip.c | 6 +-
 1 file changed, 5 insertions(+), 1 deletion(-)

diff --git a/libavcodec/mobiclip.c b/libavcodec/mobiclip.c
index d147eddbae..13f0edc89d 100644
--- a/libavcodec/mobiclip.c
+++ b/libavcodec/mobiclip.c
@@ -1323,6 +1323,10 @@ static int mobiclip_decode(AVCodecContext *avctx, void 
*data,
 }
 } else {
 MotionXY *motion = s->motion;
+int quantizer = s->quantizer + get_se_golomb(gb);
+
+if (quantizer < 12 || quantizer > 161)
+return AVERROR_INVALIDDATA;
 
 memset(motion, 0, s->motion_size);
 
@@ -1330,7 +1334,7 @@ static int mobiclip_decode(AVCodecContext *avctx, void 
*data,
 frame->key_frame = 0;
 s->dct_tab_idx = 0;
 
-setup_qtables(avctx, s->quantizer + get_se_golomb(gb));
+setup_qtables(avctx, quantizer);
 for (int y = 0; y < avctx->height; y += 16) {
 for (int x = 0; x < avctx->width; x += 16) {
 int idx;
-- 
2.17.1

___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
https://ffmpeg.org/mailman/listinfo/ffmpeg-devel

To unsubscribe, visit link above, or email
ffmpeg-devel-requ...@ffmpeg.org with subject "unsubscribe".

Re: [FFmpeg-devel] [FFmpeg-cvslog] fate: disable automatic conversions on many tests.

2020-09-10 Thread James Almer
On 9/10/2020 3:47 PM, Michael Niedermayer wrote:
> On Thu, Sep 10, 2020 at 07:35:12PM +0200, Nicolas George wrote:
>> Michael Niedermayer (12020-09-10):
>>> this breaks several tests on big endian as that needs converts at diffferent
>>> places.
>>>
>>> heres a list of failures
>>
>> Thanks for pointing it. I do not see these archs on fate.ffmpeg.org. Is
>> there a way to get the error output?
> 
> the mips qemu fate box run out of diskspace, ive cleared it up so it
> might reappear in the next day or 2, if not then it needs checking what else
> is stuck
> 
> Iam not sure why a out of diskspace resulted in the entry to disappear 
> entirely
> off fate.ffmpeg.org. But that is something that probably should be looked 
> into and fixed too as it makes it very easy to miss that a box is broken

Entries disappear after an specific amount of days without sending a new
report, so the only thing i can think could have happened is that the
runs on those boxes errored out at a point before they could even
attempt to send a report back to fate, or failed while trying to do it.

> 
> thx
> 
> [...]
> 
> 
> ___
> ffmpeg-devel mailing list
> ffmpeg-devel@ffmpeg.org
> https://ffmpeg.org/mailman/listinfo/ffmpeg-devel
> 
> To unsubscribe, visit link above, or email
> ffmpeg-devel-requ...@ffmpeg.org with subject "unsubscribe".
> 

___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
https://ffmpeg.org/mailman/listinfo/ffmpeg-devel

To unsubscribe, visit link above, or email
ffmpeg-devel-requ...@ffmpeg.org with subject "unsubscribe".

[FFmpeg-devel] [PATCH 5/9] avfilter/vf_subtitles: Fix leaks on failure

2020-09-10 Thread Andreas Rheinhardt
init_subtitles() sometimes returned directly upon error without cleaning
up after itself. The easiest way to trigger this is by using
picture-based subtitles; it is also possible to run into this in case of
missing decoders or allocation failures.

Furthermore, return the proper error code in case of missing decoder.

Signed-off-by: Andreas Rheinhardt 
---
 libavfilter/vf_subtitles.c | 12 
 1 file changed, 8 insertions(+), 4 deletions(-)

diff --git a/libavfilter/vf_subtitles.c b/libavfilter/vf_subtitles.c
index 1bd42391e0..2d3145bf2d 100644
--- a/libavfilter/vf_subtitles.c
+++ b/libavfilter/vf_subtitles.c
@@ -384,13 +384,15 @@ static av_cold int init_subtitles(AVFilterContext *ctx)
 if (!dec) {
 av_log(ctx, AV_LOG_ERROR, "Failed to find subtitle codec %s\n",
avcodec_get_name(st->codecpar->codec_id));
-return AVERROR(EINVAL);
+ret = AVERROR_DECODER_NOT_FOUND;
+goto end;
 }
 dec_desc = avcodec_descriptor_get(st->codecpar->codec_id);
 if (dec_desc && !(dec_desc->props & AV_CODEC_PROP_TEXT_SUB)) {
 av_log(ctx, AV_LOG_ERROR,
"Only text based subtitles are currently supported\n");
-return AVERROR_PATCHWELCOME;
+ret = AVERROR_PATCHWELCOME;
+goto end;
 }
 if (ass->charenc)
 av_dict_set(_opts, "sub_charenc", ass->charenc, 0);
@@ -398,8 +400,10 @@ static av_cold int init_subtitles(AVFilterContext *ctx)
 av_dict_set(_opts, "sub_text_format", "ass", 0);
 
 dec_ctx = avcodec_alloc_context3(dec);
-if (!dec_ctx)
-return AVERROR(ENOMEM);
+if (!dec_ctx) {
+ret = AVERROR(ENOMEM);
+goto end;
+}
 
 ret = avcodec_parameters_to_context(dec_ctx, st->codecpar);
 if (ret < 0)
-- 
2.20.1

___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
https://ffmpeg.org/mailman/listinfo/ffmpeg-devel

To unsubscribe, visit link above, or email
ffmpeg-devel-requ...@ffmpeg.org with subject "unsubscribe".

[FFmpeg-devel] [PATCH 8/9] avfilter/vf_subtitles: Return early upon avformat_open_input() failure

2020-09-10 Thread Andreas Rheinhardt
There is nothing to free at this point.

Signed-off-by: Andreas Rheinhardt 
---
 libavfilter/vf_subtitles.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/libavfilter/vf_subtitles.c b/libavfilter/vf_subtitles.c
index 08b4d4efca..f9733c3935 100644
--- a/libavfilter/vf_subtitles.c
+++ b/libavfilter/vf_subtitles.c
@@ -322,7 +322,7 @@ static av_cold int init_subtitles(AVFilterContext *ctx)
 ret = avformat_open_input(, ass->filename, NULL, NULL);
 if (ret < 0) {
 av_log(ctx, AV_LOG_ERROR, "Unable to open %s\n", ass->filename);
-goto end;
+return ret;
 }
 ret = avformat_find_stream_info(fmt, NULL);
 if (ret < 0)
-- 
2.20.1

___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
https://ffmpeg.org/mailman/listinfo/ffmpeg-devel

To unsubscribe, visit link above, or email
ffmpeg-devel-requ...@ffmpeg.org with subject "unsubscribe".

[FFmpeg-devel] [PATCH 6/9] avfilter/vf_subtitles: Remove unnecessary initialization of AVPacket

2020-09-10 Thread Andreas Rheinhardt
av_read_frame() can handle uninitialized packets.

Signed-off-by: Andreas Rheinhardt 
---
 libavfilter/vf_subtitles.c | 3 ---
 1 file changed, 3 deletions(-)

diff --git a/libavfilter/vf_subtitles.c b/libavfilter/vf_subtitles.c
index 2d3145bf2d..a045375b2d 100644
--- a/libavfilter/vf_subtitles.c
+++ b/libavfilter/vf_subtitles.c
@@ -449,9 +449,6 @@ static av_cold int init_subtitles(AVFilterContext *ctx)
 ass_process_codec_private(ass->track,
   dec_ctx->subtitle_header,
   dec_ctx->subtitle_header_size);
-av_init_packet();
-pkt.data = NULL;
-pkt.size = 0;
 while (av_read_frame(fmt, ) >= 0) {
 int i, got_subtitle;
 AVSubtitle sub = {0};
-- 
2.20.1

___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
https://ffmpeg.org/mailman/listinfo/ffmpeg-devel

To unsubscribe, visit link above, or email
ffmpeg-devel-requ...@ffmpeg.org with subject "unsubscribe".

[FFmpeg-devel] [PATCH 7/9] avfilter/vf_subtitles: Remove obsolete LIBAVCODEC_VERSION_INT checks

2020-09-10 Thread Andreas Rheinhardt
libavcodec major version is already 58.

Signed-off-by: Andreas Rheinhardt 
---
 libavfilter/vf_subtitles.c | 10 +++---
 1 file changed, 3 insertions(+), 7 deletions(-)

diff --git a/libavfilter/vf_subtitles.c b/libavfilter/vf_subtitles.c
index a045375b2d..08b4d4efca 100644
--- a/libavfilter/vf_subtitles.c
+++ b/libavfilter/vf_subtitles.c
@@ -396,8 +396,7 @@ static av_cold int init_subtitles(AVFilterContext *ctx)
 }
 if (ass->charenc)
 av_dict_set(_opts, "sub_charenc", ass->charenc, 0);
-if (LIBAVCODEC_VERSION_INT >= AV_VERSION_INT(57,26,100))
-av_dict_set(_opts, "sub_text_format", "ass", 0);
+av_dict_set(_opts, "sub_text_format", "ass", 0);
 
 dec_ctx = avcodec_alloc_context3(dec);
 if (!dec_ctx) {
@@ -465,11 +464,8 @@ static av_cold int init_subtitles(AVFilterContext *ctx)
 char *ass_line = sub.rects[i]->ass;
 if (!ass_line)
 break;
-if (LIBAVCODEC_VERSION_INT < AV_VERSION_INT(57,25,100))
-ass_process_data(ass->track, ass_line, 
strlen(ass_line));
-else
-ass_process_chunk(ass->track, ass_line, 
strlen(ass_line),
-  start_time, duration);
+ass_process_chunk(ass->track, ass_line, strlen(ass_line),
+  start_time, duration);
 }
 }
 }
-- 
2.20.1

___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
https://ffmpeg.org/mailman/listinfo/ffmpeg-devel

To unsubscribe, visit link above, or email
ffmpeg-devel-requ...@ffmpeg.org with subject "unsubscribe".

[FFmpeg-devel] [PATCH 4/9] avfilter/vf_uspp: Fix potential leak of dict on error

2020-09-10 Thread Andreas Rheinhardt
Signed-off-by: Andreas Rheinhardt 
---
 libavfilter/vf_uspp.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/libavfilter/vf_uspp.c b/libavfilter/vf_uspp.c
index f6fb193433..72a0f562af 100644
--- a/libavfilter/vf_uspp.c
+++ b/libavfilter/vf_uspp.c
@@ -362,9 +362,9 @@ static int config_input(AVFilterLink *inlink)
 avctx_enc->global_quality = 123;
 av_dict_set(, "no_bitstream", "1", 0);
 ret = avcodec_open2(avctx_enc, enc, );
+av_dict_free();
 if (ret < 0)
 return ret;
-av_dict_free();
 av_assert0(avctx_enc->codec);
 }
 
-- 
2.20.1

___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
https://ffmpeg.org/mailman/listinfo/ffmpeg-devel

To unsubscribe, visit link above, or email
ffmpeg-devel-requ...@ffmpeg.org with subject "unsubscribe".

[FFmpeg-devel] [PATCH 9/9] fftools, libavcodec, libavfilter: Add const to some AVCodec *

2020-09-10 Thread Andreas Rheinhardt
The user has no business modifying the underlying AVCodec.

Signed-off-by: Andreas Rheinhardt 
---
 fftools/ffmpeg.h   | 5 +++--
 fftools/ffmpeg_filter.c| 5 +++--
 libavcodec/avrndec.c   | 2 +-
 libavcodec/utils.c | 4 ++--
 libavfilter/lavfutils.c| 2 +-
 libavfilter/src_movie.c| 2 +-
 libavfilter/vf_mcdeint.c   | 2 +-
 libavfilter/vf_subtitles.c | 2 +-
 libavfilter/vf_uspp.c  | 2 +-
 9 files changed, 14 insertions(+), 12 deletions(-)

diff --git a/fftools/ffmpeg.h b/fftools/ffmpeg.h
index 908bc73fca..8665218dcf 100644
--- a/fftools/ffmpeg.h
+++ b/fftools/ffmpeg.h
@@ -638,8 +638,9 @@ void assert_avoptions(AVDictionary *m);
 
 int guess_input_channel_layout(InputStream *ist);
 
-enum AVPixelFormat choose_pixel_fmt(AVStream *st, AVCodecContext *avctx, 
AVCodec *codec, enum AVPixelFormat target);
-void choose_sample_fmt(AVStream *st, AVCodec *codec);
+enum AVPixelFormat choose_pixel_fmt(AVStream *st, AVCodecContext *avctx,
+const AVCodec *codec, enum AVPixelFormat 
target);
+void choose_sample_fmt(AVStream *st, const AVCodec *codec);
 
 int configure_filtergraph(FilterGraph *fg);
 int configure_output_filter(FilterGraph *fg, OutputFilter *ofilter, 
AVFilterInOut *out);
diff --git a/fftools/ffmpeg_filter.c b/fftools/ffmpeg_filter.c
index 3c507f8c1d..e9e31e043e 100644
--- a/fftools/ffmpeg_filter.c
+++ b/fftools/ffmpeg_filter.c
@@ -60,7 +60,8 @@ static const enum AVPixelFormat 
*get_compliance_unofficial_pix_fmts(enum AVCodec
 }
 }
 
-enum AVPixelFormat choose_pixel_fmt(AVStream *st, AVCodecContext *enc_ctx, 
AVCodec *codec, enum AVPixelFormat target)
+enum AVPixelFormat choose_pixel_fmt(AVStream *st, AVCodecContext *enc_ctx,
+const AVCodec *codec, enum AVPixelFormat 
target)
 {
 if (codec && codec->pix_fmts) {
 const enum AVPixelFormat *p = codec->pix_fmts;
@@ -90,7 +91,7 @@ enum AVPixelFormat choose_pixel_fmt(AVStream *st, 
AVCodecContext *enc_ctx, AVCod
 return target;
 }
 
-void choose_sample_fmt(AVStream *st, AVCodec *codec)
+void choose_sample_fmt(AVStream *st, const AVCodec *codec)
 {
 if (codec && codec->sample_fmts) {
 const enum AVSampleFormat *p = codec->sample_fmts;
diff --git a/libavcodec/avrndec.c b/libavcodec/avrndec.c
index a7bdab280d..f4ec490de5 100644
--- a/libavcodec/avrndec.c
+++ b/libavcodec/avrndec.c
@@ -46,7 +46,7 @@ static av_cold int init(AVCodecContext *avctx)
 }
 
 if(a->is_mjpeg) {
-AVCodec *codec = avcodec_find_decoder(AV_CODEC_ID_MJPEG);
+const AVCodec *codec = avcodec_find_decoder(AV_CODEC_ID_MJPEG);
 AVDictionary *thread_opt = NULL;
 if (!codec) {
 av_log(avctx, AV_LOG_ERROR, "MJPEG codec not found\n");
diff --git a/libavcodec/utils.c b/libavcodec/utils.c
index 2e5185f364..d93a0953fa 100644
--- a/libavcodec/utils.c
+++ b/libavcodec/utils.c
@@ -695,7 +695,7 @@ int attribute_align_arg avcodec_open2(AVCodecContext 
*avctx, const AVCodec *code
 if ((avctx->codec->capabilities & AV_CODEC_CAP_EXPERIMENTAL) &&
 avctx->strict_std_compliance > FF_COMPLIANCE_EXPERIMENTAL) {
 const char *codec_string = av_codec_is_encoder(codec) ? "encoder" : 
"decoder";
-AVCodec *codec2;
+const AVCodec *codec2;
 av_log(avctx, AV_LOG_ERROR,
"The %s '%s' is experimental but experimental codecs are not 
enabled, "
"add '-strict %d' if you want to use it.\n",
@@ -1193,7 +1193,7 @@ FF_ENABLE_DEPRECATION_WARNINGS
 const char *avcodec_get_name(enum AVCodecID id)
 {
 const AVCodecDescriptor *cd;
-AVCodec *codec;
+const AVCodec *codec;
 
 if (id == AV_CODEC_ID_NONE)
 return "none";
diff --git a/libavfilter/lavfutils.c b/libavfilter/lavfutils.c
index 57af5ebfdc..a2085ed5ef 100644
--- a/libavfilter/lavfutils.c
+++ b/libavfilter/lavfutils.c
@@ -27,7 +27,7 @@ int ff_load_image(uint8_t *data[4], int linesize[4],
 {
 AVInputFormat *iformat = NULL;
 AVFormatContext *format_ctx = NULL;
-AVCodec *codec;
+const AVCodec *codec;
 AVCodecContext *codec_ctx = NULL;
 AVCodecParameters *par;
 AVFrame *frame = NULL;
diff --git a/libavfilter/src_movie.c b/libavfilter/src_movie.c
index d83cb6d1e4..ab12c34f4a 100644
--- a/libavfilter/src_movie.c
+++ b/libavfilter/src_movie.c
@@ -155,7 +155,7 @@ static AVStream *find_stream(void *log, AVFormatContext 
*avf, const char *spec)
 
 static int open_stream(AVFilterContext *ctx, MovieStream *st)
 {
-AVCodec *codec;
+const AVCodec *codec;
 int ret;
 
 codec = avcodec_find_decoder(st->st->codecpar->codec_id);
diff --git a/libavfilter/vf_mcdeint.c b/libavfilter/vf_mcdeint.c
index 9cdec6308d..bc7b3230d3 100644
--- a/libavfilter/vf_mcdeint.c
+++ b/libavfilter/vf_mcdeint.c
@@ -102,7 +102,7 @@ static int config_props(AVFilterLink *inlink)
 {
 AVFilterContext *ctx = inlink->dst;
 MCDeintContext *mcdeint = ctx->priv;
-AVCodec *enc;
+const AVCodec *enc;
 

[FFmpeg-devel] [PATCH 3/9] avfilter/lavfutils: Avoid initializing packet

2020-09-10 Thread Andreas Rheinhardt
av_read_frame() can handle uninitialized packets.

Signed-off-by: Andreas Rheinhardt 
---
 libavfilter/lavfutils.c | 4 +---
 1 file changed, 1 insertion(+), 3 deletions(-)

diff --git a/libavfilter/lavfutils.c b/libavfilter/lavfutils.c
index d7de89f4b3..57af5ebfdc 100644
--- a/libavfilter/lavfutils.c
+++ b/libavfilter/lavfutils.c
@@ -35,8 +35,6 @@ int ff_load_image(uint8_t *data[4], int linesize[4],
 AVPacket pkt;
 AVDictionary *opt=NULL;
 
-av_init_packet();
-
 iformat = av_find_input_format("image2pipe");
 if ((ret = avformat_open_input(_ctx, filename, iformat, NULL)) < 0) 
{
 av_log(log_ctx, AV_LOG_ERROR,
@@ -89,6 +87,7 @@ int ff_load_image(uint8_t *data[4], int linesize[4],
 }
 
 ret = avcodec_decode_video2(codec_ctx, frame, _decoded, );
+av_packet_unref();
 if (ret < 0 || !frame_decoded) {
 av_log(log_ctx, AV_LOG_ERROR, "Failed to decode image from file\n");
 if (ret >= 0)
@@ -107,7 +106,6 @@ int ff_load_image(uint8_t *data[4], int linesize[4],
 av_image_copy(data, linesize, (const uint8_t **)frame->data, 
frame->linesize, *pix_fmt, *w, *h);
 
 end:
-av_packet_unref();
 avcodec_free_context(_ctx);
 avformat_close_input(_ctx);
 av_frame_free();
-- 
2.20.1

___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
https://ffmpeg.org/mailman/listinfo/ffmpeg-devel

To unsubscribe, visit link above, or email
ffmpeg-devel-requ...@ffmpeg.org with subject "unsubscribe".

[FFmpeg-devel] [PATCH 2/9] avfilter/lavfutils: Fix memleak when avformat_find_stream_info() fails

2020-09-10 Thread Andreas Rheinhardt
Signed-off-by: Andreas Rheinhardt 
---
 libavfilter/lavfutils.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/libavfilter/lavfutils.c b/libavfilter/lavfutils.c
index 84dd4c0704..d7de89f4b3 100644
--- a/libavfilter/lavfutils.c
+++ b/libavfilter/lavfutils.c
@@ -46,7 +46,7 @@ int ff_load_image(uint8_t *data[4], int linesize[4],
 
 if ((ret = avformat_find_stream_info(format_ctx, NULL)) < 0) {
 av_log(log_ctx, AV_LOG_ERROR, "Find stream info failed\n");
-return ret;
+goto end;
 }
 
 par = format_ctx->streams[0]->codecpar;
-- 
2.20.1

___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
https://ffmpeg.org/mailman/listinfo/ffmpeg-devel

To unsubscribe, visit link above, or email
ffmpeg-devel-requ...@ffmpeg.org with subject "unsubscribe".

[FFmpeg-devel] [PATCH 1/9] avfilter/lavfutils: Don't use uninitialized pointers for freeing

2020-09-10 Thread Andreas Rheinhardt
Happened on several error conditions, e.g. if there is just no decoder
for the format (like with svg images).

Signed-off-by: Andreas Rheinhardt 
---
 libavfilter/lavfutils.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/libavfilter/lavfutils.c b/libavfilter/lavfutils.c
index db4b69b9f3..84dd4c0704 100644
--- a/libavfilter/lavfutils.c
+++ b/libavfilter/lavfutils.c
@@ -28,9 +28,9 @@ int ff_load_image(uint8_t *data[4], int linesize[4],
 AVInputFormat *iformat = NULL;
 AVFormatContext *format_ctx = NULL;
 AVCodec *codec;
-AVCodecContext *codec_ctx;
+AVCodecContext *codec_ctx = NULL;
 AVCodecParameters *par;
-AVFrame *frame;
+AVFrame *frame = NULL;
 int frame_decoded, ret = 0;
 AVPacket pkt;
 AVDictionary *opt=NULL;
-- 
2.20.1

___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
https://ffmpeg.org/mailman/listinfo/ffmpeg-devel

To unsubscribe, visit link above, or email
ffmpeg-devel-requ...@ffmpeg.org with subject "unsubscribe".

Re: [FFmpeg-devel] [PATCH 2/2] avformat/moflex: make seeking more useful

2020-09-10 Thread Andreas Rheinhardt
Paul B Mahol:
> Signed-off-by: Paul B Mahol 
> ---
>  libavformat/moflex.c | 19 ++-
>  1 file changed, 18 insertions(+), 1 deletion(-)
> 
> diff --git a/libavformat/moflex.c b/libavformat/moflex.c
> index 747e32f079..257408 100644
> --- a/libavformat/moflex.c
> +++ b/libavformat/moflex.c
> @@ -327,7 +327,13 @@ static int moflex_read_packet(AVFormatContext *s, 
> AVPacket *pkt)
>  av_packet_move_ref(pkt, packet);
>  pkt->pos = m->pos;
>  pkt->stream_index = stream_index;
> -pkt->flags |= AV_PKT_FLAG_KEY;
> +if (s->streams[stream_index]->codecpar->codec_type == 
> AVMEDIA_TYPE_VIDEO) {
> +pkt->duration = 1;
> +if (pkt->data[0] & 0x80)
> +pkt->flags |= AV_PKT_FLAG_KEY;
> +} else {
> +pkt->flags |= AV_PKT_FLAG_KEY;
> +}
>  return ret;
>  }
>  }
> @@ -341,6 +347,16 @@ static int moflex_read_packet(AVFormatContext *s, 
> AVPacket *pkt)
>  return AVERROR_EOF;
>  }
>  
> +static int moflex_read_seek(AVFormatContext *s, int stream_index,
> +int64_t pts, int flags)
> +{
> +MOFLEXDemuxContext *m = s->priv_data;
> +
> +m->in_block = 0;
> +
> +return -1;

A seek that always fails? Why?

> +}
> +
>  static int moflex_read_close(AVFormatContext *s)
>  {
>  for (int i = 0; i < s->nb_streams; i++) {
> @@ -360,6 +376,7 @@ AVInputFormat ff_moflex_demuxer = {
>  .read_probe = moflex_probe,
>  .read_header= moflex_read_header,
>  .read_packet= moflex_read_packet,
> +.read_seek  = moflex_read_seek,
>  .read_close = moflex_read_close,
>  .extensions = "moflex",
>  .flags  = AVFMT_GENERIC_INDEX,
> 

___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
https://ffmpeg.org/mailman/listinfo/ffmpeg-devel

To unsubscribe, visit link above, or email
ffmpeg-devel-requ...@ffmpeg.org with subject "unsubscribe".

[FFmpeg-devel] [PATCH 1/2] avcodec/mobiclip: add missing flush

2020-09-10 Thread Paul B Mahol
Signed-off-by: Paul B Mahol 
---
 libavcodec/mobiclip.c | 9 +
 1 file changed, 9 insertions(+)

diff --git a/libavcodec/mobiclip.c b/libavcodec/mobiclip.c
index d147eddbae..c296ce3c78 100644
--- a/libavcodec/mobiclip.c
+++ b/libavcodec/mobiclip.c
@@ -1389,6 +1389,14 @@ static int mobiclip_decode(AVCodecContext *avctx, void 
*data,
 return 0;
 }
 
+static void mobiclip_flush(AVCodecContext *avctx)
+{
+MobiClipContext *s = avctx->priv_data;
+
+for (int i = 0; i < 6; i++)
+av_frame_unref(s->pic[i]);
+}
+
 static av_cold int mobiclip_close(AVCodecContext *avctx)
 {
 MobiClipContext *s = avctx->priv_data;
@@ -1421,6 +1429,7 @@ AVCodec ff_mobiclip_decoder = {
 .priv_data_size = sizeof(MobiClipContext),
 .init   = mobiclip_init,
 .decode = mobiclip_decode,
+.flush  = mobiclip_flush,
 .close  = mobiclip_close,
 .capabilities   = AV_CODEC_CAP_DR1,
 };
-- 
2.17.1

___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
https://ffmpeg.org/mailman/listinfo/ffmpeg-devel

To unsubscribe, visit link above, or email
ffmpeg-devel-requ...@ffmpeg.org with subject "unsubscribe".

[FFmpeg-devel] [PATCH 2/2] avformat/moflex: make seeking more useful

2020-09-10 Thread Paul B Mahol
Signed-off-by: Paul B Mahol 
---
 libavformat/moflex.c | 19 ++-
 1 file changed, 18 insertions(+), 1 deletion(-)

diff --git a/libavformat/moflex.c b/libavformat/moflex.c
index 747e32f079..257408 100644
--- a/libavformat/moflex.c
+++ b/libavformat/moflex.c
@@ -327,7 +327,13 @@ static int moflex_read_packet(AVFormatContext *s, AVPacket 
*pkt)
 av_packet_move_ref(pkt, packet);
 pkt->pos = m->pos;
 pkt->stream_index = stream_index;
-pkt->flags |= AV_PKT_FLAG_KEY;
+if (s->streams[stream_index]->codecpar->codec_type == 
AVMEDIA_TYPE_VIDEO) {
+pkt->duration = 1;
+if (pkt->data[0] & 0x80)
+pkt->flags |= AV_PKT_FLAG_KEY;
+} else {
+pkt->flags |= AV_PKT_FLAG_KEY;
+}
 return ret;
 }
 }
@@ -341,6 +347,16 @@ static int moflex_read_packet(AVFormatContext *s, AVPacket 
*pkt)
 return AVERROR_EOF;
 }
 
+static int moflex_read_seek(AVFormatContext *s, int stream_index,
+int64_t pts, int flags)
+{
+MOFLEXDemuxContext *m = s->priv_data;
+
+m->in_block = 0;
+
+return -1;
+}
+
 static int moflex_read_close(AVFormatContext *s)
 {
 for (int i = 0; i < s->nb_streams; i++) {
@@ -360,6 +376,7 @@ AVInputFormat ff_moflex_demuxer = {
 .read_probe = moflex_probe,
 .read_header= moflex_read_header,
 .read_packet= moflex_read_packet,
+.read_seek  = moflex_read_seek,
 .read_close = moflex_read_close,
 .extensions = "moflex",
 .flags  = AVFMT_GENERIC_INDEX,
-- 
2.17.1

___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
https://ffmpeg.org/mailman/listinfo/ffmpeg-devel

To unsubscribe, visit link above, or email
ffmpeg-devel-requ...@ffmpeg.org with subject "unsubscribe".

Re: [FFmpeg-devel] [PATCH 2/3] avcodec/fastaudio: Remove redundant % 32

2020-09-10 Thread Michael Niedermayer
On Wed, Sep 09, 2020 at 03:01:41AM +0200, Paul B Mahol wrote:
> On Tue, Sep 08, 2020 at 11:29:20PM +0200, Michael Niedermayer wrote:
> > Signed-off-by: Michael Niedermayer 
> > ---
> >  libavcodec/fastaudio.c | 2 +-
> >  1 file changed, 1 insertion(+), 1 deletion(-)
> > 
> 
> ok

will apply

thx

[...]
-- 
Michael GnuPG fingerprint: 9FF2128B147EF6730BADF133611EC787040B0FAB

Whats the most studid thing your enemy could do ? Blow himself up
Whats the most studid thing you could do ? Give up your rights and
freedom because your enemy blew himself up.



signature.asc
Description: PGP signature
___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
https://ffmpeg.org/mailman/listinfo/ffmpeg-devel

To unsubscribe, visit link above, or email
ffmpeg-devel-requ...@ffmpeg.org with subject "unsubscribe".

Re: [FFmpeg-devel] [PATCH] avcodec/agm: Fix off by 1 error in decode_inter_plane()

2020-09-10 Thread Michael Niedermayer
On Thu, Sep 10, 2020 at 09:15:22PM +0200, Paul B Mahol wrote:
> On Thu, Sep 10, 2020 at 07:04:54PM +0200, Michael Niedermayer wrote:
> > Fixes: Regression since 1f2096945709a32315da740691b5716da55893c3
> > Found-by: 
> > Signed-off-by: Michael Niedermayer 
> > ---
> >  libavcodec/agm.c | 4 ++--
> >  1 file changed, 2 insertions(+), 2 deletions(-)
> > 
> 
> lgtm

will apply

thx

[...]
-- 
Michael GnuPG fingerprint: 9FF2128B147EF6730BADF133611EC787040B0FAB

"I am not trying to be anyone's saviour, I'm trying to think about the
 future and not be sad" - Elon Musk



signature.asc
Description: PGP signature
___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
https://ffmpeg.org/mailman/listinfo/ffmpeg-devel

To unsubscribe, visit link above, or email
ffmpeg-devel-requ...@ffmpeg.org with subject "unsubscribe".

Re: [FFmpeg-devel] [PATCH] avcodec/agm: Fix off by 1 error in decode_inter_plane()

2020-09-10 Thread Paul B Mahol
On Thu, Sep 10, 2020 at 07:04:54PM +0200, Michael Niedermayer wrote:
> Fixes: Regression since 1f2096945709a32315da740691b5716da55893c3
> Found-by: 
> Signed-off-by: Michael Niedermayer 
> ---
>  libavcodec/agm.c | 4 ++--
>  1 file changed, 2 insertions(+), 2 deletions(-)
> 

lgtm
___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
https://ffmpeg.org/mailman/listinfo/ffmpeg-devel

To unsubscribe, visit link above, or email
ffmpeg-devel-requ...@ffmpeg.org with subject "unsubscribe".

Re: [FFmpeg-devel] [PATCH 1/2] avcodec/mips: [loongson] Fixed mmi optimization

2020-09-10 Thread Michael Niedermayer
On Thu, Sep 03, 2020 at 02:29:51PM +0800, Shiyou Yin wrote:
> From: gxw 
> 
> Test case fate-checkasm-h264pred failed in latest community code.
> This patch fixed the bug.

will apply

thx

[...]
-- 
Michael GnuPG fingerprint: 9FF2128B147EF6730BADF133611EC787040B0FAB

"I am not trying to be anyone's saviour, I'm trying to think about the
 future and not be sad" - Elon Musk



signature.asc
Description: PGP signature
___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
https://ffmpeg.org/mailman/listinfo/ffmpeg-devel

To unsubscribe, visit link above, or email
ffmpeg-devel-requ...@ffmpeg.org with subject "unsubscribe".

Re: [FFmpeg-devel] [PATCH 2/2] Fix msa can't be disabled when '--cpu=loongson3a' assigned.

2020-09-10 Thread Michael Niedermayer
On Thu, Sep 10, 2020 at 07:05:38PM +0800, Shiyou Yin wrote:
> >-Original Message-
> >From: ffmpeg-devel-boun...@ffmpeg.org 
> >[mailto:ffmpeg-devel-boun...@ffmpeg.org] On Behalf Of
> >Shiyou Yin
> >Sent: Thursday, September 3, 2020 2:30 PM
> >To: ffmpeg-devel@ffmpeg.org
> >Subject: [FFmpeg-devel] [PATCH 2/2] Fix msa can't be disabled when 
> >'--cpu=loongson3a' assigned.
> >
> >There are compiler and runtime check for MSA and MMI.
> >Remove the redundant setting of MSA and MMI for cores specified by "--cpu".
> >
> >Signed-off-by: Shiyou Yin 
> >---
> > configure | 9 -
> > 1 file changed, 9 deletions(-)
> >
> >diff --git a/configure b/configure
> >index 5640720..7f103fa 100755
> >--- a/configure
> >+++ b/configure
> >@@ -5025,8 +5025,6 @@ elif enabled mips; then
> > disable loongson3
> > disable mipsdsp
> > disable mipsdspr2
> >-disable msa
> >-disable mmi
> >
> > cpuflags="-march=$cpu"
> >
> >@@ -5035,17 +5033,13 @@ elif enabled mips; then
> > mips1|mips3)
> > ;;
> > mips32r2)
> >-enable msa
> > enable mips32r2
> > ;;
> > mips32r5)
> >-enable msa
> > enable mips32r2
> > enable mips32r5
> > ;;
> > mips64r2|mips64r5)
> >-enable msa
> >-enable mmi
> > enable mips64r2
> > enable loongson3
> > ;;
> >@@ -5062,7 +5056,6 @@ elif enabled mips; then
> > enable mips32r2
> > ;;
> > p5600)
> >-enable msa
> > enable mips32r2
> > enable mips32r5
> > check_cflags "-mtune=p5600" && check_cflags "-msched-weight 
> > -mload-store-pairs
> >-funroll-loops"
> >@@ -5077,7 +5070,6 @@ elif enabled mips; then
> > ;;
> > # Cores from Loongson
> > loongson2e|loongson2f|loongson3*)
> >-enable mmi
> > enable local_aligned
> > enable simd_align_16
> > enable fast_64bit
> >@@ -5100,7 +5092,6 @@ elif enabled mips; then
> > case $cpu in
> > loongson3*)
> > enable loongson3
> >-enable msa
> > cpuflags="-march=loongson3a -mhard-float 
> > $expensive_optimization_flag"
> > ;;
> > loongson2e)
> >--
> >2.1.0
> >
> 
> Ping.

will apply

thx

[...]
-- 
Michael GnuPG fingerprint: 9FF2128B147EF6730BADF133611EC787040B0FAB

The educated differ from the uneducated as much as the living from the
dead. -- Aristotle 


signature.asc
Description: PGP signature
___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
https://ffmpeg.org/mailman/listinfo/ffmpeg-devel

To unsubscribe, visit link above, or email
ffmpeg-devel-requ...@ffmpeg.org with subject "unsubscribe".

Re: [FFmpeg-devel] [FFmpeg-cvslog] fate: disable automatic conversions on many tests.

2020-09-10 Thread Michael Niedermayer
On Thu, Sep 10, 2020 at 07:35:12PM +0200, Nicolas George wrote:
> Michael Niedermayer (12020-09-10):
> > this breaks several tests on big endian as that needs converts at diffferent
> > places.
> > 
> > heres a list of failures
> 
> Thanks for pointing it. I do not see these archs on fate.ffmpeg.org. Is
> there a way to get the error output?

the mips qemu fate box run out of diskspace, ive cleared it up so it
might reappear in the next day or 2, if not then it needs checking what else
is stuck

Iam not sure why a out of diskspace resulted in the entry to disappear entirely
off fate.ffmpeg.org. But that is something that probably should be looked 
into and fixed too as it makes it very easy to miss that a box is broken

thx

[...]

-- 
Michael GnuPG fingerprint: 9FF2128B147EF6730BADF133611EC787040B0FAB

Never trust a computer, one day, it may think you are the virus. -- Compn


signature.asc
Description: PGP signature
___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
https://ffmpeg.org/mailman/listinfo/ffmpeg-devel

To unsubscribe, visit link above, or email
ffmpeg-devel-requ...@ffmpeg.org with subject "unsubscribe".

Re: [FFmpeg-devel] [FFmpeg-cvslog] fate: disable automatic conversions on many tests.

2020-09-10 Thread Nicolas George
Michael Niedermayer (12020-09-10):
> this breaks several tests on big endian as that needs converts at diffferent
> places.
> 
> heres a list of failures

Thanks for pointing it. I do not see these archs on fate.ffmpeg.org. Is
there a way to get the error output?

Anyway, I will try to find a big-endian arch and check.

Regards,

-- 
  Nicolas George


signature.asc
Description: PGP signature
___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
https://ffmpeg.org/mailman/listinfo/ffmpeg-devel

To unsubscribe, visit link above, or email
ffmpeg-devel-requ...@ffmpeg.org with subject "unsubscribe".

[FFmpeg-devel] [PATCH] avcodec/agm: Fix off by 1 error in decode_inter_plane()

2020-09-10 Thread Michael Niedermayer
Fixes: Regression since 1f2096945709a32315da740691b5716da55893c3
Found-by: 
Signed-off-by: Michael Niedermayer 
---
 libavcodec/agm.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/libavcodec/agm.c b/libavcodec/agm.c
index 19490c5456..f60cbf1a18 100644
--- a/libavcodec/agm.c
+++ b/libavcodec/agm.c
@@ -423,8 +423,8 @@ static int decode_inter_plane(AGMContext *s, GetBitContext 
*gb, int size,
 int map = s->map[x];
 
 if (orig_mv_x >= -32) {
-if (y * 8 + mv_y < 0 || y * 8 + mv_y + 8 >= h ||
-x * 8 + mv_x < 0 || x * 8 + mv_x + 8 >= w)
+if (y * 8 + mv_y < 0 || y * 8 + mv_y + 8 > h ||
+x * 8 + mv_x < 0 || x * 8 + mv_x + 8 > w)
 return AVERROR_INVALIDDATA;
 
 copy_block8(frame->data[plane] + (s->blocks_h - 1 - y) * 8 
* frame->linesize[plane] + x * 8,
-- 
2.17.1

___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
https://ffmpeg.org/mailman/listinfo/ffmpeg-devel

To unsubscribe, visit link above, or email
ffmpeg-devel-requ...@ffmpeg.org with subject "unsubscribe".

Re: [FFmpeg-devel] [FFmpeg-cvslog] fate: disable automatic conversions on many tests.

2020-09-10 Thread Michael Niedermayer
On Tue, Sep 08, 2020 at 12:20:25PM +, Nicolas George wrote:
> ffmpeg | branch: master | Nicolas George  | Fri Aug 14 
> 18:58:27 2020 +0200| [f08e024ac7d249064648a43bab06ed545f8827c7] | committer: 
> Nicolas George
> 
> fate: disable automatic conversions on many tests.
> 
> Explicitly insert the scale or aresample filter where it would
> have been inserted by the negotiation.
> Re-enable conversions if it cannot be done easily.
> 
> If a conversion is needed in a test, we want to know about it.
> If the negotiation changes and makes new conversion necessary,
> we want to know about it even more.
> 
> > http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=f08e024ac7d249064648a43bab06ed545f8827c7
> ---

this breaks several tests on big endian as that needs converts at diffferent
places.

heres a list of failures
make: *** [fate-filter-yuvtestsrc-yuv444p12] Error 1
make: *** [fate-filter-framerate-12bit-up] Error 1
make: *** [fate-filter-framerate-12bit-down] Error 1
make: *** [fate-bmp-16bit-mask] Error 1
make: *** [fate-bmp-15bit] Error 1
make: *** [fate-bmp-15bit-mask] Error 1
make: *** [fate-gif-color] Error 1
make: *** [fate-gif-disposal-background] Error 1
make: *** [fate-gif-disposal-restore] Error 1
make: *** [fate-gif-gray] Error 1
make: *** [fate-gif-deal] Error 1
make: *** [fate-h264-conformance-frext-hi422fr13_sony_b] Error 1
make: *** [fate-h264-conformance-frext-hi422fr6_sony_a] Error 1
make: *** [fate-h264-conformance-frext-pph10i1_panasonic_a] Error 1
make: *** [fate-h264-conformance-frext-pph10i3_panasonic_a] Error 1
make: *** [fate-h264-conformance-frext-pph422i1_panasonic_a] Error 1
make: *** [fate-h264-conformance-frext-pph10i2_panasonic_a] Error 1
make: *** [fate-h264-conformance-frext-pph422i3_panasonic_a] Error 1
make: *** [fate-h264-conformance-frext-pph10i4_panasonic_a] Error 1
make: *** [fate-h264-conformance-frext-pph10i6_panasonic_a] Error 1
make: *** [fate-h264-conformance-frext-pph422i2_panasonic_a] Error 1
make: *** [fate-h264-conformance-frext-pph422i4_panasonic_a] Error 1
make: *** [fate-h264-conformance-frext-pph10i5_panasonic_a] Error 1
make: *** [fate-h264-conformance-frext-pph10i7_panasonic_a] Error 1
make: *** [fate-h264-conformance-frext-pph422i6_panasonic_a] Error 1
make: *** [fate-h264-conformance-frext-pph422i5_panasonic_a] Error 1
make: *** [fate-h264-conformance-frext-pph422i7_panasonic_a] Error 1
make: *** [fate-h264-invalid-ref-mod] Error 1
make: *** [fate-hevc-conformance-DBLK_A_MAIN10_VIXS_3] Error 1
make: *** [fate-hevc-conformance-WP_A_MAIN10_Toshiba_3] Error 1
make: *** [fate-hevc-conformance-WP_MAIN10_B_Toshiba_3] Error 1
make: *** [fate-hevc-conformance-WPP_A_ericsson_MAIN10_2] Error 1
make: *** [fate-hevc-conformance-WPP_D_ericsson_MAIN10_2] Error 1
make: *** [fate-hevc-conformance-WPP_B_ericsson_MAIN10_2] Error 1
make: *** [fate-hevc-conformance-WPP_C_ericsson_MAIN10_2] Error 1
make: *** [fate-hevc-conformance-WPP_E_ericsson_MAIN10_2] Error 1
make: *** [fate-hevc-conformance-WPP_F_ericsson_MAIN10_2] Error 1
make: *** [fate-hevc-conformance-INITQP_B_Sony_1] Error 1
make: *** [fate-hevc-conformance-IPCM_A_RExt_NEC] Error 1
make: *** [fate-hevc-conformance-IPCM_B_RExt_NEC] Error 1
make: *** [fate-hevc-conformance-PERSIST_RPARAM_A_RExt_Sony_1] Error 1
make: *** [fate-hevc-conformance-PERSIST_RPARAM_A_RExt_Sony_3] Error 1
make: *** [fate-hevc-conformance-ADJUST_IPRED_ANGLE_A_RExt_Mitsubishi_1] Error 1
make: *** [fate-hevc-conformance-SAO_A_RExt_MediaTek_1] Error 1
make: *** [fate-hevc-conformance-Main_422_10_A_RExt_Sony_1] Error 1
make: *** [fate-hevc-conformance-Main_422_10_B_RExt_Sony_1] Error 1
make: *** [fate-dnxhr-444] Error 1
make: *** [fate-dnxhr-12bit] Error 1
make: *** [fate-mss2-rgb555] Error 1
make: *** [fate-mss2-rgb555s] Error 1
make: *** [fate-pixlet-rgb] Error 1
make: *** [fate-prores-422_hq] Error 1
make: *** [fate-prores-422] Error 1
make: *** [fate-prores-422_lt] Error 1
make: *** [fate-prores-422_proxy] Error 1
make: *** [fate-prores-alpha] Error 1
make: *** [fate-prores-alpha_skip] Error 1
make: *** [fate-prores-transparency] Error 1
make: *** [fate-prores-transparency_skip] Error 1
make: *** [fate-qtrle-32bit] Error 1
make: *** [fate-vp9p2-20-10bit-yuv420] Error 1
make: *** [fate-vp9p2-20-12bit-yuv420] Error 1
make: *** [fate-vp9p3-20-10bit-yuv422] Error 1
make: *** [fate-vp9p3-20-10bit-yuv444] Error 1
make: *** [fate-vp9p3-20-10bit-yuv440] Error 1
make: *** [fate-vp9p3-20-12bit-yuv422] Error 1
make: *** [fate-vp9p3-20-12bit-yuv440] Error 1
make: *** [fate-vp9p3-20-12bit-yuv444] Error 1
make: *** [fate-ts-demux] Error 1
make: *** [fate-filter-showpalette] Error 1
make: *** [fate-filter-palettegen-1] Error 1
make: *** [fate-filter-palettegen-2] Error 1
make: *** [fate-fitsdec-ext_data_min_max] Error 1
make: *** [fate-fitsdec-bitpix-32] Error 1
make: *** [fate-fitsdec-bitpix-64] Error 1
make: *** [fate-fitsdec-blank_bitpix32] Error 1
make: *** [fate-hls-fmp4_ac3] Error 127
make: *** [fate-jpg-12bpp] Error 1
make: *** 

Re: [FFmpeg-devel] [PATCH 2/2] avcodec/videotoolboxenc: fix use after destroy

2020-09-10 Thread Zhao Zhili

> 在 2020年9月10日,下午10:21,Richard Kern  写道:
> 
> 
> 
>> On Sep 10, 2020, at 8:57 AM, zhilizhao  wrote:
>> 
>> 
>> 
 On Aug 28, 2020, at 8:55 AM, Steven Liu  wrote:
>>> 
>>>  于2020年8月27日周四 下午5:39写道:
 
 From: Zhao Zhili 
 
 The lock is used in clear_frame_queue().
 ---
 libavcodec/videotoolboxenc.c | 11 +++
 1 file changed, 7 insertions(+), 4 deletions(-)
 
 diff --git a/libavcodec/videotoolboxenc.c b/libavcodec/videotoolboxenc.c
 index 988782f10d..758db9641f 100644
 --- a/libavcodec/videotoolboxenc.c
 +++ b/libavcodec/videotoolboxenc.c
 @@ -2496,14 +2496,17 @@ static av_cold int vtenc_close(AVCodecContext 
 *avctx)
 {
   VTEncContext *vtctx = avctx->priv_data;
 
 -pthread_cond_destroy(>cv_sample_sent);
 -pthread_mutex_destroy(>lock);
 -
 -if(!vtctx->session) return 0;
 +if(!vtctx->session) {
 +pthread_cond_destroy(>cv_sample_sent);
 +pthread_mutex_destroy(>lock);
 +return 0;
 +}
 
   VTCompressionSessionCompleteFrames(vtctx->session,
  kCMTimeIndefinite);
   clear_frame_queue(vtctx);
 +pthread_cond_destroy(>cv_sample_sent);
 +pthread_mutex_destroy(>lock);
   CFRelease(vtctx->session);
   vtctx->session = NULL;
 
 --
 2.28.0
 
 ___
 ffmpeg-devel mailing list
 ffmpeg-devel@ffmpeg.org
 https://ffmpeg.org/mailman/listinfo/ffmpeg-devel
 
 To unsubscribe, visit link above, or email
 ffmpeg-devel-requ...@ffmpeg.org with subject "unsubscribe".
>>> 
>>> 
>>> This patch look better than
>>> https://patchwork.ffmpeg.org/project/ffmpeg/patch/20200827025327.28334-1...@chinaffmpeg.org/
>>> 
>> 
>> Ping for the patch set.
> Can you provide steps to reproduce the deadlock issue? I can get it pushed 
> this weekend if so. 

I only try to fix a use after destroy issue as the commit message says.
It may solved another issue unintentional. Liu, could you help by giving
more information about the deadlock issue, please.

>> 
>>> 
>>> Thanks
>>> Steven
>>> ___
>>> ffmpeg-devel mailing list
>>> ffmpeg-devel@ffmpeg.org
>>> https://ffmpeg.org/mailman/listinfo/ffmpeg-devel
>>> 
>>> To unsubscribe, visit link above, or email
>>> ffmpeg-devel-requ...@ffmpeg.org with subject "unsubscribe".
>> 
>> ___
>> ffmpeg-devel mailing list
>> ffmpeg-devel@ffmpeg.org
>> https://ffmpeg.org/mailman/listinfo/ffmpeg-devel
>> 
>> To unsubscribe, visit link above, or email
>> ffmpeg-devel-requ...@ffmpeg.org with subject "unsubscribe".
> ___
> ffmpeg-devel mailing list
> ffmpeg-devel@ffmpeg.org
> https://ffmpeg.org/mailman/listinfo/ffmpeg-devel
> 
> To unsubscribe, visit link above, or email
> ffmpeg-devel-requ...@ffmpeg.org with subject "unsubscribe".

___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
https://ffmpeg.org/mailman/listinfo/ffmpeg-devel

To unsubscribe, visit link above, or email
ffmpeg-devel-requ...@ffmpeg.org with subject "unsubscribe".

Re: [FFmpeg-devel] [PATCH 2/2] avcodec/videotoolboxenc: fix use after destroy

2020-09-10 Thread Richard Kern


> On Sep 10, 2020, at 8:57 AM, zhilizhao  wrote:
> 
> 
> 
>> On Aug 28, 2020, at 8:55 AM, Steven Liu  wrote:
>> 
>>  于2020年8月27日周四 下午5:39写道:
>>> 
>>> From: Zhao Zhili 
>>> 
>>> The lock is used in clear_frame_queue().
>>> ---
>>> libavcodec/videotoolboxenc.c | 11 +++
>>> 1 file changed, 7 insertions(+), 4 deletions(-)
>>> 
>>> diff --git a/libavcodec/videotoolboxenc.c b/libavcodec/videotoolboxenc.c
>>> index 988782f10d..758db9641f 100644
>>> --- a/libavcodec/videotoolboxenc.c
>>> +++ b/libavcodec/videotoolboxenc.c
>>> @@ -2496,14 +2496,17 @@ static av_cold int vtenc_close(AVCodecContext 
>>> *avctx)
>>> {
>>>VTEncContext *vtctx = avctx->priv_data;
>>> 
>>> -pthread_cond_destroy(>cv_sample_sent);
>>> -pthread_mutex_destroy(>lock);
>>> -
>>> -if(!vtctx->session) return 0;
>>> +if(!vtctx->session) {
>>> +pthread_cond_destroy(>cv_sample_sent);
>>> +pthread_mutex_destroy(>lock);
>>> +return 0;
>>> +}
>>> 
>>>VTCompressionSessionCompleteFrames(vtctx->session,
>>>   kCMTimeIndefinite);
>>>clear_frame_queue(vtctx);
>>> +pthread_cond_destroy(>cv_sample_sent);
>>> +pthread_mutex_destroy(>lock);
>>>CFRelease(vtctx->session);
>>>vtctx->session = NULL;
>>> 
>>> --
>>> 2.28.0
>>> 
>>> ___
>>> ffmpeg-devel mailing list
>>> ffmpeg-devel@ffmpeg.org
>>> https://ffmpeg.org/mailman/listinfo/ffmpeg-devel
>>> 
>>> To unsubscribe, visit link above, or email
>>> ffmpeg-devel-requ...@ffmpeg.org with subject "unsubscribe".
>> 
>> 
>> This patch look better than
>> https://patchwork.ffmpeg.org/project/ffmpeg/patch/20200827025327.28334-1...@chinaffmpeg.org/
>> 
> 
> Ping for the patch set.
Can you provide steps to reproduce the deadlock issue? I can get it pushed this 
weekend if so. 
> 
>> 
>> Thanks
>> Steven
>> ___
>> ffmpeg-devel mailing list
>> ffmpeg-devel@ffmpeg.org
>> https://ffmpeg.org/mailman/listinfo/ffmpeg-devel
>> 
>> To unsubscribe, visit link above, or email
>> ffmpeg-devel-requ...@ffmpeg.org with subject "unsubscribe".
> 
> ___
> ffmpeg-devel mailing list
> ffmpeg-devel@ffmpeg.org
> https://ffmpeg.org/mailman/listinfo/ffmpeg-devel
> 
> To unsubscribe, visit link above, or email
> ffmpeg-devel-requ...@ffmpeg.org with subject "unsubscribe".
___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
https://ffmpeg.org/mailman/listinfo/ffmpeg-devel

To unsubscribe, visit link above, or email
ffmpeg-devel-requ...@ffmpeg.org with subject "unsubscribe".

Re: [FFmpeg-devel] [PATCH v4 1/1] avformat: add mca demuxer

2020-09-10 Thread Paul B Mahol
On Thu, Sep 03, 2020 at 04:32:37PM -0600, liush...@aosc.io wrote:
> From: Zixing Liu 
> 
> Signed-off-by: liushuyu 
> ---
>  Changelog|   1 +
>  doc/general.texi |   2 +
>  libavformat/Makefile |   1 +
>  libavformat/allformats.c |   1 +
>  libavformat/mca.c| 226 +++
>  libavformat/version.h|   2 +-
>  6 files changed, 232 insertions(+), 1 deletion(-)
>  create mode 100644 libavformat/mca.c
> 

Gonna test and apply soon.
___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
https://ffmpeg.org/mailman/listinfo/ffmpeg-devel

To unsubscribe, visit link above, or email
ffmpeg-devel-requ...@ffmpeg.org with subject "unsubscribe".

[FFmpeg-devel] [PATCH] avcodec/utils: make the src paramater for ff_thread_ref_frame const

2020-09-10 Thread James Almer
Signed-off-by: James Almer 
---
 libavcodec/thread.h | 2 +-
 libavcodec/utils.c  | 2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/libavcodec/thread.h b/libavcodec/thread.h
index 540135fbc9..87bf154da9 100644
--- a/libavcodec/thread.h
+++ b/libavcodec/thread.h
@@ -129,7 +129,7 @@ int ff_thread_get_buffer(AVCodecContext *avctx, ThreadFrame 
*f, int flags);
  */
 void ff_thread_release_buffer(AVCodecContext *avctx, ThreadFrame *f);
 
-int ff_thread_ref_frame(ThreadFrame *dst, ThreadFrame *src);
+int ff_thread_ref_frame(ThreadFrame *dst, const ThreadFrame *src);
 
 int ff_thread_init(AVCodecContext *s);
 int ff_slice_thread_execute_with_mainfunc(AVCodecContext *avctx,
diff --git a/libavcodec/utils.c b/libavcodec/utils.c
index 2e5185f364..f0a41c99b5 100644
--- a/libavcodec/utils.c
+++ b/libavcodec/utils.c
@@ -1852,7 +1852,7 @@ unsigned int avpriv_toupper4(unsigned int x)
 ((unsigned)av_toupper((x >> 24) & 0xFF) << 24);
 }
 
-int ff_thread_ref_frame(ThreadFrame *dst, ThreadFrame *src)
+int ff_thread_ref_frame(ThreadFrame *dst, const ThreadFrame *src)
 {
 int ret;
 
-- 
2.27.0

___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
https://ffmpeg.org/mailman/listinfo/ffmpeg-devel

To unsubscribe, visit link above, or email
ffmpeg-devel-requ...@ffmpeg.org with subject "unsubscribe".

Re: [FFmpeg-devel] [PATCH 2/2] avcodec/videotoolboxenc: fix use after destroy

2020-09-10 Thread zhilizhao


> On Aug 28, 2020, at 8:55 AM, Steven Liu  wrote:
> 
>  于2020年8月27日周四 下午5:39写道:
>> 
>> From: Zhao Zhili 
>> 
>> The lock is used in clear_frame_queue().
>> ---
>> libavcodec/videotoolboxenc.c | 11 +++
>> 1 file changed, 7 insertions(+), 4 deletions(-)
>> 
>> diff --git a/libavcodec/videotoolboxenc.c b/libavcodec/videotoolboxenc.c
>> index 988782f10d..758db9641f 100644
>> --- a/libavcodec/videotoolboxenc.c
>> +++ b/libavcodec/videotoolboxenc.c
>> @@ -2496,14 +2496,17 @@ static av_cold int vtenc_close(AVCodecContext *avctx)
>> {
>> VTEncContext *vtctx = avctx->priv_data;
>> 
>> -pthread_cond_destroy(>cv_sample_sent);
>> -pthread_mutex_destroy(>lock);
>> -
>> -if(!vtctx->session) return 0;
>> +if(!vtctx->session) {
>> +pthread_cond_destroy(>cv_sample_sent);
>> +pthread_mutex_destroy(>lock);
>> +return 0;
>> +}
>> 
>> VTCompressionSessionCompleteFrames(vtctx->session,
>>kCMTimeIndefinite);
>> clear_frame_queue(vtctx);
>> +pthread_cond_destroy(>cv_sample_sent);
>> +pthread_mutex_destroy(>lock);
>> CFRelease(vtctx->session);
>> vtctx->session = NULL;
>> 
>> --
>> 2.28.0
>> 
>> ___
>> ffmpeg-devel mailing list
>> ffmpeg-devel@ffmpeg.org
>> https://ffmpeg.org/mailman/listinfo/ffmpeg-devel
>> 
>> To unsubscribe, visit link above, or email
>> ffmpeg-devel-requ...@ffmpeg.org with subject "unsubscribe".
> 
> 
> This patch look better than
> https://patchwork.ffmpeg.org/project/ffmpeg/patch/20200827025327.28334-1...@chinaffmpeg.org/
> 

Ping for the patch set.

> 
> Thanks
> Steven
> ___
> ffmpeg-devel mailing list
> ffmpeg-devel@ffmpeg.org
> https://ffmpeg.org/mailman/listinfo/ffmpeg-devel
> 
> To unsubscribe, visit link above, or email
> ffmpeg-devel-requ...@ffmpeg.org with subject "unsubscribe".

___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
https://ffmpeg.org/mailman/listinfo/ffmpeg-devel

To unsubscribe, visit link above, or email
ffmpeg-devel-requ...@ffmpeg.org with subject "unsubscribe".

[FFmpeg-devel] [PATCH] dnn/native: add native support for dense

2020-09-10 Thread Mingyu Yin
Signed-off-by: Mingyu Yin 
---
 libavfilter/dnn/Makefile  |   1 +
 libavfilter/dnn/dnn_backend_native.h  |   2 +
 .../dnn/dnn_backend_native_layer_conv2d.h |   1 -
 .../dnn/dnn_backend_native_layer_dense.c  | 151 ++
 .../dnn/dnn_backend_native_layer_dense.h  |  37 +
 libavfilter/dnn/dnn_backend_native_layers.c   |   2 +
 tests/dnn/dnn-layer-dense-test.c  | 131 +++
 tools/python/convert_from_tensorflow.py   | 137 ++--
 8 files changed, 447 insertions(+), 15 deletions(-)
 create mode 100644 libavfilter/dnn/dnn_backend_native_layer_dense.c
 create mode 100644 libavfilter/dnn/dnn_backend_native_layer_dense.h
 create mode 100644 tests/dnn/dnn-layer-dense-test.c

diff --git a/libavfilter/dnn/Makefile b/libavfilter/dnn/Makefile
index e0957073ee..3681801892 100644
--- a/libavfilter/dnn/Makefile
+++ b/libavfilter/dnn/Makefile
@@ -2,6 +2,7 @@ OBJS-$(CONFIG_DNN)   += 
dnn/dnn_interface.o
 OBJS-$(CONFIG_DNN)   += dnn/dnn_backend_native.o
 OBJS-$(CONFIG_DNN)   += dnn/dnn_backend_native_layers.o
 OBJS-$(CONFIG_DNN)   += 
dnn/dnn_backend_native_layer_avgpool.o
+OBJS-$(CONFIG_DNN)   += 
dnn/dnn_backend_native_layer_dense.o
 OBJS-$(CONFIG_DNN)   += 
dnn/dnn_backend_native_layer_pad.o
 OBJS-$(CONFIG_DNN)   += 
dnn/dnn_backend_native_layer_conv2d.o
 OBJS-$(CONFIG_DNN)   += 
dnn/dnn_backend_native_layer_depth2space.o
diff --git a/libavfilter/dnn/dnn_backend_native.h 
b/libavfilter/dnn/dnn_backend_native.h
index b1f8f3d6bf..0c98fd1a0c 100644
--- a/libavfilter/dnn/dnn_backend_native.h
+++ b/libavfilter/dnn/dnn_backend_native.h
@@ -45,11 +45,13 @@ typedef enum {
 DLT_MATH_BINARY = 5,
 DLT_MATH_UNARY = 6,
 DLT_AVG_POOL = 7,
+DLT_DENSE = 8,
 DLT_COUNT
 } DNNLayerType;
 
 typedef enum {DOT_INPUT = 1, DOT_OUTPUT = 2, DOT_INTERMEDIATE = DOT_INPUT | 
DOT_OUTPUT} DNNOperandType;
 typedef enum {VALID, SAME, SAME_CLAMP_TO_EDGE} DNNPaddingParam;
+typedef enum {RELU, TANH, SIGMOID, NONE, LEAKY_RELU} DNNActivationFunc;
 
 typedef struct Layer{
 DNNLayerType type;
diff --git a/libavfilter/dnn/dnn_backend_native_layer_conv2d.h 
b/libavfilter/dnn/dnn_backend_native_layer_conv2d.h
index 72319f2ebe..1295028c46 100644
--- a/libavfilter/dnn/dnn_backend_native_layer_conv2d.h
+++ b/libavfilter/dnn/dnn_backend_native_layer_conv2d.h
@@ -23,7 +23,6 @@
 
 #include "dnn_backend_native.h"
 
-typedef enum {RELU, TANH, SIGMOID, NONE, LEAKY_RELU} DNNActivationFunc;
 
 typedef struct ConvolutionalParams{
 int32_t input_num, output_num, kernel_size;
diff --git a/libavfilter/dnn/dnn_backend_native_layer_dense.c 
b/libavfilter/dnn/dnn_backend_native_layer_dense.c
new file mode 100644
index 00..694a170b65
--- /dev/null
+++ b/libavfilter/dnn/dnn_backend_native_layer_dense.c
@@ -0,0 +1,151 @@
+/*
+ * Copyright (c) 2018 Sergey Lavrushkin
+ *
+ * This file is part of FFmpeg.
+ *
+ * FFmpeg is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU Lesser General Public
+ * License as published by the Free Software Foundation; either
+ * version 2.1 of the License, or (at your option) any later version.
+ *
+ * FFmpeg is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with FFmpeg; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ */
+
+#include "libavutil/avassert.h"
+#include "dnn_backend_native_layer_dense.h"
+
+int dnn_load_layer_dense(Layer *layer, AVIOContext *model_file_context, int 
file_size, int operands_num)
+{
+DenseParams *dense_params;
+int kernel_size;
+int dnn_size = 0;
+dense_params = av_malloc(sizeof(*dense_params));
+if (!dense_params)
+return 0;
+
+dense_params->activation = (int32_t)avio_rl32(model_file_context);
+dense_params->input_num = (int32_t)avio_rl32(model_file_context);
+dense_params->output_num = (int32_t)avio_rl32(model_file_context);
+dense_params->has_bias = (int32_t)avio_rl32(model_file_context);
+dnn_size += 16;
+
+kernel_size = dense_params->input_num * dense_params->output_num;
+dnn_size += kernel_size * 4;
+if (dense_params->has_bias)
+dnn_size += dense_params->output_num * 4;
+
+if (dnn_size > file_size || dense_params->input_num <= 0 ||
+dense_params->output_num <= 0){
+av_freep(_params);
+return 0;
+}
+
+dense_params->kernel = av_malloc(kernel_size * sizeof(float));
+if (!dense_params->kernel) {
+av_freep(_params);
+

[FFmpeg-devel] [PATCH 2/2] avcodec/utils: Require a non zero channels unless AV_CODEC_CAP_CHANNEL_CONF is set

2020-09-10 Thread Michael Niedermayer
This avoids per codec checks for channels not being 0

Fixes: division by 0
Fixes: 
25419/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_FASTAUDIO_fuzzer-5632544761184256
Fixes: 
25433/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_FASTAUDIO_fuzzer-6215671900536832

Found-by: continuous fuzzing process 
https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg
Suggested-by: Paul B Mahol 
See: [FFmpeg-devel] [PATCH 1/3] avcodec/fastaudio: Check channel
Signed-off-by: Michael Niedermayer 
---
 libavcodec/utils.c | 9 +
 1 file changed, 9 insertions(+)

diff --git a/libavcodec/utils.c b/libavcodec/utils.c
index 2e5185f364..f78ec620c1 100644
--- a/libavcodec/utils.c
+++ b/libavcodec/utils.c
@@ -666,6 +666,15 @@ int attribute_align_arg avcodec_open2(AVCodecContext 
*avctx, const AVCodec *code
 ret = AVERROR(EINVAL);
 goto free_and_end;
 }
+if (av_codec_is_decoder(codec) &&
+codec->type == AVMEDIA_TYPE_AUDIO &&
+!(codec->capabilities & AV_CODEC_CAP_CHANNEL_CONF) &&
+avctx->channels == 0) {
+av_log(avctx, AV_LOG_ERROR, "Decoder requires channel count but 
channels not set\n");
+ret = AVERROR(EINVAL);
+goto free_and_end;
+}
+
 if (avctx->sample_rate < 0) {
 av_log(avctx, AV_LOG_ERROR, "Invalid sample rate: %d\n", 
avctx->sample_rate);
 ret = AVERROR(EINVAL);
-- 
2.17.1

___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
https://ffmpeg.org/mailman/listinfo/ffmpeg-devel

To unsubscribe, visit link above, or email
ffmpeg-devel-requ...@ffmpeg.org with subject "unsubscribe".

[FFmpeg-devel] [PATCH 1/2] avcodec: Set AV_CODEC_CAP_CHANNEL_CONF in more decoders

2020-09-10 Thread Michael Niedermayer
Suggested-by: Paul B Mahol 
See: [FFmpeg-devel] [PATCH 1/3] avcodec/fastaudio: Check channels
Signed-off-by: Michael Niedermayer 
---
 libavcodec/ac3dec_fixed.c   |  3 ++-
 libavcodec/ac3dec_float.c   |  6 --
 libavcodec/adxdec.c |  3 ++-
 libavcodec/flacdec.c|  4 +++-
 libavcodec/mpegaudiodec_fixed.c | 15 ++-
 libavcodec/mpegaudiodec_float.c | 15 ++-
 libavcodec/pcm-dvd.c|  3 ++-
 libavcodec/ralf.c   |  3 ++-
 libavcodec/s302m.c  |  3 ++-
 libavcodec/shorten.c|  5 -
 10 files changed, 41 insertions(+), 19 deletions(-)

diff --git a/libavcodec/ac3dec_fixed.c b/libavcodec/ac3dec_fixed.c
index 336a538cad..f36854cdc5 100644
--- a/libavcodec/ac3dec_fixed.c
+++ b/libavcodec/ac3dec_fixed.c
@@ -176,7 +176,8 @@ AVCodec ff_ac3_fixed_decoder = {
 .init   = ac3_decode_init,
 .close  = ac3_decode_end,
 .decode = ac3_decode_frame,
-.capabilities   = AV_CODEC_CAP_DR1,
+.capabilities   = AV_CODEC_CAP_CHANNEL_CONF |
+  AV_CODEC_CAP_DR1,
 .long_name  = NULL_IF_CONFIG_SMALL("ATSC A/52A (AC-3)"),
 .sample_fmts= (const enum AVSampleFormat[]) { AV_SAMPLE_FMT_S16P,
   AV_SAMPLE_FMT_NONE },
diff --git a/libavcodec/ac3dec_float.c b/libavcodec/ac3dec_float.c
index b85a4ce336..57a626a181 100644
--- a/libavcodec/ac3dec_float.c
+++ b/libavcodec/ac3dec_float.c
@@ -61,7 +61,8 @@ AVCodec ff_ac3_decoder = {
 .init   = ac3_decode_init,
 .close  = ac3_decode_end,
 .decode = ac3_decode_frame,
-.capabilities   = AV_CODEC_CAP_DR1,
+.capabilities   = AV_CODEC_CAP_CHANNEL_CONF |
+  AV_CODEC_CAP_DR1,
 .long_name  = NULL_IF_CONFIG_SMALL("ATSC A/52A (AC-3)"),
 .sample_fmts= (const enum AVSampleFormat[]) { AV_SAMPLE_FMT_FLTP,
   AV_SAMPLE_FMT_NONE },
@@ -84,7 +85,8 @@ AVCodec ff_eac3_decoder = {
 .init   = ac3_decode_init,
 .close  = ac3_decode_end,
 .decode = ac3_decode_frame,
-.capabilities   = AV_CODEC_CAP_DR1,
+.capabilities   = AV_CODEC_CAP_CHANNEL_CONF |
+  AV_CODEC_CAP_DR1,
 .long_name  = NULL_IF_CONFIG_SMALL("ATSC A/52B (AC-3, E-AC-3)"),
 .sample_fmts= (const enum AVSampleFormat[]) { AV_SAMPLE_FMT_FLTP,
   AV_SAMPLE_FMT_NONE },
diff --git a/libavcodec/adxdec.c b/libavcodec/adxdec.c
index 40ed8e5ba7..69a391ee1f 100644
--- a/libavcodec/adxdec.c
+++ b/libavcodec/adxdec.c
@@ -183,7 +183,8 @@ AVCodec ff_adpcm_adx_decoder = {
 .init   = adx_decode_init,
 .decode = adx_decode_frame,
 .flush  = adx_decode_flush,
-.capabilities   = AV_CODEC_CAP_DR1,
+.capabilities   = AV_CODEC_CAP_CHANNEL_CONF |
+  AV_CODEC_CAP_DR1,
 .sample_fmts= (const enum AVSampleFormat[]) { AV_SAMPLE_FMT_S16P,
   AV_SAMPLE_FMT_NONE },
 };
diff --git a/libavcodec/flacdec.c b/libavcodec/flacdec.c
index d1cf82b541..cf6128f897 100644
--- a/libavcodec/flacdec.c
+++ b/libavcodec/flacdec.c
@@ -669,7 +669,9 @@ AVCodec ff_flac_decoder = {
 .init   = flac_decode_init,
 .close  = flac_decode_close,
 .decode = flac_decode_frame,
-.capabilities   = AV_CODEC_CAP_DR1 | AV_CODEC_CAP_FRAME_THREADS,
+.capabilities   = AV_CODEC_CAP_CHANNEL_CONF |
+  AV_CODEC_CAP_DR1 |
+  AV_CODEC_CAP_FRAME_THREADS,
 .sample_fmts= (const enum AVSampleFormat[]) { AV_SAMPLE_FMT_S16,
   AV_SAMPLE_FMT_S16P,
   AV_SAMPLE_FMT_S32,
diff --git a/libavcodec/mpegaudiodec_fixed.c b/libavcodec/mpegaudiodec_fixed.c
index ad7ceb20b6..68ba841efe 100644
--- a/libavcodec/mpegaudiodec_fixed.c
+++ b/libavcodec/mpegaudiodec_fixed.c
@@ -47,7 +47,8 @@ AVCodec ff_mp1_decoder = {
 .priv_data_size = sizeof(MPADecodeContext),
 .init   = decode_init,
 .decode = decode_frame,
-.capabilities   = AV_CODEC_CAP_DR1,
+.capabilities   = AV_CODEC_CAP_CHANNEL_CONF |
+  AV_CODEC_CAP_DR1,
 .flush  = flush,
 .sample_fmts= (const enum AVSampleFormat[]) { AV_SAMPLE_FMT_S16P,
   AV_SAMPLE_FMT_S16,
@@ -63,7 +64,8 @@ AVCodec ff_mp2_decoder = {
 .priv_data_size = sizeof(MPADecodeContext),
 .init   = decode_init,
 .decode = decode_frame,
-.capabilities   = AV_CODEC_CAP_DR1,
+.capabilities   = AV_CODEC_CAP_CHANNEL_CONF |
+  AV_CODEC_CAP_DR1,
 .flush  = flush,
 .sample_fmts= (const enum AVSampleFormat[]) { AV_SAMPLE_FMT_S16P,
   

Re: [FFmpeg-devel] [PATCH 1/3] avcodec/fastaudio: Check channels

2020-09-10 Thread Michael Niedermayer
On Wed, Sep 09, 2020 at 03:00:51AM +0200, Paul B Mahol wrote:
> On Tue, Sep 08, 2020 at 11:29:19PM +0200, Michael Niedermayer wrote:
> > Fixes: division by 0
> > Fixes: 
> > 25419/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_FASTAUDIO_fuzzer-5632544761184256
> > Fixes: 
> > 25433/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_FASTAUDIO_fuzzer-6215671900536832
> > 
> > Found-by: continuous fuzzing process 
> > https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg
> > Signed-off-by: Michael Niedermayer 
> > ---
> >  libavcodec/fastaudio.c | 3 +++
> >  1 file changed, 3 insertions(+)
> > 
> 
> This should be in generic path somehow. There are decoders that does not need 
> this check
> as they store number of channels in bitstream, but there are others that do 
> not, and thus adding
> this check for each and every one of them is not nice.

Posted a implementation using a different, generic approuch
but such generic approuch requires all decoders to declare correctly
if they store the channel configuration in some header. I suspect not all
codecs have this correct yet after the patchset.
maybe you can check if your decoders set the flag correctly
fate and a bunch of files i have all pass but i do not have input files
for all decoders ...

Thanks


[...]
-- 
Michael GnuPG fingerprint: 9FF2128B147EF6730BADF133611EC787040B0FAB

The worst form of inequality is to try to make unequal things equal.
-- Aristotle


signature.asc
Description: PGP signature
___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
https://ffmpeg.org/mailman/listinfo/ffmpeg-devel

To unsubscribe, visit link above, or email
ffmpeg-devel-requ...@ffmpeg.org with subject "unsubscribe".

Re: [FFmpeg-devel] [PATCH 2/3] avfilter/src_movie: Remove unnecessary secondary AVPacket

2020-09-10 Thread Andreas Rheinhardt
Nicolas George:
> Andreas Rheinhardt (12020-09-10):
>> The movie and amovie filters currently use two packets. One of the two,
>> pkt0, is the owner of the returned packet; it is also the destination
>> packet for av_read_frame(). The other one pkt is initially (i.e. after
>> av_read_frame()) a copy of pkt0; copy means that the contents of both
>> are absolutely the same: They both point to the same AVBufferRef and the
>> same side data. This violation of the refcounted packet API is only
>> possible because pkt is not considered to own its data. Only pkt0 is
>> ever unreferenced.
>> The reason for pkt's existence seems to be historic:
>> The API used for decoding audio (namely avcodec_decode_audio4()) could
>> consume frames partially, i.e. it could return multiple frames for one
>> packet and therefore it returned how much of the input buffer had been
>> consumed. The caller was then supposed to update the packet's data and
>> size pointer to reflect this and call avcodec_decode_audio4() again with
>> the updated packet to get the next frame.
>> But before the introduction of refcounted AVPackets where knowledge and
>> responsibility about what to free lies with the underlying AVBuffer such
>> a procedure required a spare packet (or one would need to record the
>> original data and size fields separately to restore them before freeing
>> the packet; notice that this code has been written when AVPackets still
>> had a destruct field). But these times are long gone, so just remove the
>> secondary AVPacket.
>>
>> Signed-off-by: Andreas Rheinhardt 
>> ---
>> It seems that the avcodec_decode_audio4() lost the ability to output
>> multiple frames per packet in 061a0c14bb5767bca72e3a7227ca400de439ba09.
>> Am I right?
> 
> I think I am ok with the change (and the two others), but I think it
> would be much more useful update src_movie to use the new decoding API:
> no need to keep a packet in the context, no need to distinguish between
> audio and video.
> 
> More work, but more useful. And it would allow to properly implement an
> activate version.
> 
> Regards,
> 
I might implement the switch to the new decoding API later, but I wanted
to fix the memleak first.

- Andreas
___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
https://ffmpeg.org/mailman/listinfo/ffmpeg-devel

To unsubscribe, visit link above, or email
ffmpeg-devel-requ...@ffmpeg.org with subject "unsubscribe".

[FFmpeg-devel] [PATCH] avformat/flic: add support for seeking to start

2020-09-10 Thread Paul B Mahol
Signed-off-by: Paul B Mahol 
---
 libavformat/flic.c | 38 +++---
 1 file changed, 35 insertions(+), 3 deletions(-)

diff --git a/libavformat/flic.c b/libavformat/flic.c
index e65c15..4552bff69c 100644
--- a/libavformat/flic.c
+++ b/libavformat/flic.c
@@ -202,6 +202,7 @@ static int flic_read_packet(AVFormatContext *s,
 int magic;
 int ret = 0;
 unsigned char preamble[FLIC_PREAMBLE_SIZE];
+int64_t pos = avio_tell(pb);
 
 while (!packet_read && !avio_feof(pb)) {
 
@@ -219,15 +220,19 @@ static int flic_read_packet(AVFormatContext *s,
 return ret;
 
 pkt->stream_index = flic->video_stream_index;
-pkt->pts = flic->frame_number++;
-pkt->pos = avio_tell(pb);
+pkt->pos = pos;
 memcpy(pkt->data, preamble, FLIC_PREAMBLE_SIZE);
 ret = avio_read(pb, pkt->data + FLIC_PREAMBLE_SIZE,
 size - FLIC_PREAMBLE_SIZE);
 if (ret != size - FLIC_PREAMBLE_SIZE) {
 ret = AVERROR(EIO);
 }
+pkt->flags = flic->frame_number == 0 ? AV_PKT_FLAG_KEY : 0;
+pkt->pts = flic->frame_number;
+if (flic->frame_number == 0)
+av_add_index_entry(s->streams[flic->video_stream_index], 
pkt->pos, pkt->pts, pkt->size, 0, AVINDEX_KEYFRAME);
 packet_read = 1;
+flic->frame_number++;
 } else if (magic == FLIC_TFTD_CHUNK_AUDIO) {
 if ((ret = av_new_packet(pkt, size)) < 0)
 return ret;
@@ -236,7 +241,8 @@ static int flic_read_packet(AVFormatContext *s,
 avio_skip(pb, 10);
 
 pkt->stream_index = flic->audio_stream_index;
-pkt->pos = avio_tell(pb);
+pkt->pos = pos;
+pkt->flags = AV_PKT_FLAG_KEY;
 ret = avio_read(pb, pkt->data, size);
 
 if (ret != size) {
@@ -254,6 +260,31 @@ static int flic_read_packet(AVFormatContext *s,
 return avio_feof(pb) ? AVERROR_EOF : ret;
 }
 
+static int flic_read_seek(AVFormatContext *s, int stream_index,
+  int64_t pts, int flags)
+{
+FlicDemuxContext *flic = s->priv_data;
+AVStream *st = s->streams[stream_index];
+int64_t pos, ts;
+int index;
+
+if (!st->index_entries || stream_index != flic->video_stream_index)
+return -1;
+
+index = av_index_search_timestamp(st, pts, flags);
+
+if (index < 0)
+index = av_index_search_timestamp(st, pts, flags ^ 
AVSEEK_FLAG_BACKWARD);
+if (index < 0)
+return -1;
+
+pos = st->index_entries[index].pos;
+ts  = st->index_entries[index].timestamp;
+flic->frame_number = ts;
+avio_seek(s->pb, pos, SEEK_SET);
+return 0;
+}
+
 AVInputFormat ff_flic_demuxer = {
 .name   = "flic",
 .long_name  = NULL_IF_CONFIG_SMALL("FLI/FLC/FLX animation"),
@@ -261,4 +292,5 @@ AVInputFormat ff_flic_demuxer = {
 .read_probe = flic_probe,
 .read_header= flic_read_header,
 .read_packet= flic_read_packet,
+.read_seek  = flic_read_seek,
 };
-- 
2.17.1

___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
https://ffmpeg.org/mailman/listinfo/ffmpeg-devel

To unsubscribe, visit link above, or email
ffmpeg-devel-requ...@ffmpeg.org with subject "unsubscribe".

Re: [FFmpeg-devel] [PATCH v4 1/2] libavcodec/webp: add support for animated WebP decoding

2020-09-10 Thread Moritz Barsnick
On Wed, Sep 09, 2020 at 09:57:24 +0200, Zlomek, Josef wrote:
> On Tue, Sep 8, 2020 at 3:19 PM Moritz Barsnick  wrote:
> > Missing version bumps.
> There is a version bump for libavformat, as new demuxer was added.

I didn't see that in v4.

> I did not know that version should be increased also when there is a change
> in existing decoder in libavcodec. Should it or not?

I guess not. Since you're expanding the feature set, you should at
least bump micro.

> > And perhaps an explanation why fate changed.
> > (Can be here, not in the commit message, if obvious. Was WebP
> > previously set to 10 fps by default?)
>
> Previously, WebP used generic image demuxer, which uses 25 fps by default.
> Usually, web browsers and webp libraries set default fps to 10 if frame
> duration is too low.
> So the logic in WebP demuxer was implemented similarly - if the frame
> duration is not specified (single image) or is too low, the duration is set
> to 100 ms resulting in 10 fps.
> The fate tests were updated accordingly.

Okay, thank you, I understand now. :-)

Moritz
___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
https://ffmpeg.org/mailman/listinfo/ffmpeg-devel

To unsubscribe, visit link above, or email
ffmpeg-devel-requ...@ffmpeg.org with subject "unsubscribe".

Re: [FFmpeg-devel] [PATCH 1/2] avcodec/mips: [loongson] Fixed mmi optimization

2020-09-10 Thread Shiyou Yin
>-Original Message-
>From: ffmpeg-devel-boun...@ffmpeg.org [mailto:ffmpeg-devel-boun...@ffmpeg.org] 
>On Behalf Of
>Shiyou Yin
>Sent: Thursday, September 3, 2020 2:30 PM
>To: ffmpeg-devel@ffmpeg.org
>Cc: gxw
>Subject: [FFmpeg-devel] [PATCH 1/2] avcodec/mips: [loongson] Fixed mmi 
>optimization
>
>From: gxw 
>
>Test case fate-checkasm-h264pred failed in latest community code.
>This patch fixed the bug.
>
>Signed-off-by: Shiyou Yin 
>---
> libavcodec/mips/h264pred_mmi.c | 8 ++--
> 1 file changed, 6 insertions(+), 2 deletions(-)
>
>diff --git a/libavcodec/mips/h264pred_mmi.c b/libavcodec/mips/h264pred_mmi.c
>index f4fe091..0209c2e 100644
>--- a/libavcodec/mips/h264pred_mmi.c
>+++ b/libavcodec/mips/h264pred_mmi.c
>@@ -178,7 +178,9 @@ void ff_pred8x8l_top_dc_8_mmi(uint8_t *src, int 
>has_topleft,
>
> "1: \n\t"
> "bnez   %[has_topright],2f  \n\t"
>-"pinsrh_3   %[ftmp2],   %[ftmp2],   %[ftmp4]\n\t"
>+"dli%[tmp0],0xa4\n\t"
>+"mtc1   %[tmp0],%[ftmp1]\n\t"
>+"pshufh %[ftmp2],   %[ftmp2],   %[ftmp1]\n\t"
>
> "2: \n\t"
> "dli%[tmp0],0x02\n\t"
>@@ -370,7 +372,9 @@ void ff_pred8x8l_vertical_8_mmi(uint8_t *src, int 
>has_topleft,
>
> "1: \n\t"
> "bnez   %[has_topright],2f  \n\t"
>-"pinsrh_3   %[ftmp11],  %[ftmp11],  %[ftmp9]\n\t"
>+"dli%[tmp0],0xa4\n\t"
>+"mtc1   %[tmp0],%[ftmp1]\n\t"
>+"pshufh %[ftmp11],  %[ftmp11],  %[ftmp1]\n\t"
>
> "2: \n\t"
> "dli%[tmp0],0x02\n\t"
>--
>2.1.0
>

Ping.

___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
https://ffmpeg.org/mailman/listinfo/ffmpeg-devel

To unsubscribe, visit link above, or email
ffmpeg-devel-requ...@ffmpeg.org with subject "unsubscribe".

Re: [FFmpeg-devel] [PATCH 2/2] Fix msa can't be disabled when '--cpu=loongson3a' assigned.

2020-09-10 Thread Shiyou Yin
>-Original Message-
>From: ffmpeg-devel-boun...@ffmpeg.org [mailto:ffmpeg-devel-boun...@ffmpeg.org] 
>On Behalf Of
>Shiyou Yin
>Sent: Thursday, September 3, 2020 2:30 PM
>To: ffmpeg-devel@ffmpeg.org
>Subject: [FFmpeg-devel] [PATCH 2/2] Fix msa can't be disabled when 
>'--cpu=loongson3a' assigned.
>
>There are compiler and runtime check for MSA and MMI.
>Remove the redundant setting of MSA and MMI for cores specified by "--cpu".
>
>Signed-off-by: Shiyou Yin 
>---
> configure | 9 -
> 1 file changed, 9 deletions(-)
>
>diff --git a/configure b/configure
>index 5640720..7f103fa 100755
>--- a/configure
>+++ b/configure
>@@ -5025,8 +5025,6 @@ elif enabled mips; then
> disable loongson3
> disable mipsdsp
> disable mipsdspr2
>-disable msa
>-disable mmi
>
> cpuflags="-march=$cpu"
>
>@@ -5035,17 +5033,13 @@ elif enabled mips; then
> mips1|mips3)
> ;;
> mips32r2)
>-enable msa
> enable mips32r2
> ;;
> mips32r5)
>-enable msa
> enable mips32r2
> enable mips32r5
> ;;
> mips64r2|mips64r5)
>-enable msa
>-enable mmi
> enable mips64r2
> enable loongson3
> ;;
>@@ -5062,7 +5056,6 @@ elif enabled mips; then
> enable mips32r2
> ;;
> p5600)
>-enable msa
> enable mips32r2
> enable mips32r5
> check_cflags "-mtune=p5600" && check_cflags "-msched-weight 
> -mload-store-pairs
>-funroll-loops"
>@@ -5077,7 +5070,6 @@ elif enabled mips; then
> ;;
> # Cores from Loongson
> loongson2e|loongson2f|loongson3*)
>-enable mmi
> enable local_aligned
> enable simd_align_16
> enable fast_64bit
>@@ -5100,7 +5092,6 @@ elif enabled mips; then
> case $cpu in
> loongson3*)
> enable loongson3
>-enable msa
> cpuflags="-march=loongson3a -mhard-float 
> $expensive_optimization_flag"
> ;;
> loongson2e)
>--
>2.1.0
>

Ping.

___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
https://ffmpeg.org/mailman/listinfo/ffmpeg-devel

To unsubscribe, visit link above, or email
ffmpeg-devel-requ...@ffmpeg.org with subject "unsubscribe".

Re: [FFmpeg-devel] [PATCH] libavcodec/options_table: Add missing colorspace options

2020-09-10 Thread Gyan Doshi



On 08-09-2020 08:31 pm, Harry Mallon wrote:



On 8 Sep 2020, at 14:29, Gyan Doshi  wrote:

On 08-09-2020 06:23 pm, Harry Mallon wrote:



On 8 Sep 2020, at 13:08, Gyan Doshi  wrote:

Hi Harry,

On 06-09-2020 04:24 pm, Gyan Doshi wrote:

On 06-09-2020 02:59 pm, Harry Mallon wrote:

Is there anything I need to do to move this forwards? I think it is relatively 
uncontroversial?

Agreed. Will push in 3 days if there are no objections.

Can you link to some doc references for the entries you added?


I'm not 100% sure what you mean, do you mean add some links to the 
doc/codecs.texi file, or just for the mailing list? ICtCp is definitely in 
ITU-R Rec 2100, I'm not sure about the others. It just seemed to me that they 
were missing from the command line arguments (and I needed to manually set 
ICtCp for something).

For the ML, at present. Ideally, the canonical standard docs. Avoid Wikipedia, 
forum posts..etc


Well ICtCp (which is the one I am interested in) is in ITU-R BT.2100 
https://www.itu.int/dms_pubrec/itu-r/rec/bt/R-REC-BT.2100-2-201807-I!!PDF-E.pdf
I am not sure where the chroma-derived ones come from. They are all already 
supported in ffmpeg 
(https://github.com/FFmpeg/FFmpeg/commit/f3571048669bf876681499f49e9df492f05f73c6),
 just they were missing from this specific command line option.


Will push now and supplement details later.

Thanks,
Gyan
___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
https://ffmpeg.org/mailman/listinfo/ffmpeg-devel

To unsubscribe, visit link above, or email
ffmpeg-devel-requ...@ffmpeg.org with subject "unsubscribe".

Re: [FFmpeg-devel] [PATCH] avformat/utils: Avoid duplicating extradata from extract_extradata BSF

2020-09-10 Thread Andreas Rheinhardt
Andreas Rheinhardt:
> Instead move the extradata contained in packet side-data to its
> destination. This is possible because the side data already has zeroed
> padding.
> 
> Notice that the check for FF_MAX_EXTRADATA_SIZE has been dropped,
> because said constant is from libavcodec/internal.h. If libavcodec
> wanted to enforce this, it should do so in the extract_extradata BSF
> instead.
> 
> Signed-off-by: Andreas Rheinhardt 
> ---
>  libavformat/utils.c | 23 ---
>  1 file changed, 8 insertions(+), 15 deletions(-)
> 
> diff --git a/libavformat/utils.c b/libavformat/utils.c
> index 807d9f10cb..63952e31a0 100644
> --- a/libavformat/utils.c
> +++ b/libavformat/utils.c
> @@ -3567,9 +3567,6 @@ static int extract_extradata(AVStream *st, const 
> AVPacket *pkt)
>  }
>  
>  while (ret >= 0 && !sti->avctx->extradata) {
> -int extradata_size;
> -uint8_t *extradata;
> -
>  ret = av_bsf_receive_packet(sti->extract_extradata.bsf, pkt_ref);
>  if (ret < 0) {
>  if (ret != AVERROR(EAGAIN) && ret != AVERROR_EOF)
> @@ -3577,19 +3574,15 @@ static int extract_extradata(AVStream *st, const 
> AVPacket *pkt)
>  continue;
>  }
>  
> -extradata = av_packet_get_side_data(pkt_ref, 
> AV_PKT_DATA_NEW_EXTRADATA,
> -_size);
> -
> -if (extradata) {
> -av_assert0(!sti->avctx->extradata);
> -if ((unsigned)extradata_size < FF_MAX_EXTRADATA_SIZE)
> -sti->avctx->extradata = av_mallocz(extradata_size + 
> AV_INPUT_BUFFER_PADDING_SIZE);
> -if (!sti->avctx->extradata) {
> -av_packet_unref(pkt_ref);
> -return AVERROR(ENOMEM);
> +for (int i = 0; i < pkt_ref->side_data_elems; i++) {
> +AVPacketSideData *side_data = _ref->side_data[i];
> +if (side_data->type == AV_PKT_DATA_NEW_EXTRADATA) {
> +sti->avctx->extradata  = side_data->data;
> +sti->avctx->extradata_size = side_data->size;
> +side_data->data = NULL;
> +side_data->size = 0;
> +break;
>  }
> -memcpy(sti->avctx->extradata, extradata, extradata_size);
> -sti->avctx->extradata_size = extradata_size;
>  }
>  av_packet_unref(pkt_ref);
>  }
> 
Will apply tomorrow unless there are objections.

- Andreas
___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
https://ffmpeg.org/mailman/listinfo/ffmpeg-devel

To unsubscribe, visit link above, or email
ffmpeg-devel-requ...@ffmpeg.org with subject "unsubscribe".

Re: [FFmpeg-devel] [PATCH 2/3] avcodec/extract_extradata: Remove always-true check

2020-09-10 Thread Andreas Rheinhardt
Andreas Rheinhardt:
> If a sequence header has already been found, it is certain that the next
> startcode (being disjoint from the sequence header startcode) can begin
> at index four at the earliest.
> 
> Signed-off-by: Andreas Rheinhardt 
> ---
>  libavcodec/extract_extradata_bsf.c | 2 --
>  1 file changed, 2 deletions(-)
> 
> diff --git a/libavcodec/extract_extradata_bsf.c 
> b/libavcodec/extract_extradata_bsf.c
> index 6e80076522..38517bdcf3 100644
> --- a/libavcodec/extract_extradata_bsf.c
> +++ b/libavcodec/extract_extradata_bsf.c
> @@ -275,7 +275,6 @@ static int extract_extradata_mpeg12(AVBSFContext *ctx, 
> AVPacket *pkt,
>  if (state == 0x1B3)
>  found = 1;
>  else if (found && state != 0x1B5 && state < 0x200 && state >= 0x100) 
> {
> -if (i > 3) {
>  *size = i - 3;
>  *data = av_malloc(*size + AV_INPUT_BUFFER_PADDING_SIZE);
>  if (!*data)
> @@ -287,7 +286,6 @@ static int extract_extradata_mpeg12(AVBSFContext *ctx, 
> AVPacket *pkt,
>  pkt->data += *size;
>  pkt->size -= *size;
>  }
> -}
>  break;
>  }
>  }
> 

Will apply the last two patches of this patchset tomorrow unless there
are objections.

- Andreas
___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
https://ffmpeg.org/mailman/listinfo/ffmpeg-devel

To unsubscribe, visit link above, or email
ffmpeg-devel-requ...@ffmpeg.org with subject "unsubscribe".

Re: [FFmpeg-devel] [PATCH 1/1] avfilter/vf_premultiply: add support for gbrapf32 format

2020-09-10 Thread Paul B Mahol
On Wed, Sep 09, 2020 at 08:36:08PM -0700, mindm...@gmail.com wrote:
> From: Mark Reid 
> 
> ---
>  libavfilter/vf_premultiply.c | 118 ++-
>  1 file changed, 115 insertions(+), 3 deletions(-)
> 

LGTM, applied.
___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
https://ffmpeg.org/mailman/listinfo/ffmpeg-devel

To unsubscribe, visit link above, or email
ffmpeg-devel-requ...@ffmpeg.org with subject "unsubscribe".

Re: [FFmpeg-devel] [PATCH 2/3] avfilter/src_movie: Remove unnecessary secondary AVPacket

2020-09-10 Thread Nicolas George
Andreas Rheinhardt (12020-09-10):
> The movie and amovie filters currently use two packets. One of the two,
> pkt0, is the owner of the returned packet; it is also the destination
> packet for av_read_frame(). The other one pkt is initially (i.e. after
> av_read_frame()) a copy of pkt0; copy means that the contents of both
> are absolutely the same: They both point to the same AVBufferRef and the
> same side data. This violation of the refcounted packet API is only
> possible because pkt is not considered to own its data. Only pkt0 is
> ever unreferenced.
> The reason for pkt's existence seems to be historic:
> The API used for decoding audio (namely avcodec_decode_audio4()) could
> consume frames partially, i.e. it could return multiple frames for one
> packet and therefore it returned how much of the input buffer had been
> consumed. The caller was then supposed to update the packet's data and
> size pointer to reflect this and call avcodec_decode_audio4() again with
> the updated packet to get the next frame.
> But before the introduction of refcounted AVPackets where knowledge and
> responsibility about what to free lies with the underlying AVBuffer such
> a procedure required a spare packet (or one would need to record the
> original data and size fields separately to restore them before freeing
> the packet; notice that this code has been written when AVPackets still
> had a destruct field). But these times are long gone, so just remove the
> secondary AVPacket.
> 
> Signed-off-by: Andreas Rheinhardt 
> ---
> It seems that the avcodec_decode_audio4() lost the ability to output
> multiple frames per packet in 061a0c14bb5767bca72e3a7227ca400de439ba09.
> Am I right?

I think I am ok with the change (and the two others), but I think it
would be much more useful update src_movie to use the new decoding API:
no need to keep a packet in the context, no need to distinguish between
audio and video.

More work, but more useful. And it would allow to properly implement an
activate version.

Regards,

-- 
  Nicolas George


signature.asc
Description: PGP signature
___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
https://ffmpeg.org/mailman/listinfo/ffmpeg-devel

To unsubscribe, visit link above, or email
ffmpeg-devel-requ...@ffmpeg.org with subject "unsubscribe".

[FFmpeg-devel] [PATCH v2 4/7] lavc/hevc_ps: Add slice parse support for HEVC SCC extension

2020-09-10 Thread Haihao Xiang
From: Linjie Fu 

Signed-off-by: Linjie Fu 
---
 libavcodec/hevcdec.c | 6 ++
 libavcodec/hevcdec.h | 4 
 2 files changed, 10 insertions(+)

diff --git a/libavcodec/hevcdec.c b/libavcodec/hevcdec.c
index b77df8d89f..cbfcf492a0 100644
--- a/libavcodec/hevcdec.c
+++ b/libavcodec/hevcdec.c
@@ -806,6 +806,12 @@ static int hls_slice_header(HEVCContext *s)
 sh->slice_cr_qp_offset = 0;
 }
 
+if (s->ps.pps->pps_slice_act_qp_offsets_present_flag) {
+sh->slice_act_y_qp_offset  = get_se_golomb(gb);
+sh->slice_act_cb_qp_offset = get_se_golomb(gb);
+sh->slice_act_cr_qp_offset = get_se_golomb(gb);
+}
+
 if (s->ps.pps->chroma_qp_offset_list_enabled_flag)
 sh->cu_chroma_qp_offset_enabled_flag = get_bits1(gb);
 else
diff --git a/libavcodec/hevcdec.h b/libavcodec/hevcdec.h
index 39c5c7f89f..6e22e044dd 100644
--- a/libavcodec/hevcdec.h
+++ b/libavcodec/hevcdec.h
@@ -292,6 +292,10 @@ typedef struct SliceHeader {
 int slice_cb_qp_offset;
 int slice_cr_qp_offset;
 
+int slice_act_y_qp_offset;
+int slice_act_cb_qp_offset;
+int slice_act_cr_qp_offset;
+
 uint8_t cu_chroma_qp_offset_enabled_flag;
 
 int beta_offset;///< beta_offset_div2 * 2
-- 
2.25.1

___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
https://ffmpeg.org/mailman/listinfo/ffmpeg-devel

To unsubscribe, visit link above, or email
ffmpeg-devel-requ...@ffmpeg.org with subject "unsubscribe".

[FFmpeg-devel] [PATCH v2 5/7] lavc/hevcdec: Fix the parsing for use_integer_mv_flag

2020-09-10 Thread Haihao Xiang
From: Linjie Fu 

According to 7.3.6.1, use_integer_mv_flag should be parsed if
motion_vector_resolution_control_idc equals to 2.

Otherwise wrong parameters in the subsequent parsing procedures
would be got.

Signed-off-by: Linjie Fu 
---
 libavcodec/hevcdec.c | 8 
 libavcodec/hevcdec.h | 1 +
 2 files changed, 9 insertions(+)

diff --git a/libavcodec/hevcdec.c b/libavcodec/hevcdec.c
index cbfcf492a0..38b451f315 100644
--- a/libavcodec/hevcdec.c
+++ b/libavcodec/hevcdec.c
@@ -794,6 +794,14 @@ static int hls_slice_header(HEVCContext *s)
sh->max_num_merge_cand);
 return AVERROR_INVALIDDATA;
 }
+
+// Syntax in 7.3.6.1
+if (s->ps.sps->motion_vector_resolution_control_idc == 2)
+sh->use_integer_mv_flag = get_bits1(gb);
+else
+// Inferred to be equal to 
motion_vector_resolution_control_idc if not present
+sh->use_integer_mv_flag = 
s->ps.sps->motion_vector_resolution_control_idc;
+
 }
 
 sh->slice_qp_delta = get_se_golomb(gb);
diff --git a/libavcodec/hevcdec.h b/libavcodec/hevcdec.h
index 6e22e044dd..1164af2862 100644
--- a/libavcodec/hevcdec.h
+++ b/libavcodec/hevcdec.h
@@ -302,6 +302,7 @@ typedef struct SliceHeader {
 int tc_offset;  ///< tc_offset_div2 * 2
 
 unsigned int max_num_merge_cand; ///< 5 - 5_minus_max_num_merge_cand
+uint8_t use_integer_mv_flag;
 
 unsigned *entry_point_offset;
 int * offset;
-- 
2.25.1

___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
https://ffmpeg.org/mailman/listinfo/ffmpeg-devel

To unsubscribe, visit link above, or email
ffmpeg-devel-requ...@ffmpeg.org with subject "unsubscribe".

[FFmpeg-devel] [PATCH v2 3/7] lavc/hevc_ps: Add pps parse support for HEVC SCC extension

2020-09-10 Thread Haihao Xiang
From: Linjie Fu 

Signed-off-by: Linjie Fu 
Signed-off-by: Haihao Xiang 
---
v2 update:
- Ignore pps_multilayer_extension_flag, pps_3d_extension_flag and
  pps_scc_extension_flag for non-SCC streams 
- Return AVERROR_PATCHWELCOME for pps_multilayer_extension_flag(1) and
pps_3d_extension_flag(1).
- pps_palette_predictor_initializer is an u(v) value instead of an ue(v)
- Rename pps_scc_extensions_flag / pps_scc_extensions to
  pps_scc_extension_flag / pps_scc_extension to keep consistency with
  HEVC spec

 libavcodec/hevc_ps.c | 70 +++-
 libavcodec/hevc_ps.h | 17 +++
 2 files changed, 86 insertions(+), 1 deletion(-)

diff --git a/libavcodec/hevc_ps.c b/libavcodec/hevc_ps.c
index d65efc1aef..704b666756 100644
--- a/libavcodec/hevc_ps.c
+++ b/libavcodec/hevc_ps.c
@@ -1400,6 +1400,48 @@ static int pps_range_extensions(GetBitContext *gb, 
AVCodecContext *avctx,
 return(0);
 }
 
+static int pps_scc_extension(GetBitContext *gb, AVCodecContext *avctx,
+ HEVCPPS *pps, HEVCSPS *sps)
+{
+int num_comps;
+int i, ret;
+
+pps->pps_curr_pic_ref_enabled_flag = get_bits1(gb);
+if (pps->residual_adaptive_colour_transform_enabled_flag = get_bits1(gb)) {
+pps->pps_slice_act_qp_offsets_present_flag = get_bits1(gb);
+pps->pps_act_y_qp_offset  = get_se_golomb_long(gb) - 5;
+pps->pps_act_cb_qp_offset = get_se_golomb_long(gb) - 5;
+pps->pps_act_cr_qp_offset = get_se_golomb_long(gb) - 3;
+
+#define CHECK_QP_OFFSET(name) (pps->pps_act_ ## name ## _qp_offset < -12 || \
+   pps->pps_act_ ## name ## _qp_offset > 12)
+ret = CHECK_QP_OFFSET(y) || CHECK_QP_OFFSET(cb) || CHECK_QP_OFFSET(cr);
+#undef CHECK_QP_OFFSET
+if (ret) {
+av_log(avctx, AV_LOG_ERROR,
+   "PpsActQpOffsetY/Cb/Cr shall be in the range of [-12, 
12].\n");
+return AVERROR_INVALIDDATA;
+}
+}
+
+if (pps->pps_palette_predictor_initializers_present_flag = get_bits1(gb)) {
+if ((pps->pps_num_palette_predictor_initializers = 
get_ue_golomb_long(gb)) > 0) {
+pps->monochrome_palette_flag = get_bits1(gb);
+pps->luma_bit_depth_entry_minus8 = get_ue_golomb_long(gb);
+if (!pps->monochrome_palette_flag)
+pps->chroma_bit_depth_entry_minus8 = get_ue_golomb_long(gb);
+num_comps = pps->monochrome_palette_flag ? 1 : 3;
+for (int comp = 0; comp < num_comps; comp++)
+for (i = 0; i < pps->pps_num_palette_predictor_initializers; 
i++)
+pps->pps_palette_predictor_initializer[comp][i] =
+get_bits(gb, 8 + (!comp ? 
pps->luma_bit_depth_entry_minus8 :
+  pps->chroma_bit_depth_entry_minus8));
+}
+}
+
+return 0;
+}
+
 static inline int setup_pps(AVCodecContext *avctx, GetBitContext *gb,
 HEVCPPS *pps, HEVCSPS *sps)
 {
@@ -1753,11 +1795,37 @@ int ff_hevc_decode_nal_pps(GetBitContext *gb, 
AVCodecContext *avctx,
 
 if (get_bits1(gb)) { // pps_extension_present_flag
 pps->pps_range_extensions_flag = get_bits1(gb);
-skip_bits(gb, 7); // pps_extension_7bits
+
+/* hevc-conformance-PS_A_VIDYO_3 in fate has 
pps_multilayer_extension_flag (1),
+ * pps_3d_extension_flag (1) and pps_scc_extension_flag (1) but has 
the wrong
+ * data for pps_multilayer_extension(), pps_3d_extension(), and 
pps_scc_extension().
+ * To avoid regression for hevc-conformance-PS_A_VIDYO_3, here check
+ * pps_multilayer_extension_flag, pps_3d_extension_flag and 
pps_scc_extension_flag
+ * only for SCC streams */
+if (sps->ptl.general_ptl.profile_idc == FF_PROFILE_HEVC_SCC) {
+pps->pps_multilayer_extension_flag = get_bits1(gb);
+pps->pps_3d_extension_flag = get_bits1(gb);
+pps->pps_scc_extension_flag= get_bits1(gb);
+skip_bits(gb, 4); // pps_extension_4bits
+} else
+skip_bits(gb, 7);
+
 if (sps->ptl.general_ptl.profile_idc == FF_PROFILE_HEVC_REXT && 
pps->pps_range_extensions_flag) {
 if ((ret = pps_range_extensions(gb, avctx, pps, sps)) < 0)
 goto err;
 }
+
+if (pps->pps_multilayer_extension_flag || pps->pps_3d_extension_flag) {
+av_log(avctx, AV_LOG_ERROR,
+   "multilayer_extension or 3d_extension not yet 
implemented\n");
+ret = AVERROR_PATCHWELCOME;
+goto err;
+}
+
+if (pps->pps_scc_extension_flag) {
+if ((ret = pps_scc_extension(gb, avctx, pps, sps)) < 0)
+goto err;
+}
 }
 
 ret = setup_pps(avctx, gb, pps, sps);
diff --git a/libavcodec/hevc_ps.h b/libavcodec/hevc_ps.h
index be23758008..155b66062e 100644
--- a/libavcodec/hevc_ps.h
+++ b/libavcodec/hevc_ps.h
@@ -312,6 

[FFmpeg-devel] [PATCH v2 6/7] lavc/hevcdec: Set max_num_merge_cand to uint8_t

2020-09-10 Thread Haihao Xiang
From: Linjie Fu 

uint8_t is big enough and keep consistent with the definition in
cbs_h265.h.

Signed-off-by: Linjie Fu 
---
 libavcodec/hevcdec.h | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/libavcodec/hevcdec.h b/libavcodec/hevcdec.h
index 1164af2862..464eb7cd3c 100644
--- a/libavcodec/hevcdec.h
+++ b/libavcodec/hevcdec.h
@@ -301,7 +301,7 @@ typedef struct SliceHeader {
 int beta_offset;///< beta_offset_div2 * 2
 int tc_offset;  ///< tc_offset_div2 * 2
 
-unsigned int max_num_merge_cand; ///< 5 - 5_minus_max_num_merge_cand
+uint8_t max_num_merge_cand; ///< 5 - 5_minus_max_num_merge_cand
 uint8_t use_integer_mv_flag;
 
 unsigned *entry_point_offset;
-- 
2.25.1

___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
https://ffmpeg.org/mailman/listinfo/ffmpeg-devel

To unsubscribe, visit link above, or email
ffmpeg-devel-requ...@ffmpeg.org with subject "unsubscribe".

[FFmpeg-devel] [PATCH v2 2/7] lavc/hevc_ps: Add sps parse support for HEVC SCC extension syntax

2020-09-10 Thread Haihao Xiang
From: Linjie Fu 

According to 7.3.2.2.3 in T-REC-H.265-201911.

Signed-off-by: Linjie Fu 
Signed-off-by: Haihao Xiang 
---
v2 update: 
- Ignore sps_multilayer_extension_flag, sps_3d_extension_flag and
  sps_scc_extension_flag for non-SCC streams
- Return AVERROR_PATCHWELCOME for sps_multilayer_extension_flag(1) and
sps_3d_extension_flag(1).
- sps_palette_predictor_initializer is an u(v) value instead of an ue(v) 

 libavcodec/hevc.h|  3 +++
 libavcodec/hevc_ps.c | 44 +---
 libavcodec/hevc_ps.h | 15 +++
 3 files changed, 59 insertions(+), 3 deletions(-)

diff --git a/libavcodec/hevc.h b/libavcodec/hevc.h
index 1804755327..6b454a75c1 100644
--- a/libavcodec/hevc.h
+++ b/libavcodec/hevc.h
@@ -154,6 +154,9 @@ enum {
 // get near that, though, so set a lower limit here with the maximum
 // possible value for 4K video (at most 135 16x16 Ctb rows).
 HEVC_MAX_ENTRY_POINT_OFFSETS = HEVC_MAX_TILE_COLUMNS * 135,
+
+// A.3.7: Screen content coding extensions
+HEVC_MAX_PALETTE_PREDICTOR_SIZE = 128,
 };
 
 
diff --git a/libavcodec/hevc_ps.c b/libavcodec/hevc_ps.c
index 584e2ba0d6..d65efc1aef 100644
--- a/libavcodec/hevc_ps.c
+++ b/libavcodec/hevc_ps.c
@@ -909,7 +909,7 @@ int ff_hevc_parse_sps(HEVCSPS *sps, GetBitContext *gb, 
unsigned int *sps_id,
 HEVCWindow *ow;
 int ret = 0;
 int log2_diff_max_min_transform_block_size;
-int bit_depth_chroma, start, vui_present, sublayer_ordering_info;
+int bit_depth_chroma, start, vui_present, sublayer_ordering_info, 
num_comps;
 int i;
 
 // Coded parameters
@@ -1130,8 +1130,20 @@ int ff_hevc_parse_sps(HEVCSPS *sps, GetBitContext *gb, 
unsigned int *sps_id,
 decode_vui(gb, avctx, apply_defdispwin, sps);
 
 if (get_bits1(gb)) { // sps_extension_flag
-sps->sps_range_extension_flag = get_bits1(gb);
-skip_bits(gb, 7); //sps_extension_7bits = get_bits(gb, 7);
+sps->sps_range_extension_flag  = get_bits1(gb);
+
+/* To keep consistency with the workaround for 
hevc-conformance-PS_A_VIDYO_3
+ * in PPS, here ignore sps_multilayer_extension_flag, 
sps_3d_extension_flag
+ * and sps_scc_extension_flag for non-SCC streams too. Note 
multilayer_extension
+ * or 3d_extension is not implemented in FFmpeg */
+if (sps->ptl.general_ptl.profile_idc == FF_PROFILE_HEVC_SCC) {
+sps->sps_multilayer_extension_flag = get_bits1(gb);
+sps->sps_3d_extension_flag = get_bits1(gb);
+sps->sps_scc_extension_flag= get_bits1(gb);
+skip_bits(gb, 4); //sps_extension_4bits = get_bits(gb, 4);
+} else
+skip_bits(gb, 7);
+
 if (sps->sps_range_extension_flag) {
 sps->transform_skip_rotation_enabled_flag = get_bits1(gb);
 sps->transform_skip_context_enabled_flag  = get_bits1(gb);
@@ -1157,6 +1169,32 @@ int ff_hevc_parse_sps(HEVCSPS *sps, GetBitContext *gb, 
unsigned int *sps_id,
 av_log(avctx, AV_LOG_WARNING,
"cabac_bypass_alignment_enabled_flag not yet 
implemented\n");
 }
+if (sps->sps_multilayer_extension_flag || sps->sps_3d_extension_flag) {
+av_log(avctx, AV_LOG_ERROR,
+   "multilayer_extension or 3d_extension not yet 
implemented\n");
+return AVERROR_PATCHWELCOME;
+}
+
+if (sps->sps_scc_extension_flag) {
+sps->sps_curr_pic_ref_enabled_flag = get_bits1(gb);
+sps->palette_mode_enabled_flag = get_bits1(gb);
+if (sps->palette_mode_enabled_flag) {
+sps->palette_max_size = get_ue_golomb_long(gb);
+sps->delta_palette_max_predictor_size = get_ue_golomb_long(gb);
+sps->sps_palette_predictor_initializers_present_flag = 
get_bits1(gb);
+
+if (sps->sps_palette_predictor_initializers_present_flag) {
+sps->sps_num_palette_predictor_initializers_minus1 = 
get_ue_golomb_long(gb);
+num_comps = !sps->chroma_format_idc ? 1 : 3;
+for (int comp = 0; comp < num_comps; comp++)
+for (i = 0; i <= 
sps->sps_num_palette_predictor_initializers_minus1; i++)
+sps->sps_palette_predictor_initializer[comp][i] =
+get_bits(gb, !comp ? sps->bit_depth : 
sps->bit_depth_chroma);
+}
+}
+sps->motion_vector_resolution_control_idc   = get_bits(gb, 2);
+sps->intra_boundary_filtering_disabled_flag = get_bits1(gb);
+}
 }
 if (apply_defdispwin) {
 sps->output_window.left_offset   += sps->vui.def_disp_win.left_offset;
diff --git a/libavcodec/hevc_ps.h b/libavcodec/hevc_ps.h
index 2a1bbf6489..be23758008 100644
--- a/libavcodec/hevc_ps.h
+++ b/libavcodec/hevc_ps.h
@@ -223,6 +223,21 @@ typedef struct HEVCSPS {
 int 

[FFmpeg-devel] [PATCH v2 7/7] lavc/hevc: Update reference list for SCC

2020-09-10 Thread Haihao Xiang
From: Linjie Fu 

Screen Content Coding allows non-intra slice in an IDR frame, and would
mark the current decoded picture as "used for long-term reference", no
matter TwoVersionsOfCurrDecPicFlag(8.1.3), hence some previous restricts
are not suitable any more.

Constructe RefPicListTemp and RefPicList according to 8-8/9/10.

Signed-off-by: Linjie Fu 
---
 libavcodec/hevc_refs.c | 27 +--
 libavcodec/hevcdec.c   |  3 ++-
 2 files changed, 27 insertions(+), 3 deletions(-)

diff --git a/libavcodec/hevc_refs.c b/libavcodec/hevc_refs.c
index 4f6d985ae6..ba32e232bb 100644
--- a/libavcodec/hevc_refs.c
+++ b/libavcodec/hevc_refs.c
@@ -301,7 +301,7 @@ int ff_hevc_slice_rpl(HEVCContext *s)
 return ret;
 
 if (!(s->rps[ST_CURR_BEF].nb_refs + s->rps[ST_CURR_AFT].nb_refs +
-  s->rps[LT_CURR].nb_refs)) {
+  s->rps[LT_CURR].nb_refs) && 
!s->ps.pps->pps_curr_pic_ref_enabled_flag) {
 av_log(s->avctx, AV_LOG_ERROR, "Zero refs in the frame RPS.\n");
 return AVERROR_INVALIDDATA;
 }
@@ -328,6 +328,12 @@ int ff_hevc_slice_rpl(HEVCContext *s)
 rpl_tmp.nb_refs++;
 }
 }
+// Construct RefPicList0, RefPicList1 (8-8, 8-10)
+if (s->ps.pps->pps_curr_pic_ref_enabled_flag) {
+rpl_tmp.ref[rpl_tmp.nb_refs]= s->ref;
+rpl_tmp.isLongTerm[rpl_tmp.nb_refs] = 1;
+rpl_tmp.nb_refs++;
+}
 }
 
 /* reorder the references if necessary */
@@ -350,6 +356,12 @@ int ff_hevc_slice_rpl(HEVCContext *s)
 rpl->nb_refs = FFMIN(rpl->nb_refs, sh->nb_refs[list_idx]);
 }
 
+// 8-9
+if (s->ps.pps->pps_curr_pic_ref_enabled_flag && sh->slice_type == 
HEVC_SLICE_P &&
+!sh->rpl_modification_flag[list_idx] && rpl_tmp.nb_refs > 
sh->nb_refs[L0]) {
+rpl->ref[sh->nb_refs[L0]] = s->ref;
+}
+
 if (sh->collocated_list == list_idx &&
 sh->collocated_ref_idx < rpl->nb_refs)
 s->ref->collocated_ref = rpl->ref[sh->collocated_ref_idx];
@@ -423,7 +435,8 @@ static int add_candidate_ref(HEVCContext *s, RefPicList 
*list,
 {
 HEVCFrame *ref = find_ref_idx(s, poc, use_msb);
 
-if (ref == s->ref || list->nb_refs >= HEVC_MAX_REFS)
+if ((ref == s->ref && !s->ps.pps->pps_curr_pic_ref_enabled_flag) ||
+list->nb_refs >= HEVC_MAX_REFS)
 return AVERROR_INVALIDDATA;
 
 if (!ref) {
@@ -492,6 +505,12 @@ int ff_hevc_frame_rps(HEVCContext *s)
 goto fail;
 }
 
+if (s->ps.pps->pps_curr_pic_ref_enabled_flag) {
+ret = add_candidate_ref(s, [LT_FOLL], s->poc, 
HEVC_FRAME_FLAG_LONG_REF, 1);
+if (ret < 0)
+goto fail;
+}
+
 fail:
 /* release any frames that are now unused */
 for (i = 0; i < FF_ARRAY_ELEMS(s->DPB); i++)
@@ -518,5 +537,9 @@ int ff_hevc_frame_nb_refs(const HEVCContext *s)
 for (i = 0; i < long_rps->nb_refs; i++)
 ret += !!long_rps->used[i];
 }
+
+if (s->ps.pps->pps_curr_pic_ref_enabled_flag)
+ret++;
+
 return ret;
 }
diff --git a/libavcodec/hevcdec.c b/libavcodec/hevcdec.c
index 38b451f315..f34e3668db 100644
--- a/libavcodec/hevcdec.c
+++ b/libavcodec/hevcdec.c
@@ -623,7 +623,8 @@ static int hls_slice_header(HEVCContext *s)
sh->slice_type);
 return AVERROR_INVALIDDATA;
 }
-if (IS_IRAP(s) && sh->slice_type != HEVC_SLICE_I) {
+if (IS_IRAP(s) && sh->slice_type != HEVC_SLICE_I &&
+s->ps.sps->ptl.general_ptl.profile_idc != FF_PROFILE_HEVC_SCC) {
 av_log(s->avctx, AV_LOG_ERROR, "Inter slices in an IRAP frame.\n");
 return AVERROR_INVALIDDATA;
 }
-- 
2.25.1

___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
https://ffmpeg.org/mailman/listinfo/ffmpeg-devel

To unsubscribe, visit link above, or email
ffmpeg-devel-requ...@ffmpeg.org with subject "unsubscribe".

[FFmpeg-devel] [PATCH v2 1/7] lavc/avcodec: Add FF_PROFILE_HEVC_SCC for screen content coding

2020-09-10 Thread Haihao Xiang
From: Linjie Fu 

Signed-off-by: Linjie Fu 
---
 libavcodec/avcodec.h  | 1 +
 libavcodec/hevc_ps.c  | 2 ++
 libavcodec/profiles.c | 1 +
 3 files changed, 4 insertions(+)

diff --git a/libavcodec/avcodec.h b/libavcodec/avcodec.h
index c91b2fd169..32e4770de2 100644
--- a/libavcodec/avcodec.h
+++ b/libavcodec/avcodec.h
@@ -1948,6 +1948,7 @@ typedef struct AVCodecContext {
 #define FF_PROFILE_HEVC_MAIN_10 2
 #define FF_PROFILE_HEVC_MAIN_STILL_PICTURE  3
 #define FF_PROFILE_HEVC_REXT4
+#define FF_PROFILE_HEVC_SCC 9
 
 #define FF_PROFILE_AV1_MAIN 0
 #define FF_PROFILE_AV1_HIGH 1
diff --git a/libavcodec/hevc_ps.c b/libavcodec/hevc_ps.c
index ea6fd536c6..584e2ba0d6 100644
--- a/libavcodec/hevc_ps.c
+++ b/libavcodec/hevc_ps.c
@@ -281,6 +281,8 @@ static int decode_profile_tier_level(GetBitContext *gb, 
AVCodecContext *avctx,
 av_log(avctx, AV_LOG_DEBUG, "Main Still Picture profile bitstream\n");
 else if (ptl->profile_idc == FF_PROFILE_HEVC_REXT)
 av_log(avctx, AV_LOG_DEBUG, "Range Extension profile bitstream\n");
+else if (ptl->profile_idc == FF_PROFILE_HEVC_SCC)
+av_log(avctx, AV_LOG_DEBUG, "Screen Content Coding Extension profile 
bitstream\n");
 else
 av_log(avctx, AV_LOG_WARNING, "Unknown HEVC profile: %d\n", 
ptl->profile_idc);
 
diff --git a/libavcodec/profiles.c b/libavcodec/profiles.c
index e59a3a5c12..e815b90c6a 100644
--- a/libavcodec/profiles.c
+++ b/libavcodec/profiles.c
@@ -79,6 +79,7 @@ const AVProfile ff_hevc_profiles[] = {
 { FF_PROFILE_HEVC_MAIN_10,  "Main 10" },
 { FF_PROFILE_HEVC_MAIN_STILL_PICTURE,   "Main Still Picture"  },
 { FF_PROFILE_HEVC_REXT, "Rext"},
+{ FF_PROFILE_HEVC_SCC,  "Scc" },
 { FF_PROFILE_UNKNOWN },
 };
 
-- 
2.25.1

___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
https://ffmpeg.org/mailman/listinfo/ffmpeg-devel

To unsubscribe, visit link above, or email
ffmpeg-devel-requ...@ffmpeg.org with subject "unsubscribe".

[FFmpeg-devel] [PATCH v2 0/7] HEVC native support for Screen content coding

2020-09-10 Thread Haihao Xiang
Resend Linjie's patchset with the updates.

As a part of the support for VA-API HEVC SCC decoding (gen12, Tiger
Lake+).

The full support could be accessed in:
https://github.com/intel-media-ci/ffmpeg/pull/231

The VAAPI part would be provided later once the implementations of
native parsing and reference management are all decent.

Linjie Fu (7):
  lavc/avcodec: Add FF_PROFILE_HEVC_SCC for screen content coding
  lavc/hevc_ps: Add sps parse support for HEVC SCC extension syntax
  lavc/hevc_ps: Add pps parse support for HEVC SCC extension
  lavc/hevc_ps: Add slice parse support for HEVC SCC extension
  lavc/hevcdec: Fix the parsing for use_integer_mv_flag
  lavc/hevcdec: Set max_num_merge_cand to uint8_t
  lavc/hevc: Update reference list for SCC

 libavcodec/avcodec.h   |   1 +
 libavcodec/hevc.h  |   3 ++
 libavcodec/hevc_ps.c   | 118 +++--
 libavcodec/hevc_ps.h   |  32 +++
 libavcodec/hevc_refs.c |  27 +-
 libavcodec/hevcdec.c   |  17 +-
 libavcodec/hevcdec.h   |   7 ++-
 libavcodec/profiles.c  |   1 +
 8 files changed, 197 insertions(+), 9 deletions(-)

-- 
2.25.1

___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
https://ffmpeg.org/mailman/listinfo/ffmpeg-devel

To unsubscribe, visit link above, or email
ffmpeg-devel-requ...@ffmpeg.org with subject "unsubscribe".