Re: [FFmpeg-devel] [PATCH v2 2/3] libavcodec: add a new AV_CODEC_EXPORT_DATA_FILM_GRAIN flag and option

2020-11-15 Thread Anton Khirnov
Quoting Lynne (2020-11-14 15:32:35) > Nov 14, 2020, 11:23 by an...@khirnov.net: > > > Quoting Lynne (2020-11-12 18:42:22) > > > >> This introduces a new field to allow decoders to export their film grain > >> parameters. > >> Will be used by the next patch. > >> > >> Patch attached. > >> From

Re: [FFmpeg-devel] [PATCH 5/7] avformat/wavdec: Avoid zeroing written to array

2020-11-15 Thread Anton Khirnov
Quoting Michael Niedermayer (2020-11-16 01:05:07) > On Sat, Nov 14, 2020 at 11:12:15AM +0100, Anton Khirnov wrote: > > Quoting Michael Niedermayer (2020-11-10 00:04:54) > > > Fixes: OOM > > > Fixes: > > > 26934/clusterfuzz-testcase-minimized-ffmpeg_dem_W64_fuzzer-5996784213819392 > > > > > >

Re: [FFmpeg-devel] [PATCH 10/18] lavf: move AVStream.*index_entries* to AVStreamInternal

2020-11-15 Thread Anton Khirnov
Quoting Xiang, Haihao (2020-11-16 06:16:55) > > This change breaks the compiling of gst-libav ( > https://gitlab.freedesktop.org/gstreamer/gst-libav), I filed > https://trac.ffmpeg.org/ticket/8988 to track this regression. This is not a regression, it's a bug in gst-libav. These fields are

Re: [FFmpeg-devel] [PATCH 10/18] lavf: move AVStream.*index_entries* to AVStreamInternal

2020-11-15 Thread Xiang, Haihao
This change breaks the compiling of gst-libav ( https://gitlab.freedesktop.org/gstreamer/gst-libav), I filed https://trac.ffmpeg.org/ticket/8988 to track this regression. Thanks Haihao > Those are private fields, no reason to have them exposed in a public > header. Since there are some

[FFmpeg-devel] [PATCH v2] nv-codec-headers: add cuMemcpy

2020-11-15 Thread leozhang
Signed-off-by: leozhang --- include/ffnvcodec/dynlink_cuda.h | 2 ++ include/ffnvcodec/dynlink_loader.h | 4 2 files changed, 6 insertions(+) diff --git a/include/ffnvcodec/dynlink_cuda.h b/include/ffnvcodec/dynlink_cuda.h index 117fdc5..baafa49 100644 ---

[FFmpeg-devel] [PATCH] Support HDR10+ metadata for HEVC.

2020-11-15 Thread Mohammad Izadi
From: Mohammad Izadi HDR10+ is dynamic metadata (A/341 Amendment - SMPTE2094-40) that needs to be decoded from ITU-T T.35 in HEVC bitstream. The HDR10+ is transferred to side data packet to be used or passed through. --- The fate test file can be found here:

Re: [FFmpeg-devel] [PATCH 100/114] avcodec/vp3: Use symbols table for VP3 motion vectors

2020-11-15 Thread Peter Ross
On Sun, Nov 15, 2020 at 06:37:25AM +0100, Andreas Rheinhardt wrote: > Peter Ross: > > On Tue, Nov 10, 2020 at 11:58:22AM +0100, Andreas Rheinhardt wrote: > >> Expressions like array[get_vlc2()] can be optimized by using a symbols > >> table if the array is always the same for a given VLC. This

Re: [FFmpeg-devel] [PATCH] nv-codec-headers: add cuMemcpy

2020-11-15 Thread leozhang
Timo Rothenpieler 于2020年11月13日周五 下午8:20写道: > > Please also add cuMemcpyAsync while at it. Will add it. > > What for and where is this needed? cuMemcpy is used to copy 1D array between host and device. For example, the gauss blur filter weights can be calculated by CPU, then memcpy to device

Re: [FFmpeg-devel] [PATCH 4/4 v3] avcodec/av1dec: add an option to select an operating point

2020-11-15 Thread James Almer
On 11/15/2020 6:55 PM, James Almer wrote: Signed-off-by: James Almer --- doc/decoders.texi | 13 + libavcodec/av1dec.c | 30 ++ libavcodec/av1dec.h | 4 3 files changed, 47 insertions(+) diff --git a/doc/decoders.texi b/doc/decoders.texi

Re: [FFmpeg-devel] [PATCH 5/7] avformat/wavdec: Avoid zeroing written to array

2020-11-15 Thread Michael Niedermayer
On Sat, Nov 14, 2020 at 11:12:15AM +0100, Anton Khirnov wrote: > Quoting Michael Niedermayer (2020-11-10 00:04:54) > > Fixes: OOM > > Fixes: > > 26934/clusterfuzz-testcase-minimized-ffmpeg_dem_W64_fuzzer-5996784213819392 > > > > Found-by: continuous fuzzing process > >

[FFmpeg-devel] [PATCH 4/4 v3] avcodec/av1dec: add an option to select an operating point

2020-11-15 Thread James Almer
Signed-off-by: James Almer --- doc/decoders.texi | 13 + libavcodec/av1dec.c | 30 ++ libavcodec/av1dec.h | 4 3 files changed, 47 insertions(+) diff --git a/doc/decoders.texi b/doc/decoders.texi index bfab562fb2..27c6ba4a5d 100644 ---

[FFmpeg-devel] [PATCH 2/4 v2] avcodec/cbs: allow cbs_read_fragment_content() to discard units

2020-11-15 Thread James Almer
The caller may not need all units in a fragment in reading only scenarios. They could in fact alter global state stored in the private CodedBitstreamType fields in an undesirable way. And unlike preventing decomposition of units, discarding can be done based on parsed values within the unit.

[FFmpeg-devel] [PATCH 3/4 v3] avcodec/cbs_av1: add an option to select an operating point

2020-11-15 Thread James Almer
This implements the function drop_obu() as defined in Setion 6.2.1 from the spec. In a reading only scenario, units that belong to an operating point the caller doesn't want should not be parsed. Signed-off-by: James Almer --- libavcodec/cbs_av1.c | 30 +-

[FFmpeg-devel] [PATCH 1/4 v2] avcodec/cbs: add an AVClass to CodedBitstreamType for option handling

2020-11-15 Thread James Almer
So unit parsing may be configured with caller set options. Signed-off-by: James Almer --- libavcodec/cbs.c | 9 + libavcodec/cbs_internal.h | 6 ++ 2 files changed, 15 insertions(+) diff --git a/libavcodec/cbs.c b/libavcodec/cbs.c index c8c526ab12..c7afccd6f5 100644 ---

Re: [FFmpeg-devel] [PATCH 1/2] avcodec/cbs_h265_syntax_template: Better check for num_long_term_sps

2020-11-15 Thread Mark Thompson
On 14/11/2020 10:18, Michael Niedermayer wrote: Fixes: index 26 out of bounds for type 'uint8_t [16]' Fixes: 24913/clusterfuzz-testcase-minimized-ffmpeg_BSF_HEVC_METADATA_fuzzer-6261760693370880 Found-by: continuous fuzzing process

[FFmpeg-devel] [PATCH 1/4] avformat/rtsp: set AV_OPT_FLAG_DEPRECATED on depracated options

2020-11-15 Thread Andriy Gelman
From: Andriy Gelman Signed-off-by: Andriy Gelman --- libavformat/rtsp.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/libavformat/rtsp.c b/libavformat/rtsp.c index d9832bbf1f..2ef75f50e3 100644 --- a/libavformat/rtsp.c +++ b/libavformat/rtsp.c @@ -94,7 +94,7 @@ const

[FFmpeg-devel] [PATCH 3/4] avformat/rtsp: fix timeout option

2020-11-15 Thread Andriy Gelman
From: Andriy Gelman 92c40ef882be115e72d2aa02f9032b7ce88f8537 added a listen_timeout option for sdp. This allowed a user to set variable timeout in sdp which was originally hard coded to 10 seconds. The commit used the initial_timeout variable to store the value. However, in rtsp this variable

[FFmpeg-devel] [PATCH 2/4] doc/protocols: update options

2020-11-15 Thread Andriy Gelman
From: Andriy Gelman Define listen_timeout. Set user-agent and timeout to deprecated. Signed-off-by: Andriy Gelman --- doc/protocols.texi | 13 +++-- 1 file changed, 11 insertions(+), 2 deletions(-) diff --git a/doc/protocols.texi b/doc/protocols.texi index b4efa14509..fd866f57a5

[FFmpeg-devel] [PATCH 4/4] avformat/rtsp: change to default stimeout to 10 seconds

2020-11-15 Thread Andriy Gelman
From: Andriy Gelman This is to match the behaviour before commits: c8101aabee654f6d147a4d89f77fa73e18908610 92c40ef882be115e72d2aa02f9032b7ce88f8537 The only difference is that now a 10 second timeout will also be set when the rtsp session is being setup, whereas before this was an infinite

Re: [FFmpeg-devel] [PATCH 2/4] avcodec/cbs: allow cbs_read_fragment_content() to discard units

2020-11-15 Thread James Almer
On 10/1/2020 9:38 PM, James Almer wrote: On 10/1/2020 8:57 PM, Mark Thompson wrote: On 20/09/2020 18:24, James Almer wrote: The caller may not need all units in a fragment in reading only scenarios. They could in fact alter global state stored in the private CodedBitstreamType fields in an

Re: [FFmpeg-devel] [PATCH] avformat/mpegts: make sure mpegts_read_header always stops at the first pmt

2020-11-15 Thread Ross Nicholson
On Sat, 14 Nov 2020 at 23:40, Marton Balint wrote: > mpegts_read_header stops parsing the file at the first PMT. However the > check > that ensured this was wrong because streams can also be added before the > first > PMT is received (e.g. EIT). > > So let's make sure we are in the header

[FFmpeg-devel] [PATCH] avformat/matroskadec: avoid warning on duration conversion

2020-11-15 Thread Steve Lhomme
Do the conversion from double to uint64_t explicitly and only once. The comparison to UINT64_MAX is not correct. --- libavformat/matroskadec.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/libavformat/matroskadec.c b/libavformat/matroskadec.c index 8a5bc4018a..4ff472005e

[FFmpeg-devel] [PATCH 2/2] avformat/matroskadec: adjust the cluster time to the track timebase

2020-11-15 Thread Steve Lhomme
The Block timestamp read in matroska_parse_block() is in track timebase and is passed on as such to the AVPacket which uses this timebase. In the normal case the Cluster and Track timebases are the same because the track->time_scale is 1.0. But when it is not the case, the values in Cluster

[FFmpeg-devel] [PATCH] avformat/matroskadec: only use the track duration if it exists

2020-11-15 Thread Steve Lhomme
No need to multiplying/dividing when we know it's zero. --- libavformat/matroskadec.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/libavformat/matroskadec.c b/libavformat/matroskadec.c index 4ff472005e..25b22afebe 100644 --- a/libavformat/matroskadec.c +++

[FFmpeg-devel] [PATCH] avformat/matroskadec: update the end timestamp when there is a timestamp

2020-11-15 Thread Steve Lhomme
No need to check if the cluster has a timestamp or not. If we found a timestamp for this block, then it's usable. This is actually the same condition to decide if we can use the timestamp or not. --- libavformat/matroskadec.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git

[FFmpeg-devel] [PATCH 1/2] avformat/matroskadec: add a warning when the track TimestampScale won't be used

2020-11-15 Thread Steve Lhomme
--- libavformat/matroskadec.c | 6 +- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/libavformat/matroskadec.c b/libavformat/matroskadec.c index 981e044263..ba0e2956df 100644 --- a/libavformat/matroskadec.c +++ b/libavformat/matroskadec.c @@ -2672,8 +2672,12 @@ static int

Re: [FFmpeg-devel] [PATCH] Support HDR10+ metadata for HEVC.

2020-11-15 Thread Andreas Rheinhardt
Mohammad Izadi: > From: Mohammad Izadi > > HDR10+ is dynamic metadata (A/341 Amendment - SMPTE2094-40) that needs to be > decoded from ITU-T T.35 in HEVC bitstream. The HDR10+ is transferred to side > data packet to be used or passed through. > > The fate test file can be found here: >