Re: [FFmpeg-devel] Patch for seg fault in swr_convert_internal() -> sum2_float during dithering
> On Apr 7, 2018, at 02:07, Michael Niedermayer wrote: > > On Thu, Apr 05, 2018 at 02:38:03PM +0200, Hendrik Schreiber wrote: > > will apply > > thanks Great. Much appreciated. -hendrik ___ ffmpeg-devel mailing list ffmpeg-devel@ffmpeg.org http://ffmpeg.org/mailman/listinfo/ffmpeg-devel
Re: [FFmpeg-devel] lavfi/silencedetect v3
On 4/7/18, James Almer wrote: > On 4/1/2018 8:26 AM, Paul B Mahol wrote: >> On 3/5/18, Gaullier Nicolas wrote: >>> Hello, >>> I have not received any comment yet on my patchset v3 ("add mono mode" >>> new >>> feature + 4 fixes including a ticket), does it look good to you, could it >>> be >>> committed ? >>> >>> http://ffmpeg.org/pipermail/ffmpeg-devel/2018-February/225494.html >>> http://ffmpeg.org/pipermail/ffmpeg-devel/2018-February/225495.html >>> http://ffmpeg.org/pipermail/ffmpeg-devel/2018-February/225496.html >>> http://ffmpeg.org/pipermail/ffmpeg-devel/2018-February/225497.html >>> http://ffmpeg.org/pipermail/ffmpeg-devel/2018-February/225498.html >>> http://ffmpeg.org/pipermail/ffmpeg-devel/2018-February/225499.html >>> http://ffmpeg.org/pipermail/ffmpeg-devel/2018-February/225500.html >>> http://ffmpeg.org/pipermail/ffmpeg-devel/2018-February/225501.html >>> >>> Thanks, >>> Nicolas Gaullier >> >> I applied all except last two. > > This broke the fate in a couple targets, like msvc 2017 and kfreebsd. > Tests like this shouldn't try to print float values... Disable such tests? ___ ffmpeg-devel mailing list ffmpeg-devel@ffmpeg.org http://ffmpeg.org/mailman/listinfo/ffmpeg-devel
[FFmpeg-devel] [PATCH] gitattributes - force LF for some FATE srt and webvtt refs
Please first read the commit msg below, which is, I hope, self-explanatory, but I want to note a few things. When searching to see how this issue was addressed in the past, I saw the recommendation was to set git global autocrlf to false. That's inadvisable because it affects checkout/clones of all other repos that the Windows user has. Setting repo local autocrlf to false is preferable but any local edits with CRLF will be merged unchanged. So the safe alternative to this patch is to set local autocrlf to input for Windows users and document that clearly in both Git How-to and ffmpeg-web.git/src/download. gitattributes will have to track any deliberate CRLF files. Regards, Gyan From e273754f53f2ad937e2ea05304dd554747fdc792 Mon Sep 17 00:00:00 2001 From: Gyan Doshi Date: Sat, 7 Apr 2018 13:31:55 +0530 Subject: [PATCH] gitattributes - force LF for some FATE srt and webvtt refs The SRT and WebVTT muxers only write out LF line endings. On Windows, the refs for a few related FATE tests are checked out, by default, as CRLF, causing these tests to fail. Patch forces these files to be checked out as LF. --- .gitattributes | 4 1 file changed, 4 insertions(+) diff --git a/.gitattributes b/.gitattributes index 5a19b963b6..59e20ffc92 100644 --- a/.gitattributes +++ b/.gitattributes @@ -1,2 +1,6 @@ *.pnm -diff -text tests/ref/fate/sub-scc eol=crlf +tests/ref/fate/sub-srt-empty-events eol=lf +tests/ref/fate/sub-srt-madness-timeshift eol=lf +tests/ref/fate/sub-srt-rrn-remux eol=lf +tests/ref/fate/sub-webvttenc eol=lf -- 2.12.2.windows.2___ ffmpeg-devel mailing list ffmpeg-devel@ffmpeg.org http://ffmpeg.org/mailman/listinfo/ffmpeg-devel
Re: [FFmpeg-devel] [PATCH] avformat/rawenc: check stream type
2018-04-04 12:23 GMT+02:00, Gyan Doshi : > Validate codec of stream to be muxed except for data muxer. What issue does your patch fix? Carl Eugen ___ ffmpeg-devel mailing list ffmpeg-devel@ffmpeg.org http://ffmpeg.org/mailman/listinfo/ffmpeg-devel
Re: [FFmpeg-devel] [PATCH] avformat/rawenc: check stream type
On 4/7/2018 4:35 PM, Carl Eugen Hoyos wrote: 2018-04-04 12:23 GMT+02:00, Gyan Doshi : Validate codec of stream to be muxed except for data muxer. What issue does your patch fix? Had an user on SE sometime back extract a video stream to a .h264 (in order to retime PTS). The retiming didn't work since the stream was actually mpeg4 but the muxer hasn't complained. Might have been fine but ffmpeg's format probe settled on h264 so user couldn't proceed until we examined the source. So just added some basic checks. Initially strict but loosened due to Michael's feedback. Users can still use data or rawvideo muxer to extract any random stream. (I do see that rawvideo does not enforce a single stream. Why?) Regards, Gyan ___ ffmpeg-devel mailing list ffmpeg-devel@ffmpeg.org http://ffmpeg.org/mailman/listinfo/ffmpeg-devel
[FFmpeg-devel] Add IRC nicknames to MAINTAINERS?
Hi It's come up a couple of times that IRC nicknames would be useful. I at least tend to answer IRC much more quickly than email. Something like patch attached maybe? /TomasFrom 03225dda47c73c3323c3276353d0ac896123cd3f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Tomas=20H=C3=A4rdin?= Date: Sat, 7 Apr 2018 12:18:00 +0200 Subject: [PATCH] Add IRC nicknames --- MAINTAINERS | 8 +--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/MAINTAINERS b/MAINTAINERS index 3c54ad6781..e94e07641f 100644 --- a/MAINTAINERS +++ b/MAINTAINERS @@ -574,8 +574,10 @@ Releases If you want to maintain an older release, please contact us -GnuPG Fingerprints of maintainers and contributors -== +GnuPG Fingerprints and IRC nicknames of maintainers and contributors + + +Nicknames apply to #ffmpeg and #ffmpeg-devel @ irc.freenode.net Alexander Strasser1C96 78B7 83CB 8AA7 9AF5 D1EB A7D8 A57B A876 E58F Anssi Hannula 1A92 FF42 2DD9 8D2E 8AF7 65A9 4278 C520 513D F3CB @@ -610,5 +612,5 @@ Steinar H. Gunderson C2E9 004F F028 C18E 4EAD DB83 7F61 7561 7797 8F76 Stephan Hilb 4F38 0B3A 5F39 B99B F505 E562 8D5C 5554 4E17 8863 Tiancheng "Timothy" Gu9456 AFC0 814A 8139 E994 8351 7FE6 B095 B582 B0D4 Tim Nicholson 38CF DB09 3ED0 F607 8B67 6CED 0C0B FC44 8B0B FC83 -Tomas Härdin A79D 4E3D F38F 763F 91F5 8B33 A01E 8AE0 41BB 2551 +Tomas Härdin A79D 4E3D F38F 763F 91F5 8B33 A01E 8AE0 41BB 2551 thardin Wei Gao 4269 7741 857A 0E60 9EC5 08D2 4744 4EFA 62C1 87B9 -- 2.11.0 ___ ffmpeg-devel mailing list ffmpeg-devel@ffmpeg.org http://ffmpeg.org/mailman/listinfo/ffmpeg-devel
Re: [FFmpeg-devel] Add IRC nicknames to MAINTAINERS?
On 4/7/2018 9:08 AM, Tomas Härdin wrote: > Hi > > It's come up a couple of times that IRC nicknames would be useful. I at > least tend to answer IRC much more quickly than email. Something like > patch attached maybe? > > /Tomas > > > 0001-Add-IRC-nicknames.patch > > > From 03225dda47c73c3323c3276353d0ac896123cd3f Mon Sep 17 00:00:00 2001 > From: =?UTF-8?q?Tomas=20H=C3=A4rdin?= > Date: Sat, 7 Apr 2018 12:18:00 +0200 > Subject: [PATCH] Add IRC nicknames > > --- > MAINTAINERS | 8 +--- > 1 file changed, 5 insertions(+), 3 deletions(-) > > diff --git a/MAINTAINERS b/MAINTAINERS > index 3c54ad6781..e94e07641f 100644 > --- a/MAINTAINERS > +++ b/MAINTAINERS > @@ -574,8 +574,10 @@ Releases > If you want to maintain an older release, please contact us > > > -GnuPG Fingerprints of maintainers and contributors > -== > +GnuPG Fingerprints and IRC nicknames of maintainers and contributors > + > + > +Nicknames apply to #ffmpeg and #ffmpeg-devel @ irc.freenode.net > > Alexander Strasser1C96 78B7 83CB 8AA7 9AF5 D1EB A7D8 A57B A876 > E58F > Anssi Hannula 1A92 FF42 2DD9 8D2E 8AF7 65A9 4278 C520 513D > F3CB > @@ -610,5 +612,5 @@ Steinar H. Gunderson C2E9 004F F028 C18E 4EAD > DB83 7F61 7561 7797 8F76 > Stephan Hilb 4F38 0B3A 5F39 B99B F505 E562 8D5C 5554 4E17 > 8863 > Tiancheng "Timothy" Gu9456 AFC0 814A 8139 E994 8351 7FE6 B095 B582 > B0D4 > Tim Nicholson 38CF DB09 3ED0 F607 8B67 6CED 0C0B FC44 8B0B > FC83 > -Tomas Härdin A79D 4E3D F38F 763F 91F5 8B33 A01E 8AE0 41BB > 2551 > +Tomas Härdin A79D 4E3D F38F 763F 91F5 8B33 A01E 8AE0 41BB > 2551 thardin Real Name (nick) FINGERPRINT Would look better, IMO. > Wei Gao 4269 7741 857A 0E60 9EC5 08D2 4744 4EFA 62C1 > 87B9 > -- 2.11.0 > > > > ___ > ffmpeg-devel mailing list > ffmpeg-devel@ffmpeg.org > http://ffmpeg.org/mailman/listinfo/ffmpeg-devel > ___ ffmpeg-devel mailing list ffmpeg-devel@ffmpeg.org http://ffmpeg.org/mailman/listinfo/ffmpeg-devel
Re: [FFmpeg-devel] [PATCH] libavcodec/rv34: error out earlier on missing references
On Mon, Apr 02, 2018 at 11:24:59PM +0200, Michael Niedermayer wrote: > Fixes visual corruption on seeking > > Fixes: downloadTest_clip_24M.rmvb > > Signed-off-by: Michael Niedermayer > --- > libavcodec/rv34.c | 6 +++--- > 1 file changed, 3 insertions(+), 3 deletions(-) will apply [...] -- Michael GnuPG fingerprint: 9FF2128B147EF6730BADF133611EC787040B0FAB Many things microsoft did are stupid, but not doing something just because microsoft did it is even more stupid. If everything ms did were stupid they would be bankrupt already. signature.asc Description: PGP signature ___ ffmpeg-devel mailing list ffmpeg-devel@ffmpeg.org http://ffmpeg.org/mailman/listinfo/ffmpeg-devel
Re: [FFmpeg-devel] [PATCH] avformat/rawenc: check stream type
2018-04-07 13:32 GMT+02:00, Gyan Doshi : > On 4/7/2018 4:35 PM, Carl Eugen Hoyos wrote: >> 2018-04-04 12:23 GMT+02:00, Gyan Doshi : >>> Validate codec of stream to be muxed except for data muxer. >> >> What issue does your patch fix? > > Had an user on SE sometime back extract a video stream to a .h264 (in > order to retime PTS). Does this work at all? > The retiming didn't work since the stream was > actually mpeg4 but the muxer hasn't complained. Might have been fine but > ffmpeg's format probe settled on h264 so user couldn't proceed until we > examined the source. A warning would be sufficient. Carl Eugen ___ ffmpeg-devel mailing list ffmpeg-devel@ffmpeg.org http://ffmpeg.org/mailman/listinfo/ffmpeg-devel
[FFmpeg-devel] [PATCH]lavc/clearvideo: Allow decoding without extradata
Hi! Attached patch fixes (initial) playback for the files in http://samples.ffmpeg.org/V-codecs/UCOD/noextradata/ - kindly provided by Piotr. Please comment, Carl Eugen From 6fb8df8d4750e66d62eb75ed57ea56463c4ebd38 Mon Sep 17 00:00:00 2001 From: Carl Eugen Hoyos Date: Sat, 7 Apr 2018 21:30:45 +0200 Subject: [PATCH] lavc/clearvideo: Allow decoding without extradata. --- libavcodec/clearvideo.c |2 ++ 1 file changed, 2 insertions(+) diff --git a/libavcodec/clearvideo.c b/libavcodec/clearvideo.c index 9319cac..6061cb5 100644 --- a/libavcodec/clearvideo.c +++ b/libavcodec/clearvideo.c @@ -652,6 +652,8 @@ static av_cold int clv_decode_init(AVCodecContext *avctx) c->tile_size = AV_RL32(&avctx->extradata[94]); } else if (avctx->extradata_size == 150) { c->tile_size = AV_RB32(&avctx->extradata[134]); +} else if (!avctx->extradata_size) { +c->tile_size = 16; } else { av_log(avctx, AV_LOG_ERROR, "Unsupported extradata size: %d\n", avctx->extradata_size); return AVERROR_INVALIDDATA; -- 1.7.10.4 ___ ffmpeg-devel mailing list ffmpeg-devel@ffmpeg.org http://ffmpeg.org/mailman/listinfo/ffmpeg-devel
Re: [FFmpeg-devel] [PATCH]lavc/clearvideo: Allow decoding without extradata
On 4/7/18, Carl Eugen Hoyos wrote: > Hi! > > Attached patch fixes (initial) playback for the files in > http://samples.ffmpeg.org/V-codecs/UCOD/noextradata/ > - kindly provided by Piotr. > > Please comment, Carl Eugen > LGTM Files are probably invalid, but whatever. ___ ffmpeg-devel mailing list ffmpeg-devel@ffmpeg.org http://ffmpeg.org/mailman/listinfo/ffmpeg-devel
Re: [FFmpeg-devel] [PATCH]lavc/clearvideo: Allow decoding without extradata
2018-04-07 22:03 GMT+02:00, Paul B Mahol : > On 4/7/18, Carl Eugen Hoyos wrote: >> Hi! >> >> Attached patch fixes (initial) playback for the files in >> http://samples.ffmpeg.org/V-codecs/UCOD/noextradata/ >> - kindly provided by Piotr. >> >> Please comment, Carl Eugen >> > > LGTM Patch applied, thank you! Carl Eugen ___ ffmpeg-devel mailing list ffmpeg-devel@ffmpeg.org http://ffmpeg.org/mailman/listinfo/ffmpeg-devel
[FFmpeg-devel] [PATCH] configure: disable direct stripping in OpenBSD
It appears strip -o creates new files without preserving permissions from the source binary, resulting in non executable files. Signed-off-by: James Almer --- Untested. This is purely based on what i see in http://fate.ffmpeg.org/ Alternatively, although probably much harder to do, would be to make FATE run the fftools from the install folder rather than the build folder, which is what it's apparently doing right now. But that also only solves the issue for test/fate.sh and not for the resulting non execurable binary in the build folder. configure | 1 + 1 file changed, 1 insertion(+) diff --git a/configure b/configure index 08d6fc5983..47eda6ca21 100755 --- a/configure +++ b/configure @@ -5045,6 +5045,7 @@ case $target_os in ;; openbsd|bitrig) disable symver +striptype="" SHFLAGS='-shared' SLIB_INSTALL_NAME='$(SLIBNAME).$(LIBMAJOR).$(LIBMINOR)' SLIB_INSTALL_LINKS= -- 2.16.2 ___ ffmpeg-devel mailing list ffmpeg-devel@ffmpeg.org http://ffmpeg.org/mailman/listinfo/ffmpeg-devel
[FFmpeg-devel] [PATCH 2/2] lavf/format: Remove the dead code in av_probe_input_buffer2.
From df6293f42fad1e4521389c23c984519caa98d3f5 Mon Sep 17 00:00:00 2001 From: Jun Zhao Date: Sun, 8 Apr 2018 08:09:13 +0800 Subject: [PATCH 2/2] lavf/format: Remove the dead code in av_probe_input_buffer2. Remove the dead code in av_probe_input_buffer2 Signed-off-by: Jun Zhao --- libavformat/format.c | 8 1 file changed, 8 deletions(-) diff --git a/libavformat/format.c b/libavformat/format.c index 1c66afb7e6..2c4c895530 100644 --- a/libavformat/format.c +++ b/libavformat/format.c @@ -250,14 +250,6 @@ int av_probe_input_buffer2(AVIOContext *pb, AVInputFormat **fmt, *semi = '\0'; } } -#if 0 -if (!*fmt && pb->av_class && av_opt_get(pb, "mime_type", AV_OPT_SEARCH_CHILDREN, &mime_type) >= 0 && mime_type) { -if (!av_strcasecmp(mime_type, "audio/aacp")) { -*fmt = av_find_input_format("aac"); -} -av_freep(&mime_type); -} -#endif for (probe_size = PROBE_BUF_MIN; probe_size <= max_probe_size && !*fmt; probe_size = FFMIN(probe_size << 1, -- 2.14.1 ___ ffmpeg-devel mailing list ffmpeg-devel@ffmpeg.org http://ffmpeg.org/mailman/listinfo/ffmpeg-devel
[FFmpeg-devel] [PATCH 1/2] avformat/avio: make the logic simple
From 733dfb98152a7a629e0440f6f807f76c2b2a9584 Mon Sep 17 00:00:00 2001 From: Jun Zhao Date: Sun, 8 Apr 2018 08:05:08 +0800 Subject: [PATCH 1/2] avformat/avio: make the logic simple remove the "ret" to make the code simple and generic. Signed-off-by: Jun Zhao --- libavformat/avio.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/libavformat/avio.c b/libavformat/avio.c index 63e82872f7..663789ec02 100644 --- a/libavformat/avio.c +++ b/libavformat/avio.c @@ -663,8 +663,7 @@ int ffurl_shutdown(URLContext *h, int flags) int ff_check_interrupt(AVIOInterruptCB *cb) { -int ret; -if (cb && cb->callback && (ret = cb->callback(cb->opaque))) -return ret; +if (cb && cb->callback) +return cb->callback(cb->opaque); return 0; } -- 2.14.1 ___ ffmpeg-devel mailing list ffmpeg-devel@ffmpeg.org http://ffmpeg.org/mailman/listinfo/ffmpeg-devel
[FFmpeg-devel] [PATCH] avcodec/movtextdec: Check style_start/end
Limits based on 3GPP TS 26.245 V14.0.0 Fixes: Timeout Fixes: 6377/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_MOVTEXT_fuzzer-5175929115508736 Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg Signed-off-by: Michael Niedermayer --- libavcodec/movtextdec.c | 8 1 file changed, 8 insertions(+) diff --git a/libavcodec/movtextdec.c b/libavcodec/movtextdec.c index 89ac791602..c38c5edce6 100644 --- a/libavcodec/movtextdec.c +++ b/libavcodec/movtextdec.c @@ -299,6 +299,14 @@ static int decode_styl(const uint8_t *tsmb, MovTextContext *m, AVPacket *avpkt) m->s_temp->style_start = AV_RB16(tsmb); tsmb += 2; m->s_temp->style_end = AV_RB16(tsmb); + +if ( m->s_temp->style_end < m->s_temp->style_start +|| (m->count_s && m->s_temp->style_start < m->s[m->count_s - 1]->style_end)) { +av_freep(&m->s_temp); +mov_text_cleanup(m); +return AVERROR(ENOMEM); +} + tsmb += 2; m->s_temp->style_fontID = AV_RB16(tsmb); tsmb += 2; -- 2.16.2 ___ ffmpeg-devel mailing list ffmpeg-devel@ffmpeg.org http://ffmpeg.org/mailman/listinfo/ffmpeg-devel
Re: [FFmpeg-devel] [PATCH] avcodec/movtextdec: Check style_start/end
On Sun, 8 Apr 2018 03:29:44 +0200 Michael Niedermayer wrote: > Limits based on 3GPP TS 26.245 V14.0.0 > Fixes: Timeout > Fixes: > 6377/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_MOVTEXT_fuzzer-5175929115508736 > > Found-by: continuous fuzzing process > https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg > Signed-off-by: Michael Niedermayer --- > libavcodec/movtextdec.c | 8 > 1 file changed, 8 insertions(+) > > diff --git a/libavcodec/movtextdec.c b/libavcodec/movtextdec.c > index 89ac791602..c38c5edce6 100644 > --- a/libavcodec/movtextdec.c > +++ b/libavcodec/movtextdec.c > @@ -299,6 +299,14 @@ static int decode_styl(const uint8_t *tsmb, > MovTextContext *m, AVPacket *avpkt) m->s_temp->style_start = > AV_RB16(tsmb); tsmb += 2; > m->s_temp->style_end = AV_RB16(tsmb); > + > +if ( m->s_temp->style_end < m->s_temp->style_start > +|| (m->count_s && m->s_temp->style_start < > m->s[m->count_s - 1]->style_end)) { > +av_freep(&m->s_temp); > +mov_text_cleanup(m); > +return AVERROR(ENOMEM); > +} > + > tsmb += 2; > m->s_temp->style_fontID = AV_RB16(tsmb); > tsmb += 2; LGTM. --phil ___ ffmpeg-devel mailing list ffmpeg-devel@ffmpeg.org http://ffmpeg.org/mailman/listinfo/ffmpeg-devel
Re: [FFmpeg-devel] [PATCH v2] lavc/hevc: Don't parse NAL unit for a dummy buffer
Hi Steven, Are there more comments on this patch? Thanks Haihao > hevc parser mistakenly reports the following message if a dummy buffer > is padded for EOF > >[hevc @ 0x559b63848610] missing picture in access unit > > v2: use the preferred code style and rebase the patch > > Signed-off-by: Haihao Xiang > --- > libavcodec/hevc_parser.c | 7 ++- > 1 file changed, 6 insertions(+), 1 deletion(-) > > diff --git a/libavcodec/hevc_parser.c b/libavcodec/hevc_parser.c > index a468682ed3..01418b276d 100644 > --- a/libavcodec/hevc_parser.c > +++ b/libavcodec/hevc_parser.c > @@ -294,6 +294,8 @@ static int hevc_parse(AVCodecParserContext *s, > AVCodecContext *avctx, > int next; > HEVCParserContext *ctx = s->priv_data; > ParseContext *pc = &ctx->pc; > +int is_dummy_buf = !buf_size; > +const uint8_t *dummy_buf = buf; > > if (avctx->extradata && !ctx->parsed_extradata) { > ff_hevc_decode_extradata(avctx->extradata, avctx->extradata_size, > &ctx->ps, &ctx->sei, > @@ -313,7 +315,10 @@ static int hevc_parse(AVCodecParserContext *s, > AVCodecContext *avctx, > } > } > > -parse_nal_units(s, buf, buf_size, avctx); > +is_dummy_buf = (is_dummy_buf && (dummy_buf == buf)); > + > +if (!is_dummy_buf) > +parse_nal_units(s, buf, buf_size, avctx); > > *poutbuf = buf; > *poutbuf_size = buf_size; ___ ffmpeg-devel mailing list ffmpeg-devel@ffmpeg.org http://ffmpeg.org/mailman/listinfo/ffmpeg-devel
Re: [FFmpeg-devel] [PATCH] avformat/rawenc: check stream type
On 4/8/2018 1:19 AM, Carl Eugen Hoyos wrote: 2018-04-07 13:32 GMT+02:00, Gyan Doshi : Had an user on SE sometime back extract a video stream to a .h264 (in order to retime PTS). Does this work at all? With input -r, yes. For streams with b-pyramid, mp4box does. A warning would be sufficient. That won't be useful in batch mode, or good when a raw muxer does something besides just a packet dump. Besides, why allow ffmpeg to produce files with mismatched extensions, when input probing can't obviate the issue? Gyan ___ ffmpeg-devel mailing list ffmpeg-devel@ffmpeg.org http://ffmpeg.org/mailman/listinfo/ffmpeg-devel
Re: [FFmpeg-devel] [PATCH v2] lavc/hevc: Don't parse NAL unit for a dummy buffer
> On 8 Apr 2018, at 12:53, Xiang, Haihao wrote: > > > > Hi Steven, > > Are there more comments on this patch? > > Thanks > Haihao > > >> hevc parser mistakenly reports the following message if a dummy buffer >> is padded for EOF >> >> [hevc @ 0x559b63848610] missing picture in access unit >> >> v2: use the preferred code style and rebase the patch >> >> Signed-off-by: Haihao Xiang >> --- >> libavcodec/hevc_parser.c | 7 ++- >> 1 file changed, 6 insertions(+), 1 deletion(-) >> >> diff --git a/libavcodec/hevc_parser.c b/libavcodec/hevc_parser.c >> index a468682ed3..01418b276d 100644 >> --- a/libavcodec/hevc_parser.c >> +++ b/libavcodec/hevc_parser.c >> @@ -294,6 +294,8 @@ static int hevc_parse(AVCodecParserContext *s, >> AVCodecContext *avctx, >> int next; >> HEVCParserContext *ctx = s->priv_data; >> ParseContext *pc = &ctx->pc; >> +int is_dummy_buf = !buf_size; >> +const uint8_t *dummy_buf = buf; >> >> if (avctx->extradata && !ctx->parsed_extradata) { >> ff_hevc_decode_extradata(avctx->extradata, avctx->extradata_size, >> &ctx->ps, &ctx->sei, >> @@ -313,7 +315,10 @@ static int hevc_parse(AVCodecParserContext *s, >> AVCodecContext *avctx, >> } >> } >> >> -parse_nal_units(s, buf, buf_size, avctx); >> +is_dummy_buf = (is_dummy_buf && (dummy_buf == buf)); >> + >> +if (!is_dummy_buf) >> +parse_nal_units(s, buf, buf_size, avctx); >> >> *poutbuf = buf; >> *poutbuf_size = buf_size; LGTM Thanks Steven ___ ffmpeg-devel mailing list ffmpeg-devel@ffmpeg.org http://ffmpeg.org/mailman/listinfo/ffmpeg-devel
Re: [FFmpeg-devel] [PATCH] avformat/hlsenc: fix handling of delete_segments when %v is present
> On 6 Apr 2018, at 18:27, Bodecs Bela wrote: > > Dear All, > > when var_stream_map option is used, %v must appear either in segment name > template or in the directory path. This latter case currently is not handled > and using delete_segments flag of hls_flags is broken now. This patch fixes > this issue. > The root cause of the bug was that HLSSegment struct only stores the final > filename part, but not the final directory path. Most of the cases, final > path info is unneded, It only necessary when you want to delete old segments > (e.g in case of live streaming). > Without variant streams it was unnecessary to store the final directory path, > because all segment were stored into the same directory. But introducing %v > in directory names either require to store the final directory path into > HLSSegment or associate segments with their variant streams to be able > deleting them later. I have choosen the second solution and introduced a > variant index data member into the segment struct. > > please review this patch. > > thank you in advance, > > Bela Bodecs > > > <0001-avformat-hlsenc-fix-handling-of-delete_segments-when.patch>___ > ffmpeg-devel mailing list > ffmpeg-devel@ffmpeg.org > http://ffmpeg.org/mailman/listinfo/ffmpeg-devel LGTM Thanks Steven ___ ffmpeg-devel mailing list ffmpeg-devel@ffmpeg.org http://ffmpeg.org/mailman/listinfo/ffmpeg-devel