[FFmpeg-devel] Hardware acceleration decoding question

2019-05-23 Thread Asaf Kave
Hello all, I am using FFmpeg libarary in my software to do HW decoding for video (H.264\H.265) on windows machine. My decoding is based on 'hw_decode.c' example, and after i call decode a frame i am using AVFrame::data[3] to get the pointer to the IDirect3DSurface9 and use it in my video player.

Re: [FFmpeg-devel] [PATCH] avformat/rtsp: Add -first_rtcp_ntp_time_path option to write the first NTP time to a file.

2019-05-23 Thread Jonathan Viney
On Thu, May 23, 2019 at 7:14 PM Moritz Barsnick wrote: > On Thu, May 23, 2019 at 16:51:16 +1200, Jonathan Viney wrote: > > > The NTP time from the first RTCP packet is currently extracted in > > > libavformat/rtsp.c and stored in AVFormatContext.start_time_realtime. > > > However, there is no

Re: [FFmpeg-devel] [PATCH] avformat/rtsp: Add -first_rtcp_ntp_time_path option to write the first NTP time to a file.

2019-05-23 Thread Moritz Barsnick
On Thu, May 23, 2019 at 16:51:16 +1200, Jonathan Viney wrote: > > The NTP time from the first RTCP packet is currently extracted in > > libavformat/rtsp.c and stored in AVFormatContext.start_time_realtime. > > However, there is no way to access this value when using ffmpeg from the > >

Re: [FFmpeg-devel] [PATCHv4] VP4 video decoder

2019-05-23 Thread Peter Ross
On Tue, May 21, 2019 at 08:39:59PM +0200, Carl Eugen Hoyos wrote: > Am Di., 21. Mai 2019 um 19:18 Uhr schrieb Lynne : > > > > May 21, 2019, 8:44 AM by pr...@xvid.org : > > > > > --- > > > > > > what's changed: > > > * apply #if CONFIG_VP4_DECODER around large vp4 code blocks

Re: [FFmpeg-devel] [PATCHv4] VP4 video decoder

2019-05-23 Thread Lynne
May 23, 2019, 12:22 PM by pr...@xvid.org: > On Tue, May 21, 2019 at 08:39:59PM +0200, Carl Eugen Hoyos wrote: > >> Am Di., 21. Mai 2019 um 19:18 Uhr schrieb Lynne : >> > >> > May 21, 2019, 8:44 AM by pr...@xvid.org : >> > >> > > --- >> > > >> > > what's changed: >> > > *

Re: [FFmpeg-devel] [PATCHv4] VP4 video decoder

2019-05-23 Thread James Almer
On 5/23/2019 9:51 AM, Lynne wrote: > May 23, 2019, 12:22 PM by pr...@xvid.org: > >> On Tue, May 21, 2019 at 08:39:59PM +0200, Carl Eugen Hoyos wrote: >> >>> Am Di., 21. Mai 2019 um 19:18 Uhr schrieb Lynne : May 21, 2019, 8:44 AM by pr...@xvid.org : > ---

Re: [FFmpeg-devel] [PATCHv4] VP4 video decoder

2019-05-23 Thread Peter Ross
On Tue, May 21, 2019 at 11:34:34AM +0200, Tomas Härdin wrote: > tis 2019-05-21 klockan 17:44 +1000 skrev Peter Ross: > > --- > > > > what's changed: > > * apply #if CONFIG_VP4_DECODER around large vp4 code blocks > > * improved vp4_read_mb_value thanks to reminars suggestions > > * improved

Re: [FFmpeg-devel] [PATCH] libavcodec/vp9: fix ref-frame size judging method

2019-05-23 Thread Ronald S. Bultje
Hi guys, On Wed, May 22, 2019 at 11:14 PM 严小复 wrote: > code”, I'm little confused about the red word,would you mean encode process > need validity checks or there need to check the reference id of each frame? > > And this patch will act on decode process, all references have already been >

Re: [FFmpeg-devel] [PATCH V2] avfilter/vf_unsharp: enable slice threading

2019-05-23 Thread Song, Ruiling
> -Original Message- > From: Song, Ruiling > Sent: Thursday, May 16, 2019 5:48 PM > To: ffmpeg-devel@ffmpeg.org > Cc: Song, Ruiling > Subject: [PATCH V2] avfilter/vf_unsharp: enable slice threading > > benchmarking with a simple command: > ffmpeg -i 1080p.mp4 -vf unsharp=la=3:ca=3 -an -f

Re: [FFmpeg-devel] [PATCHv4] VP4 video decoder

2019-05-23 Thread Peter Ross
On Tue, May 21, 2019 at 08:42:17PM +0200, Carl Eugen Hoyos wrote: > Am Di., 21. Mai 2019 um 09:45 Uhr schrieb Peter Ross : > > > diff --git a/configure b/configure > > index 9b4305cf0d..61eb774116 100755 > > --- a/configure > > +++ b/configure > > @@ -2825,6 +2825,7 @@

Re: [FFmpeg-devel] [PATCHv4] VP4 video decoder

2019-05-23 Thread Peter Ross
On Tue, May 21, 2019 at 08:38:02PM +0200, Reimar Döffinger wrote: > On Tue, May 21, 2019 at 11:15:03AM -0300, James Almer wrote: > > > I have a feeling this loop should have a stop condition like v < > > > SOME_LARGE_VALUE, say INT_MAX-255 or yuv_macroblock_count, to reject > > > corrupt/malicious

Re: [FFmpeg-devel] [PATCHv4] VP4 video decoder

2019-05-23 Thread Peter Ross
On Tue, May 21, 2019 at 09:30:54PM +0200, Reimar Döffinger wrote: > On Tue, May 21, 2019 at 05:44:20PM +1000, Peter Ross wrote: > > +if (bits < 0x100) { > > +skip_bits(gb, 1); > > +} else if (bits < 0x180) { > > +skip_bits(gb, 2); > > +v += 1; > > +} > >

Re: [FFmpeg-devel] [PATCHv4] VP4 video decoder

2019-05-23 Thread Peter Ross
On Wed, May 22, 2019 at 09:45:46PM +0200, Reimar Döffinger wrote: > On Tue, May 21, 2019 at 09:30:54PM +0200, Reimar Döffinger wrote: > > > +#define SHIFT(v, shift) ((v) >> (shift)) > > > +#define ABS_SHIFT(v, shift) ((v) > 0 ? SHIFT(v, shift) : -SHIFT(-v, > > > shift)) > > > > Don't we have

Re: [FFmpeg-devel] [PATCH] avformat/segment: populate empty outer stream extradata from packet

2019-05-23 Thread Gyan
On 21-05-2019 06:59 PM, Gyan wrote: Fixes playback in QT for me. Gyan 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] [PATCH 2/2] avformat/mpjpegdec: fix strict boundary search string

2019-05-23 Thread Moritz Barsnick
According to RFC1341, the multipart boundary indicated by the Content-Type header must be prepended by CRLF + "--", and followed by CRLF. In the case of strict MIME header boundary handling, the "--" was forgotten to add. Fixes trac #7921. Signed-off-by: Moritz Barsnick ---

[FFmpeg-devel] [PATCH 1/2] avformat/mpjpegdec: fix finding multipart boundary parameter

2019-05-23 Thread Moritz Barsnick
The string matching function's return value was evaluated incorrectly. Fixes trac #7920. Signed-off-by: Moritz Barsnick --- libavformat/mpjpegdec.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libavformat/mpjpegdec.c b/libavformat/mpjpegdec.c index e653b5cc93..a23469c0ec

Re: [FFmpeg-devel] [PATCH] avformat/cache - delete cache file after closing handle

2019-05-23 Thread Gyan
On 23-05-2019 09:13 PM, Michael Niedermayer wrote: On Wed, May 22, 2019 at 09:06:11PM +0530, Gyan wrote: On 22-05-2019 06:37 PM, Nicolas George wrote: Gyan (12019-05-22): The existing practice of unlinking path immediately after acquiring file handle was returning (unchecked) EPERM error

Re: [FFmpeg-devel] [FFMPEG DEVEL] [PATCH v5] fftools/ffprobe: Add S12M Timecode output as side data (such as SEI TC)

2019-05-23 Thread Marton Balint
On Wed, 22 May 2019, Antonin Gouzer wrote: --- Change structure to conserve one SEI data=one side data with multiple timecode elements Thanks for the changes, patch is looking good except for some minor issues. However, you need to extend doc/ffprobe.xsd to support the changed XML

Re: [FFmpeg-devel] [PATCH] avcodec/decode: Do not output subtitle frames if the packet is marked with `AV_PKT_FLAG_DISCARD`.

2019-05-23 Thread Derek Buitenhuis
On 22/05/2019 18:55, Darren Mo wrote: > Good question. The subtitle would be discarded if it overlaps an edit > boundary. > > The root cause is the MOV demuxer currently marks boundary packets for > discard. However, due to subtitle frames not being discarded (fixed by this > patch), the root

Re: [FFmpeg-devel] [PATCH] avformat/cache - delete cache file after closing handle

2019-05-23 Thread Nicolas George
Gyan (12019-05-24): > avpriv_io_delete will call the file protocol's delete which is guarded > with a header check, not done here. Do you have report of a build failure caused by unlink()? > Since we now have a generic wrapper function, isn't that better for > future maintenance? Not that I

Re: [FFmpeg-devel] [PATCH] avfilter/f_loop: do not loop if loop size is 0

2019-05-23 Thread Marton Balint
On Wed, 22 May 2019, Alexander Strasser wrote: Hi! On 2019-05-20 20:51 +0200, Marton Balint wrote: On Mon, 20 May 2019, Gyan wrote: > On 20-05-2019 02:18 AM, Marton Balint wrote: > > > > On Sun, 19 May 2019, Paul B Mahol wrote: > > > > > On 5/19/19, Marton Balint wrote: > > > > > > > >

Re: [FFmpeg-devel] [PATCH] avformat/cache - delete cache file after closing handle

2019-05-23 Thread Gyan
On 23-05-2019 11:20 PM, Nicolas George wrote: Gyan (12019-05-23): -unlink(buffername); -av_freep(); +ret = avpriv_io_delete(buffername); Is there a reason you replace unlink() with avpriv_io_delete()? unlink() is more direct, and cache does not support non-file cache.

Re: [FFmpeg-devel] [PATCH] avformat/cache - delete cache file after closing handle

2019-05-23 Thread Michael Niedermayer
On Wed, May 22, 2019 at 09:06:11PM +0530, Gyan wrote: > > > On 22-05-2019 06:37 PM, Nicolas George wrote: > >Gyan (12019-05-22): > >>The existing practice of unlinking path immediately after acquiring file > >>handle was returning (unchecked) EPERM error on Windows. Switched to > >>deletion

[FFmpeg-devel] [PATCH 0/2] avformat/mpjpegdec: fixes for strict MIME boundary checking

2019-05-23 Thread Moritz Barsnick
The mpjpegdec option "-strict_mime_boundary 1" didn't actually work with streams strictly adhering to RFC1341. Moritz Barsnick (2): avformat/mpjpegdec: fix finding multipart boundary parameter avformat/mpjpegdec: fix strict boundary search string libavformat/mpjpegdec.c | 6 +++--- 1 file

Re: [FFmpeg-devel] [PATCH] avformat/cache - delete cache file after closing handle

2019-05-23 Thread Nicolas George
Gyan (12019-05-23): > -unlink(buffername); > -av_freep(); > +ret = avpriv_io_delete(buffername); Is there a reason you replace unlink() with avpriv_io_delete()? unlink() is more direct, and cache does not support non-file cache. Regards, -- Nicolas George signature.asc

Re: [FFmpeg-devel] [PATCH] avformat/utils: fix stream ordering for program ID stream specifiers

2019-05-23 Thread Marton Balint
On Sun, 19 May 2019, Marton Balint wrote: Fixes a regression introduced in dbfd042983eed8586d4048795c00af820f5b6b1f. Will apply soon. Thanks, Marton Signed-off-by: Marton Balint --- doc/fftools-common-opts.texi | 5 - libavformat/utils.c | 16 +++- 2 files

Re: [FFmpeg-devel] [PATCH] avformat/movenc: use unspecified language by default

2019-05-23 Thread James Almer
On 5/23/2019 4:32 PM, Marton Balint wrote: > > > On Mon, 20 May 2019, Carl Eugen Hoyos wrote: > >> Am So., 19. Mai 2019 um 20:10 Uhr schrieb Marton Balint : >> >>> English was used before. >> >> A version bump is necessary. >> >> I would also like a Changelog entry, most people prefer an entry

Re: [FFmpeg-devel] [PATCH 1/2] avcodec/scpr: fix checking ret value of decode_run_i

2019-05-23 Thread Paul B Mahol
On 5/23/19, Marton Balint wrote: > Fixes Coverity CID 1441460. > > Signed-off-by: Marton Balint > --- > libavcodec/scpr.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/libavcodec/scpr.c b/libavcodec/scpr.c > index 10fc994ecf..317950dafb 100644 > ---

Re: [FFmpeg-devel] [PATCH] avcodec/ffv1dec_template: Optimize common case in run mode

2019-05-23 Thread Michael Niedermayer
On Thu, May 23, 2019 at 10:57:14AM +0200, Carl Eugen Hoyos wrote: > Am Do., 23. Mai 2019 um 01:47 Uhr schrieb Michael Niedermayer > : > > > > Fixes: Timeout (14sec -> 9sec) > > Fixes: > > 13398/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_FFV1_fuzzer-5664106709778432 > > > > Found-by:

[FFmpeg-devel] [PATCH] lavfi/vf_scale_cuda: Add format option

2019-05-23 Thread Josh Allmann
Makes certain usages of the lavfi API easier. --- libavfilter/vf_scale_cuda.c | 12 +++- 1 file changed, 11 insertions(+), 1 deletion(-) diff --git a/libavfilter/vf_scale_cuda.c b/libavfilter/vf_scale_cuda.c index b7cdb81081..6b1ef2bb6f 100644 --- a/libavfilter/vf_scale_cuda.c +++

Re: [FFmpeg-devel] [PATCH] avformat/movenc: use unspecified language by default

2019-05-23 Thread Marton Balint
On Mon, 20 May 2019, Carl Eugen Hoyos wrote: Am So., 19. Mai 2019 um 20:10 Uhr schrieb Marton Balint : English was used before. A version bump is necessary. I would also like a Changelog entry, most people prefer an entry to apichanges though. I can do both. Do people prefer to delay

Re: [FFmpeg-devel] [PATCH] avfilter/f_loop: do not loop if loop size is 0

2019-05-23 Thread Paul B Mahol
On 5/23/19, Marton Balint wrote: > > > On Wed, 22 May 2019, Alexander Strasser wrote: > >> Hi! >> >> On 2019-05-20 20:51 +0200, Marton Balint wrote: >>> >>> On Mon, 20 May 2019, Gyan wrote: >>> >>> > On 20-05-2019 02:18 AM, Marton Balint wrote: >>> > > >>> > > On Sun, 19 May 2019, Paul B Mahol

Re: [FFmpeg-devel] [PATCH] avformat/cache - delete cache file after closing handle

2019-05-23 Thread Gyan
On 24-05-2019 12:58 AM, Nicolas George wrote: Gyan (12019-05-24): avpriv_io_delete will call the file protocol's delete which is guarded with a header check, not done here. Do you have report of a build failure caused by unlink()? No.  I assume that the guard in the file proto callback is

Re: [FFmpeg-devel] [PATCH] avcodec/decode: Do not output subtitle frames if the packet is marked with `AV_PKT_FLAG_DISCARD`.

2019-05-23 Thread Darren Mo
To clarify, do you mean we should merge this now or wait for the second patch, which fixes the root cause? > On May 23, 2019, at 10:12 AM, Derek Buitenhuis > wrote: > >> On 22/05/2019 18:55, Darren Mo wrote: >> Good question. The subtitle would be discarded if it overlaps an edit >>

[FFmpeg-devel] [PATCH 2/2] avcodec/scpr3: fix checking ret value of decode_run_i

2019-05-23 Thread Marton Balint
Fixes Coverity CID 1441461. Signed-off-by: Marton Balint --- libavcodec/scpr3.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libavcodec/scpr3.c b/libavcodec/scpr3.c index 5cfad9f4d2..b4d2e21a17 100644 --- a/libavcodec/scpr3.c +++ b/libavcodec/scpr3.c @@ -1007,7 +1007,7 @@

[FFmpeg-devel] [PATCH 1/2] avcodec/scpr: fix checking ret value of decode_run_i

2019-05-23 Thread Marton Balint
Fixes Coverity CID 1441460. Signed-off-by: Marton Balint --- libavcodec/scpr.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libavcodec/scpr.c b/libavcodec/scpr.c index 10fc994ecf..317950dafb 100644 --- a/libavcodec/scpr.c +++ b/libavcodec/scpr.c @@ -359,7 +359,7 @@ static

[FFmpeg-devel] [PATCH 1/2] avfilter/f_loop: fix video loop issues with 0 size or when size is bigger than input

2019-05-23 Thread Marton Balint
Fixes infinte loop with -vf loop=loop=1 and also fixes looping when the input is less frames than the specified loop size. Possible regressions since ef1aadffc785b48ed62c45d954289e754f43ef46. Signed-off-by: Marton Balint --- libavfilter/f_loop.c | 8 +--- 1 file changed, 5 insertions(+), 3

[FFmpeg-devel] [PATCH 2/2] avfilter/f_loop: warn about unset loop sizes

2019-05-23 Thread Marton Balint
Signed-off-by: Marton Balint --- libavfilter/f_loop.c | 13 + 1 file changed, 13 insertions(+) diff --git a/libavfilter/f_loop.c b/libavfilter/f_loop.c index fcbd742eb4..5ec44d9da2 100644 --- a/libavfilter/f_loop.c +++ b/libavfilter/f_loop.c @@ -55,6 +55,15 @@ typedef struct

Re: [FFmpeg-devel] [PATCH] avformat/cache - delete cache file after closing handle

2019-05-23 Thread Hendrik Leppkes
On Thu, May 23, 2019 at 9:55 PM Gyan wrote: > > > > On 24-05-2019 12:58 AM, Nicolas George wrote: > > Gyan (12019-05-24): > >> avpriv_io_delete will call the file protocol's delete which is guarded > >> with a header check, not done here. > > Do you have report of a build failure caused by

Re: [FFmpeg-devel] [PATCH 2/2] avcodec/scpr3: fix checking ret value of decode_run_i

2019-05-23 Thread Paul B Mahol
On 5/23/19, Marton Balint wrote: > Fixes Coverity CID 1441461. > > Signed-off-by: Marton Balint > --- > libavcodec/scpr3.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/libavcodec/scpr3.c b/libavcodec/scpr3.c > index 5cfad9f4d2..b4d2e21a17 100644 > ---

Re: [FFmpeg-devel] [PATCH] avfilter/f_loop: do not loop if loop size is 0

2019-05-23 Thread Marton Balint
On Thu, 23 May 2019, Paul B Mahol wrote: On 5/23/19, Marton Balint wrote: On Wed, 22 May 2019, Alexander Strasser wrote: Hi! On 2019-05-20 20:51 +0200, Marton Balint wrote: On Mon, 20 May 2019, Gyan wrote: > On 20-05-2019 02:18 AM, Marton Balint wrote: > > > > On Sun, 19 May 2019,

[FFmpeg-devel] [PATCH] avcodec/h264_parse: Use 64bit for expectedpoc

2019-05-23 Thread Michael Niedermayer
Fixes: signed integer overflow: -2142516591 + -267814575 cannot be represented in type 'int' Fixes: 14450/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_H264_fuzzer-5716105319940096 Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg

Re: [FFmpeg-devel] [PATCH] avformat/cache - delete cache file after closing handle

2019-05-23 Thread Gyan
On 24-05-2019 02:06 AM, Hendrik Leppkes wrote: On Thu, May 23, 2019 at 9:55 PM Gyan wrote: On 24-05-2019 12:58 AM, Nicolas George wrote: Gyan (12019-05-24): avpriv_io_delete will call the file protocol's delete which is guarded with a header check, not done here. Do you have report of a

[FFmpeg-devel] [PATCH V1] doc/encoders: Document eld_v2 option for libfdk_aac encoder.

2019-05-23 Thread Jun Zhao
From: Jun Zhao Document eld_v2 option for libfdk_aac encoder. Signed-off-by: Jun Zhao --- doc/encoders.texi |6 ++ 1 files changed, 6 insertions(+), 0 deletions(-) diff --git a/doc/encoders.texi b/doc/encoders.texi index ef12c73..e0e 100644 --- a/doc/encoders.texi +++

[FFmpeg-devel] [PATCH] avcodec/mips: [loongson] fix mpeg4 decoding error on loongson platform.

2019-05-23 Thread Shiyou Yin
In function ff_dct_unquantize_mpeg2_intra_mmi, addr0 shoudn't be changed before storage operation. --- libavcodec/mips/mpegvideo_mmi.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libavcodec/mips/mpegvideo_mmi.c b/libavcodec/mips/mpegvideo_mmi.c index 18058e4..e4aba08

Re: [FFmpeg-devel] Hardware acceleration decoding question

2019-05-23 Thread Asaf Kave
Thanks Timo for the reply , no it's clear to me, and sorry for the question location i made. On Thu, May 23, 2019 at 12:29 PM Timo Rothenpieler wrote: > On 23.05.2019 10:06, Asaf Kave wrote: > > Hello all, > > I am using FFmpeg libarary in my software to do HW decoding for video > >

Re: [FFmpeg-devel] [PATCH] avcodec/ffv1dec_template: Optimize common case in run mode

2019-05-23 Thread Carl Eugen Hoyos
Am Do., 23. Mai 2019 um 01:47 Uhr schrieb Michael Niedermayer : > > Fixes: Timeout (14sec -> 9sec) > Fixes: > 13398/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_FFV1_fuzzer-5664106709778432 > > Found-by: continuous fuzzing process >

Re: [FFmpeg-devel] Hardware acceleration decoding question

2019-05-23 Thread Timo Rothenpieler
On 23.05.2019 10:06, Asaf Kave wrote: Hello all, I am using FFmpeg libarary in my software to do HW decoding for video (H.264\H.265) on windows machine. My decoding is based on 'hw_decode.c' example, and after i call decode a frame i am using AVFrame::data[3] to get the pointer to the