Re: [FFmpeg-devel] [PATCH 2/4] mov: check for positive sample->size

2015-05-24 Thread Yusuke Nakamura
2015-05-24 7:04 GMT+09:00 Andreas Cadhalpun < andreas.cadhal...@googlemail.com>: > Without this the mov demuxer can return a large number of empty packets. > > Signed-off-by: Andreas Cadhalpun > --- > libavformat/mov.c | 5 + > 1 file changed, 5 insertions(+) > > diff --git a/libavformat/mov

Re: [FFmpeg-devel] [PATCH] libdcadec: search for frames that start late in a packet

2015-05-24 Thread Hendrik Leppkes
On Sun, May 24, 2015 at 6:27 AM, James Almer wrote: > Based on commit 4ae15605f6298d8369a1f1374596b52a3839c703 > > Signed-off-by: James Almer > --- > libavcodec/libdcadec.c | 5 - > 1 file changed, 4 insertions(+), 1 deletion(-) > > diff --git a/libavcodec/libdcadec.c b/libavcodec/libdcadec.

[FFmpeg-devel] [PATCH] avutil: Add av_q2intfloat()

2015-05-24 Thread Michael Niedermayer
Signed-off-by: Michael Niedermayer --- libavutil/rational.c | 48 libavutil/rational.h |7 +++ 2 files changed, 55 insertions(+) diff --git a/libavutil/rational.c b/libavutil/rational.c index 594a6f8..21d2bb7 100644 --- a/libavutil/ratio

Re: [FFmpeg-devel] [PATCH 1/4] mov: abort on EOF in ff_mov_read_chan

2015-05-24 Thread Andreas Cadhalpun
On 24.05.2015 00:21, Michael Niedermayer wrote: > On Sun, May 24, 2015 at 12:04:08AM +0200, Andreas Cadhalpun wrote: >> Otherwise the loop can take a lot of time if num_descr is very large. >> >> Signed-off-by: Andreas Cadhalpun >> --- >> libavformat/mov_chan.c | 5 + >> 1 file changed, 5 ins

Re: [FFmpeg-devel] [PATCH 3/4] mov: fix two memleaks

2015-05-24 Thread Andreas Cadhalpun
On 24.05.2015 01:15, Michael Niedermayer wrote: > On Sun, May 24, 2015 at 12:04:39AM +0200, Andreas Cadhalpun wrote: >> Signed-off-by: Andreas Cadhalpun >> --- >> libavformat/mov.c | 4 +++- >> 1 file changed, 3 insertions(+), 1 deletion(-) > > LGTM Pushed. Best regards, Andreas _

Re: [FFmpeg-devel] [PATCH 4/4] mov: always check avio_read return value

2015-05-24 Thread Andreas Cadhalpun
On 24.05.2015 02:02, Michael Niedermayer wrote: > On Sun, May 24, 2015 at 12:04:54AM +0200, Andreas Cadhalpun wrote: >> If avio_read fails, the buffer can contain uninitialized data. >> >> This fixes 'Conditional jump or move depends on uninitialised value(s)' >> valgrind warnings. > > should be o

Re: [FFmpeg-devel] [PATCH 2/4] mov: check for positive sample->size

2015-05-24 Thread Andreas Cadhalpun
On 24.05.2015 00:46, Michael Niedermayer wrote: > On Sun, May 24, 2015 at 12:04:23AM +0200, Andreas Cadhalpun wrote: >> +if (!sample->size) { >> +av_log(s, AV_LOG_ERROR, "sample size is zero\n"); >> +return AVERROR_INVALIDDATA; >> +} > > this would cause failure to demux f

[FFmpeg-devel] [PATCH] libshine: fix support for shine 3.0

2015-05-24 Thread Andreas Cadhalpun
shine_encode_buffer expects written to be an int pointer, while the previous shine_encode_frame expected it to be a long pointer. Thus encoding with libshine currently always fails with "internal buffer too small", because a negative return value of shine_encode_buffer is interpreted as a very lar

[FFmpeg-devel] [PATCH] avcodec/put_bits: Add PUTBIT_FLAG_ONLY_LENGTH

2015-05-24 Thread Michael Niedermayer
This allows skipping computationally expensive writing code in the first pass of 2 pass encoding. Its equivalent to AVCodecContexts CODEC_FLAG2_NO_OUTPUT but by putting it in PutBitContext it becomes available without the need to keep a pointer to AVCodecContext or some other context around Signe

Re: [FFmpeg-devel] [PATCH] libdcadec: search for frames that start late in a packet

2015-05-24 Thread James Almer
On 24/05/15 6:47 AM, Hendrik Leppkes wrote: > On Sun, May 24, 2015 at 6:27 AM, James Almer wrote: >> Based on commit 4ae15605f6298d8369a1f1374596b52a3839c703 >> >> Signed-off-by: James Almer >> --- >> libavcodec/libdcadec.c | 5 - >> 1 file changed, 4 insertions(+), 1 deletion(-) >> >> diff

Re: [FFmpeg-devel] [PATCH] libshine: fix support for shine 3.0

2015-05-24 Thread Michael Niedermayer
On Sun, May 24, 2015 at 03:52:21PM +0200, Andreas Cadhalpun wrote: > shine_encode_buffer expects written to be an int pointer, while the > previous shine_encode_frame expected it to be a long pointer. > > Thus encoding with libshine currently always fails with > "internal buffer too small", becaus

Re: [FFmpeg-devel] [PATCH 2/4] mov: check for positive sample->size

2015-05-24 Thread Michael Niedermayer
On Sun, May 24, 2015 at 03:21:25PM +0200, Andreas Cadhalpun wrote: > On 24.05.2015 00:46, Michael Niedermayer wrote: > > On Sun, May 24, 2015 at 12:04:23AM +0200, Andreas Cadhalpun wrote: > > >> +if (!sample->size) { > >> +av_log(s, AV_LOG_ERROR, "sample size is zero\n"); > >> +

[FFmpeg-devel] [PATCH] Improve upon dynamic arrays- movtext subtitles

2015-05-24 Thread Niklesh Lalwani
From: Niklesh Signed-off-by: Niklesh --- libavcodec/movtextdec.c | 32 1 file changed, 16 insertions(+), 16 deletions(-) diff --git a/libavcodec/movtextdec.c b/libavcodec/movtextdec.c index 04e1c8a..11934f9 100644 --- a/libavcodec/movtextdec.c +++ b/libavcodec/

[FFmpeg-devel] [RFC][PATCH] libwebp: combine libwebp_anim and libwebp encoders into one

2015-05-24 Thread James Almer
Use either the WebPEncoder or WebPAnimEncoder APIs depending on availability of the latter. Signed-off-by: James Almer --- This is an RFC because the resulting encoder will use one of the two APIs, which is a change from the current behavior of having one encoder for each API. The new encoder was

Re: [FFmpeg-devel] [RFC][PATCH] libwebp: combine libwebp_anim and libwebp encoders into one

2015-05-24 Thread Michael Niedermayer
On Sun, May 24, 2015 at 04:22:42PM -0300, James Almer wrote: > Use either the WebPEncoder or WebPAnimEncoder APIs depending on availability > of the latter. > > Signed-off-by: James Almer > --- > This is an RFC because the resulting encoder will use one of the two APIs, > which > is a change fro

Re: [FFmpeg-devel] [RFC][PATCH] libwebp: combine libwebp_anim and libwebp encoders into one

2015-05-24 Thread James Almer
On 24/05/15 5:59 PM, Michael Niedermayer wrote: > On Sun, May 24, 2015 at 04:22:42PM -0300, James Almer wrote: >> Use either the WebPEncoder or WebPAnimEncoder APIs depending on availability >> of the latter. >> >> Signed-off-by: James Almer >> --- >> This is an RFC because the resulting encoder w

Re: [FFmpeg-devel] [RFC][PATCH] libwebp: combine libwebp_anim and libwebp encoders into one

2015-05-24 Thread Michael Niedermayer
On Sun, May 24, 2015 at 06:39:05PM -0300, James Almer wrote: > On 24/05/15 5:59 PM, Michael Niedermayer wrote: > > On Sun, May 24, 2015 at 04:22:42PM -0300, James Almer wrote: [...] > > > > try it yourself > > ./ffmpeg -i matrixbench_mpeg2.mpg -cr_threshold 1 -cr_size 16 -t 10 > > -loop 2 -vc

Re: [FFmpeg-devel] [PATCH] avcodec/libutvideoenc: Fix memleak

2015-05-24 Thread Michael Niedermayer
On Fri, May 15, 2015 at 11:53:24PM +0200, Michael Niedermayer wrote: > Fixes: CID1257657 > > Signed-off-by: Michael Niedermayer > --- > libavcodec/libutvideoenc.cpp |4 +++- > 1 file changed, 3 insertions(+), 1 deletion(-) applied [...] -- Michael GnuPG fingerprint: 9FF2128B147EF6730B

Re: [FFmpeg-devel] [RFC][PATCH] libwebp: combine libwebp_anim and libwebp encoders into one

2015-05-24 Thread Michael Niedermayer
On Sun, May 24, 2015 at 06:39:05PM -0300, James Almer wrote: > On 24/05/15 5:59 PM, Michael Niedermayer wrote: > > On Sun, May 24, 2015 at 04:22:42PM -0300, James Almer wrote: > >> Use either the WebPEncoder or WebPAnimEncoder APIs depending on > >> availability > >> of the latter. > >> > >> Signe