Optimizations:
by ffmpeg threading support implementation via frame slicing and moving
zimg_filter_graph_build to the filter initialization phase from each frame
processig
the performance increase vs original version
in video downscale and color conversion up to 4x is seen
on 64 cores Intel Xeon,
ons 2022-02-02 klockan 14:48 +0100 skrev Michael Niedermayer:
> On Tue, Feb 01, 2022 at 05:43:24PM +0100, Tomas Härdin wrote:
> > tis 2022-02-01 klockan 11:06 +0100 skrev Michael Niedermayer:
> > > On Mon, Jan 31, 2022 at 09:22:52PM +0100, Tomas Härdin wrote:
> > > [...]
> > > > It strikes me that
ons 2022-02-02 klockan 14:56 +0100 skrev Mark Gaiser:
> On Wed, Feb 2, 2022 at 2:21 PM Tomas Härdin
> wrote:
>
> > tis 2022-02-01 klockan 22:58 +0100 skrev Mark Gaiser:
> >
> > >
> > > +typedef struct Context {
> > > + AVClass *class;
> > > + URLContext *inner;
> > > + char *gateway;
>
On 1/31/2022 10:56 PM, James Almer wrote:
Should fix ticket #9622
Signed-off-by: James Almer
---
I'm not sure if this is ok or not. The AV_PKT_DATA_SKIP_SAMPLES doxy states
the skip samples value is a little endian uint32 value, so even if the mov
demuxer wrote a truncated int64_t value in sti-
On Fri, Feb 4, 2022 at 5:24 AM Wang Chuan wrote:
>
> Ping?
> On Jan 28, 2022, 11:24 AM +0800, Wang Chuan , wrote:
> > if we are reading udta in trak box, the data should go to metadata
> > of current stream.
> >
> > Signed-off-by: Wang Chuan
> > ---
> > libavformat/mov.c | 5 -
> > 1 file chan
tor 2022-02-03 klockan 18:29 +0100 skrev Mark Gaiser:
>
> +typedef struct IPFSGatewayContext {
> + AVClass *class;
> + URLContext *inner;
> + char *gateway;
Consider two separate variables. One for AVOption and one for the
dynamically allocated string. Or put the latter on the stack.
>
On Fri, Feb 4, 2022 at 12:10 PM Tomas Härdin wrote:
> tor 2022-02-03 klockan 18:29 +0100 skrev Mark Gaiser:
> >
> > +typedef struct IPFSGatewayContext {
> > +AVClass *class;
> > +URLContext *inner;
> > +char *gateway;
>
> Consider two separate variables. One for AVOption and one for t
On Fri, Feb 4, 2022 at 11:29 AM Tomas Härdin wrote:
> ons 2022-02-02 klockan 14:56 +0100 skrev Mark Gaiser:
> > On Wed, Feb 2, 2022 at 2:21 PM Tomas Härdin
> > wrote:
> >
> > > tis 2022-02-01 klockan 22:58 +0100 skrev Mark Gaiser:
> > >
> > > >
> > > > +typedef struct Context {
> > > > +AVCl
On Fri, Feb 04, 2022 at 04:29:18AM +0100, Andreas Rheinhardt wrote:
> Michael Niedermayer:
> > Fixes: Infinite loop
> > Fixes:
> > 43932/clusterfuzz-testcase-minimized-ffmpeg_dem_MATROSKA_fuzzer-6175167573786624
> >
> > Found-by: continuous fuzzing process
> > https://github.com/google/oss-fuzz/
Use -1 as the position in ff_cbs_insert_unit_data()
which implicitly reuses frag->nb_units as the counter.
Also switch to a do-while-loop, as it is more natural
than a for-loop now that the counter is gone.
Signed-off-by: Andreas Rheinhardt
---
libavcodec/cbs_mpeg2.c | 12 +---
1 file c
Use -1 as the position in ff_cbs_insert_unit_data()
which implicitly reuses frag->nb_units as the counter.
Also switch to a do-while-loop, as it is more natural
than a for-loop now that the counter is gone.
Signed-off-by: Andreas Rheinhardt
---
libavcodec/cbs_jpeg.c | 10 --
1 file chan
avpriv_find_start_code() supports non-contiguous buffers
by maintaining a state that allows to find start codes
that span across multiple buffers; a consequence thereof
is that avpriv_find_start_code() is given a zero-sized
buffer, it does not modify this state, so that it appears
as if a start cod
All split functions (the only users of this function) only
append units.
Signed-off-by: Andreas Rheinhardt
---
libavcodec/cbs.c | 22 +++---
libavcodec/cbs.h | 5 ++---
libavcodec/cbs_av1.c | 2 +-
libavcodec/cbs_h2645.c | 2 +-
libavcodec/cbs_jpeg.c | 2 +-
li
Signed-off-by: Andreas Rheinhardt
---
libavcodec/aac_adtstoasc_bsf.c | 1 -
libavcodec/aliaspixenc.c | 1 -
libavcodec/av1_parser.c| 1 -
libavcodec/avpacket.c | 6 ++
libavcodec/cbs_av1.c | 2 +-
libavcodec/cbs_vp9.c | 1 -
libavcodec/cljrenc.c
This is by definition the appropriate place for it.
Remove all the now unnecessary libavcodec/internal.h inclusions;
also remove other unnecessary headers from the affected files.
Signed-off-by: Andreas Rheinhardt
---
libavcodec/cavsdec.c | 1 +
libavcodec/cbs_mpeg2.c
Signed-off-by: Andreas Rheinhardt
---
libavcodec/cbs_mpeg2.c | 8
1 file changed, 4 insertions(+), 4 deletions(-)
diff --git a/libavcodec/cbs_mpeg2.c b/libavcodec/cbs_mpeg2.c
index 8d45d1ceeb..dfea12ef1b 100644
--- a/libavcodec/cbs_mpeg2.c
+++ b/libavcodec/cbs_mpeg2.c
@@ -144,10 +144,8
---
libavdevice/avfoundation.m | 10 ++
1 file changed, 6 insertions(+), 4 deletions(-)
diff --git a/libavdevice/avfoundation.m b/libavdevice/avfoundation.m
index 0cd6e646d5..2078c4879c 100644
--- a/libavdevice/avfoundation.m
+++ b/libavdevice/avfoundation.m
@@ -106,6 +106,7 @@ typedef st
---
libavdevice/avfoundation.m | 12 ++--
1 file changed, 10 insertions(+), 2 deletions(-)
diff --git a/libavdevice/avfoundation.m b/libavdevice/avfoundation.m
index 2078c4879c..8f5e2bd120 100644
--- a/libavdevice/avfoundation.m
+++ b/libavdevice/avfoundation.m
@@ -310,18 +310,21 @@ stati
Is moving all this code really needed?
Note that width/height can change between frames so that is supported
by scale filter.
With your change that is not more possible?
___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
https://ffmpeg.org/mailman/lis
On Thu, Feb 3, 2022 at 11:58 PM Paul B Mahol wrote:
>
> Never apply this.
I am not a maintainer and so cannot apply the patch.
There is another minor patch that has also been outstanding for some time now:
https://patchwork.ffmpeg.org/project/ffmpeg/list/?series=5700
> Very sorry state of proj
On 2/4/22 10:16, Andreas Rheinhardt wrote:
avpriv_find_start_code() supports non-contiguous buffers
by maintaining a state that allows to find start codes
that span across multiple buffers; a consequence thereof
is that avpriv_find_start_code() is given a zero-sized
buffer, it does not modify thi
On 2/4/22 10:16, Andreas Rheinhardt wrote:
This is by definition the appropriate place for it.
Remove all the now unnecessary libavcodec/internal.h inclusions;
also remove other unnecessary headers from the affected files.
Signed-off-by: Andreas Rheinhardt
---
diff --git a/libavcodec/utils.
From: Aman Karmani
fixes #6578
Signed-off-by: Aman Karmani
---
libavutil/arm/cpu.c | 17 ++---
1 file changed, 14 insertions(+), 3 deletions(-)
diff --git a/libavutil/arm/cpu.c b/libavutil/arm/cpu.c
index 81e85e2525..983e5a4d83 100644
--- a/libavutil/arm/cpu.c
+++ b/libavutil/arm/
On Fri, Feb 04, 2022 at 06:48:40 +, Soft Works wrote:
> > [two-part message removed for brevity]
>
> I've found out where the \{ and \} escaping has come from: libass
As already written in the commit-message of the first patch..
You already noticed your proposal only works with VSFilters,
bu
On Fri, Feb 04, 2022 at 02:30:37 +0100, Andreas Rheinhardt wrote:
> All text-based subtitles are supposed to be UTF-8 when they reach the
> decoder; if it isn't, the user has to set the appropriate -sub_charenc
> and -sub_charenc_mode.
>
> - Andreas
Thanks for the info! Then at least the UTF-8 as
On Fri, 4 Feb 2022, Aman Karmani wrote:
From: Aman Karmani
fixes #6578
Signed-off-by: Aman Karmani
---
libavutil/arm/cpu.c | 17 ++---
1 file changed, 14 insertions(+), 3 deletions(-)
It would be good if the commit message actually explained the upsides to
doing this.
It's al
> -Original Message-
> From: ffmpeg-devel On Behalf Of
> Oneric
> Sent: Friday, February 4, 2022 10:19 PM
> To: FFmpeg development discussions and patches de...@ffmpeg.org>
> Subject: Re: [FFmpeg-devel] [PATCH 1/2] avcodec/{ass, webvttdec}: fix
> handling of backslashes
>
> On Fri, Feb
After changes like ef13faf, the h264_metadata bitstream filter stopped
working when using the fixed_frame_rate_flag option on an input stream
that doesn't contain VUI because the default inferred value of
low_hrd_delay_flag seems to be 1. ffmpeg used to raise a warning, but
proceeded anyway but now
Rereading the spec, I think it only makes sense to update the
low_delay_hrd_flag parameter when the bitstream filter option for
fixed_frame_rate_flag is 1 to avoid clobbering the existing value in
other cases. I tried to work through all the scenarios below:
/ (BSF options) -> Resulting flags:
0/
> -Original Message-
> From: ffmpeg-devel On Behalf Of
> Oneric
> Sent: Friday, February 4, 2022 10:52 PM
> To: FFmpeg development discussions and patches de...@ffmpeg.org>
> Subject: Re: [FFmpeg-devel] [PATCH 1/2] avcodec/{ass, webvttdec}: fix
> handling of backslashes
>
> On Fri, Fe
On Fri, Feb 04, 2022 at 23:24:58 +, Soft Works wrote:
> You want to "pollute" gazillions of subtitle streams in the
> world from multiple subtitle formats with invisible
> characters in order to solve an escaping problem in ffmpeg?
I do not consider using characters that are explicitly recomme
Scott Theisen:
> This enhances the clarity of the code.
> ---
> libavcodec/cbs_mpeg2.c | 8 +++-
> 1 file changed, 3 insertions(+), 5 deletions(-)
>
> diff --git a/libavcodec/cbs_mpeg2.c b/libavcodec/cbs_mpeg2.c
> index d41477620e..afe78eef9a 100644
> --- a/libavcodec/cbs_mpeg2.c
> +++ b/liba
On 7/1/22 13:55, p...@sandflow.com wrote:
From: Pierre-Anthony Lemieux
Signed-off-by: Pierre-Anthony Lemieux
---
libavformat/tests/.gitignore | 1 +
1 file changed, 1 insertion(+)
diff --git a/libavformat/tests/.gitignore b/libavformat/tests/.gitignore
index 7ceb7a356b..aabf76345e 1006
On 4/2/22 17:58, Paul B Mahol wrote:
Never apply this. Very sorry state of project.
Iirc, there was some discussion on IRC about it. If you're okay with it, then
I'll apply it.
___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
https://ffmpeg.
From: Pierre-Anthony Lemieux
---
libavformat/tests/.gitignore | 1 +
1 file changed, 1 insertion(+)
diff --git a/libavformat/tests/.gitignore b/libavformat/tests/.gitignore
index 7ceb7a356b..aabf76345e 100644
--- a/libavformat/tests/.gitignore
+++ b/libavformat/tests/.gitignore
@@ -1,4 +1,5 @@
> -Original Message-
> From: ffmpeg-devel On Behalf Of
> Oneric
> Sent: Saturday, February 5, 2022 2:20 AM
> To: FFmpeg development discussions and patches de...@ffmpeg.org>
> Subject: Re: [FFmpeg-devel] [PATCH 1/2] avcodec/{ass, webvttdec}: fix
> handling of backslashes
>
> On Fri, Fe
On Fri, Feb 4, 2022 at 6:03 PM Zane van Iperen wrote:
>
>
>
>
> On 7/1/22 13:55, p...@sandflow.com wrote:
> > From: Pierre-Anthony Lemieux
> >
> > Signed-off-by: Pierre-Anthony Lemieux
> > ---
> > libavformat/tests/.gitignore | 1 +
> > 1 file changed, 1 insertion(+)
> >
> > diff --git a/liba
On 5/2/22 12:07, p...@sandflow.com wrote:
From: Pierre-Anthony Lemieux
---
libavformat/tests/.gitignore | 1 +
1 file changed, 1 insertion(+)
diff --git a/libavformat/tests/.gitignore b/libavformat/tests/.gitignore
index 7ceb7a356b..aabf76345e 100644
--- a/libavformat/tests/.gitignore
+
Scott Theisen:
> ff_cbs_insert_unit_data() does not modify the data or data_size fields of
> the CodedBitstreamFragment. It also does not modify the value pointed to
> by start. (We don't need that byte in this function anymore, anyway.)
> ---
> libavcodec/cbs_mpeg2.c | 26 +-
Scott Theisen:
> If the last four bytes form a valid start code, the loop would run another
> time.
> Since (start == buf_end), start_code is invalidated so the loop terminates.
>
> However, calling avpriv_find_start_code() with p == end, it will immediately
> return due to the zero size buffer.
On 21/1/22 03:45, Pierre-Anthony Lemieux wrote:
Hi all,
It was recently suggested that UUID functionality in the codebase
could be refactored into a single library.
Below is short explainer.
I would appreciate your review/feedback before I/we start writing code.
Best,
-- Pierre
I have
On Wed, Feb 02, 2022 at 03:45:10PM -0500, Patrick Keroulas wrote:
> In previous state, a new frame was allocated on each timestamp step,
> i.e. each frame/field transition. However, for interlace, a new frame
> should be allocated on 1st field, completed with the 2nd and finally
> freed.
>
> This
On 2/4/22 20:48, Andreas Rheinhardt wrote:
I disagree that this enhances clarity: When using a counter, a for loop
is the most natural.
The counter is not used as the loop condition, so it is not natural.
Also, you removed the counter and made this a do while loop in your own
patch series.
On 2/4/22 21:16, Andreas Rheinhardt wrote:
Using a pre-increment is unnatural (i is supposed to be the number of
units of the fragment and so it should naturally be incremented after a
unit has been successfully added to the fragment) and impairs clarity.
It *is* incremented after a unit has b
Scott Theisen:
> Separate from part 2 for a clearer diff.
>
> Now the true loop condition has been revealed: start < buf_end
>
> Clarify loop by moving the detection of sequence_end_codes out of the loop.
> See also commit fd93d5efe64206d5f1bce8c702602353444c0c1a regarding
> sequence_end_codes
>
On 2/4/22 21:24, Andreas Rheinhardt wrote:
end is now uninitialized in case of a unit consisting solely of a
Sequence End.
I hadn't noticed that. However, I immediately restored it in the next
patch.
___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpe
Scott Theisen:
> On 2/4/22 20:48, Andreas Rheinhardt wrote:
>> I disagree that this enhances clarity: When using a counter, a for loop
>> is the most natural.
>
> The counter is not used as the loop condition, so it is not natural.
> Also, you removed the counter and made this a do while loop in
On 2/4/22 23:06, Andreas Rheinhardt wrote:
Scott Theisen:
On 2/4/22 20:48, Andreas Rheinhardt wrote:
I disagree that this enhances clarity: When using a counter, a for loop
is the most natural.
The counter is not used as the loop condition, so it is not natural.
Also, you removed the counter a
On 2/4/22 22:54, Andreas Rheinhardt wrote:
I disagree that this is the true loop condition that just needs to be
revealed; in fact, this is basically the loop condition from before
fd93d5efe64206d5f1bce8c702602353444c0c1a, just with an added block to
deal with size one units at the end. I conside
From: Limin Wang
Signed-off-by: Limin Wang
---
libavformat/udp.c | 31 ---
1 file changed, 20 insertions(+), 11 deletions(-)
diff --git a/libavformat/udp.c b/libavformat/udp.c
index 83c042d..3dc79eb 100644
--- a/libavformat/udp.c
+++ b/libavformat/udp.c
@@ -162,22 +
From: Limin Wang
Suggested by zhilizhao, vlc project has solved the compatibility by
the same way, so I borrowed the comments from vlc project.
Fix #ticket9449
Signed-off-by: Limin Wang
---
libavformat/udp.c | 15 +--
1 file changed, 13 insertions(+), 2 deletions(-)
diff --git a/
From: Limin Wang
Signed-off-by: Limin Wang
---
libavformat/udp.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/libavformat/udp.c b/libavformat/udp.c
index 34488d6..0b078d4 100644
--- a/libavformat/udp.c
+++ b/libavformat/udp.c
@@ -175,7 +175,7 @@ static int udp_set_multica
Scott Theisen:
> ---
> libavcodec/cavsdec.c | 2 +-
> libavcodec/cbs_mpeg2.c | 4 ++--
> libavcodec/extract_extradata_bsf.c | 2 +-
> libavcodec/internal.h | 15 +++
> libavcodec/mpeg12.c| 2 +-
> libavcodec/mpeg12dec.c
Scott Theisen:
> Have the compiler enforce not changing the addresses these parameters point
> to.
>
> No functional change.
> ---
> libavcodec/internal.h | 6 +++---
> libavcodec/utils.c| 4 ++--
> 2 files changed, 5 insertions(+), 5 deletions(-)
>
> diff --git a/libavcodec/internal.h b/li
On 2/5/22 00:42, Andreas Rheinhardt wrote:
a) We use the avpriv prefix for things that should be exported from one
library to be used in other libraries, but not for public use. Therefore
the avpriv prefix is inappropriate here as this function is static. And
it makes a very long name.
So since
On 2/5/22 00:49, Andreas Rheinhardt wrote:
- * @param[in,out] start_code A reference to a mutable @c uint32_t.
+ * @param[in,out] start_code A constant pointer (reference) to a mutable @c
uint32_t.
There are no references in C.
A pointer is a type of reference. However, I agree "A pointer to
Scott Theisen:
> If true, this skips the for loop at the beginning of avpriv_find_start_code().
>
> If the state/start_code input is a local variable and only one buffer is used,
> then no history is needed.
>
> In loops and inline functions: if ignoring history, don't initialize
> start_code,
>
From: Aman Karmani
getauxval is faster, and works when procfs is not mounted
note that support on Android was added in 4.4 (API 20)
fixes #6578
Signed-off-by: Aman Karmani
---
configure | 1 +
libavutil/arm/cpu.c | 24 +---
2 files changed, 22 insertions(+), 3
On Fri, Feb 4, 2022 at 2:20 PM Martin Storsjö wrote:
> On Fri, 4 Feb 2022, Aman Karmani wrote:
>
> > From: Aman Karmani
> >
> > fixes #6578
> >
> > Signed-off-by: Aman Karmani
> > ---
> > libavutil/arm/cpu.c | 17 ++---
> > 1 file changed, 14 insertions(+), 3 deletions(-)
>
> It woul
Scott Theisen:
> No functional change.
> ---
> libavcodec/utils.c | 10 +++---
> 1 file changed, 7 insertions(+), 3 deletions(-)
>
> diff --git a/libavcodec/utils.c b/libavcodec/utils.c
> index b19befef21..cb4437edc2 100644
> --- a/libavcodec/utils.c
> +++ b/libavcodec/utils.c
> @@ -967,10 +9
It is constant, so instead of recalculating it every time, only
calculate it once.
Also add a few clarifying comments.
---
libavcodec/cbs_mpeg2.c | 14 +++---
1 file changed, 7 insertions(+), 7 deletions(-)
diff --git a/libavcodec/cbs_mpeg2.c b/libavcodec/cbs_mpeg2.c
index dfea12ef1b..d3
Andreas Rheinhardt:
> From: Anton Khirnov
>
> Many AVFifoBuffer users operate on fixed-size elements (e.g. pointers),
> but the current FIFO API deals exclusively in bytes, requiring extra
> complexity in all these callers.
>
> Add a new AVFifo API creating a FIFO with an element size
> that may
62 matches
Mail list logo