Re: [FFmpeg-devel] [PATCH] avutil: Move av_rint64_clip_* to internal.h

2015-11-14 Thread Ganesh Ajjanagadde
On Sat, Nov 14, 2015 at 9:49 PM, Michael Niedermayer wrote: > On Sat, Nov 14, 2015 at 11:01:55PM -0300, James Almer wrote: >> On 11/14/2015 10:48 PM, Michael Niedermayer wrote: >> > From: Michael Niedermayer >> > >> > This should avoid build failures on VS2012 >> > Feel free to changes this to a

Re: [FFmpeg-devel] [PATCH] avutil: Move av_rint64_clip_* to internal.h

2015-11-14 Thread Michael Niedermayer
On Sat, Nov 14, 2015 at 11:01:55PM -0300, James Almer wrote: > On 11/14/2015 10:48 PM, Michael Niedermayer wrote: > > From: Michael Niedermayer > > > > This should avoid build failures on VS2012 > > Feel free to changes this to a different solution > > > > Signed-off-by: Michael Niedermayer > >

[FFmpeg-devel] [PATCH] ffmpeg: Simplify fps code related to delta0

2015-11-14 Thread Bryan Huh
Small refactor of fps code for improved readability. In particular the "cor" variable was unnecessary and misleading because it would always be set to -delta0. --- ffmpeg.c | 11 +-- 1 files changed, 5 insertions(+), 6 deletions(-) diff --git a/ffmpeg.c b/ffmpeg.c index 3341777..560c5a0

[FFmpeg-devel] [PATCH] ffmpeg: Fixing typos and adding comments to fps code

2015-11-14 Thread Bryan Huh
--- ffmpeg.c | 16 ffmpeg.h |2 +- 2 files changed, 9 insertions(+), 9 deletions(-) diff --git a/ffmpeg.c b/ffmpeg.c index 3341777..a56ec87 100644 --- a/ffmpeg.c +++ b/ffmpeg.c @@ -984,11 +984,11 @@ static void do_video_out(AVFormatContext *s,

Re: [FFmpeg-devel] [PATCH 2/2] avutil/eval: change sqrt to hypot

2015-11-14 Thread Michael Niedermayer
On Sat, Nov 14, 2015 at 12:11:20PM -0500, Ganesh Ajjanagadde wrote: > This improves the mathematical behavior of hypotenuse computation. > > Signed-off-by: Ganesh Ajjanagadde > --- > libavutil/eval.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) if a hypot() function fallback is added

Re: [FFmpeg-devel] [PATCH] mpegvideo: clear overread in clear_context

2015-11-14 Thread Michael Niedermayer
On Sat, Nov 14, 2015 at 11:00:55PM +0100, Andreas Cadhalpun wrote: > Otherwise the h263p decoder can try to copy overread bytes, even though > buffer is NULL. > > Signed-off-by: Andreas Cadhalpun > --- > libavcodec/mpegvideo.c | 1 + > 1 file changed, 1 insertion(+) LGTM [...] -- Michael

Re: [FFmpeg-devel] [PATCH] avutil: Move av_rint64_clip_* to internal.h

2015-11-14 Thread James Almer
On 11/14/2015 10:48 PM, Michael Niedermayer wrote: > From: Michael Niedermayer > > This should avoid build failures on VS2012 > Feel free to changes this to a different solution > > Signed-off-by: Michael Niedermayer > --- > libavutil/common.h | 39 --- >

[FFmpeg-devel] [PATCH] avutil: Move av_rint64_clip_* to internal.h

2015-11-14 Thread Michael Niedermayer
From: Michael Niedermayer This should avoid build failures on VS2012 Feel free to changes this to a different solution Signed-off-by: Michael Niedermayer --- libavutil/common.h | 39 --- libavutil/internal.h | 40 +++

Re: [FFmpeg-devel] [PATCHv4] avutil/common: add av_rint64_clip

2015-11-14 Thread Ganesh Ajjanagadde
On Sat, Nov 14, 2015 at 6:30 PM, Hendrik Leppkes wrote: > On Sat, Nov 14, 2015 at 10:38 PM, Ganesh Ajjanagadde wrote: >> On Sat, Nov 14, 2015 at 4:30 PM, Hendrik Leppkes wrote: >>> On Sat, Nov 14, 2015 at 10:27 PM, Ganesh Ajjanagadde >>> wrote: On Sat, Nov 14, 2015 at 4:03 PM, Ganesh Ajja

[FFmpeg-devel] [PATCH] avutil/libm: correct isnan, isinf compat hacks

2015-11-14 Thread Ganesh Ajjanagadde
isnan and isinf are actually macros as per the standard. In particular, the existing implementation has incorrect signature. Furthermore, this results in undefined behavior for e.g double values outside float range as per the standard. This patch corrects the undefined behavior for all usage withi

Re: [FFmpeg-devel] [PATCHv4] avutil/common: add av_rint64_clip

2015-11-14 Thread Hendrik Leppkes
On Sat, Nov 14, 2015 at 10:38 PM, Ganesh Ajjanagadde wrote: > On Sat, Nov 14, 2015 at 4:30 PM, Hendrik Leppkes wrote: >> On Sat, Nov 14, 2015 at 10:27 PM, Ganesh Ajjanagadde >> wrote: >>> On Sat, Nov 14, 2015 at 4:03 PM, Ganesh Ajjanagadde >>> wrote: On Sat, Nov 14, 2015 at 3:28 PM, Hend

[FFmpeg-devel] [PATCH] mpegtsenc: add vc-1 support to MPEG-TS muxer (ticket 2141)

2015-11-14 Thread Hagen Schmidt
--- libavformat/mpegtsenc.c | 10 ++ 1 file changed, 10 insertions(+) diff --git a/libavformat/mpegtsenc.c b/libavformat/mpegtsenc.c index 252f9c6..468bad4 100644 --- a/libavformat/mpegtsenc.c +++ b/libavformat/mpegtsenc.c @@ -297,6 +297,9 @@ static int mpegts_write_pmt(AVFormatContext *s

Re: [FFmpeg-devel] [PATCH 1/2] configure+libm.h: add hypot emulation

2015-11-14 Thread Ganesh Ajjanagadde
On Sat, Nov 14, 2015 at 4:48 PM, Paul B Mahol wrote: > On 11/14/15, Ganesh Ajjanagadde wrote: >> It is known that the naive sqrt(x*x + y*y) approach for computing the >> hypotenuse suffers from overflow and accuracy issues, see e.g >> http://www.johndcook.com/blog/2010/06/02/whats-so-hard-about-f

[FFmpeg-devel] [PATCH] mpegvideo: clear overread in clear_context

2015-11-14 Thread Andreas Cadhalpun
Otherwise the h263p decoder can try to copy overread bytes, even though buffer is NULL. Signed-off-by: Andreas Cadhalpun --- libavcodec/mpegvideo.c | 1 + 1 file changed, 1 insertion(+) diff --git a/libavcodec/mpegvideo.c b/libavcodec/mpegvideo.c index 69e0595..60e19ff 100644 --- a/libavcodec/m

Re: [FFmpeg-devel] [PATCH 1/2] configure+libm.h: add hypot emulation

2015-11-14 Thread Ganesh Ajjanagadde
On Sat, Nov 14, 2015 at 4:48 PM, Paul B Mahol wrote: > On 11/14/15, Ganesh Ajjanagadde wrote: >> It is known that the naive sqrt(x*x + y*y) approach for computing the >> hypotenuse suffers from overflow and accuracy issues, see e.g >> http://www.johndcook.com/blog/2010/06/02/whats-so-hard-about-f

Re: [FFmpeg-devel] [PATCH 1/2] configure+libm.h: add hypot emulation

2015-11-14 Thread Paul B Mahol
On 11/14/15, Ganesh Ajjanagadde wrote: > It is known that the naive sqrt(x*x + y*y) approach for computing the > hypotenuse suffers from overflow and accuracy issues, see e.g > http://www.johndcook.com/blog/2010/06/02/whats-so-hard-about-finding-a-hypotenuse/. > This adds hypot support to FFmpeg,

Re: [FFmpeg-devel] [PATCHv4] avutil/common: add av_rint64_clip

2015-11-14 Thread Ganesh Ajjanagadde
On Sat, Nov 14, 2015 at 4:30 PM, Hendrik Leppkes wrote: > On Sat, Nov 14, 2015 at 10:27 PM, Ganesh Ajjanagadde wrote: >> On Sat, Nov 14, 2015 at 4:03 PM, Ganesh Ajjanagadde wrote: >>> On Sat, Nov 14, 2015 at 3:28 PM, Hendrik Leppkes >>> wrote: On Sat, Nov 14, 2015 at 3:51 AM, Ganesh Ajjan

Re: [FFmpeg-devel] [PATCHv4] avutil/common: add av_rint64_clip

2015-11-14 Thread Ganesh Ajjanagadde
On Sat, Nov 14, 2015 at 4:35 PM, James Almer wrote: > On 11/14/2015 6:30 PM, Hendrik Leppkes wrote: >> On Sat, Nov 14, 2015 at 10:27 PM, Ganesh Ajjanagadde >> wrote: >>> On Sat, Nov 14, 2015 at 4:03 PM, Ganesh Ajjanagadde >>> wrote: On Sat, Nov 14, 2015 at 3:28 PM, Hendrik Leppkes

Re: [FFmpeg-devel] [PATCHv4] avutil/common: add av_rint64_clip

2015-11-14 Thread James Almer
On 11/14/2015 6:30 PM, Hendrik Leppkes wrote: > On Sat, Nov 14, 2015 at 10:27 PM, Ganesh Ajjanagadde wrote: >> On Sat, Nov 14, 2015 at 4:03 PM, Ganesh Ajjanagadde wrote: >>> On Sat, Nov 14, 2015 at 3:28 PM, Hendrik Leppkes >>> wrote: On Sat, Nov 14, 2015 at 3:51 AM, Ganesh Ajjanagadde >>

Re: [FFmpeg-devel] [PATCHv4] avutil/common: add av_rint64_clip

2015-11-14 Thread Hendrik Leppkes
On Sat, Nov 14, 2015 at 10:27 PM, Ganesh Ajjanagadde wrote: > On Sat, Nov 14, 2015 at 4:03 PM, Ganesh Ajjanagadde wrote: >> On Sat, Nov 14, 2015 at 3:28 PM, Hendrik Leppkes wrote: >>> On Sat, Nov 14, 2015 at 3:51 AM, Ganesh Ajjanagadde >>> wrote: On Fri, Nov 13, 2015 at 7:17 PM, Ronald S.

Re: [FFmpeg-devel] [PATCHv4] avutil/common: add av_rint64_clip

2015-11-14 Thread Ganesh Ajjanagadde
On Sat, Nov 14, 2015 at 4:03 PM, Ganesh Ajjanagadde wrote: > On Sat, Nov 14, 2015 at 3:28 PM, Hendrik Leppkes wrote: >> On Sat, Nov 14, 2015 at 3:51 AM, Ganesh Ajjanagadde wrote: >>> On Fri, Nov 13, 2015 at 7:17 PM, Ronald S. Bultje >>> wrote: Hi, On Fri, Nov 13, 2015 at 6:16 PM

Re: [FFmpeg-devel] [PATCH 2/2] ffserver_config: replace strtod by av_strtod and correct undefined behavior

2015-11-14 Thread Michael Niedermayer
On Thu, Nov 12, 2015 at 09:46:05PM -0500, Ganesh Ajjanagadde wrote: > This uses av_strtod for added flexibility, and av_rint64_clip for ensuring > that > no undefined behavior gets invoked. > > Signed-off-by: Ganesh Ajjanagadde > --- > ffserver_config.c | 21 + > 1 file chan

Re: [FFmpeg-devel] [libav-devel] [PATCH 3/4] dds: make sure pallete frame buffer exists before use

2015-11-14 Thread Andreas Cadhalpun
On 14.11.2015 03:38, Vittorio Giovara wrote: > On Fri, Nov 13, 2015 at 10:01 PM, Andreas Cadhalpun > wrote: >> On 13.11.2015 02:08, Vittorio Giovara wrote: >>> oh I see, that can happen for a special crafted file, DDPF_FOURCC has >>> been introduced recently while DDPF_PALETTE has been removed, so

Re: [FFmpeg-devel] [PATCHv4] avutil/common: add av_rint64_clip

2015-11-14 Thread Ganesh Ajjanagadde
On Sat, Nov 14, 2015 at 3:28 PM, Hendrik Leppkes wrote: > On Sat, Nov 14, 2015 at 3:51 AM, Ganesh Ajjanagadde wrote: >> On Fri, Nov 13, 2015 at 7:17 PM, Ronald S. Bultje wrote: >>> Hi, >>> >>> On Fri, Nov 13, 2015 at 6:16 PM, Ganesh Ajjanagadde >>> wrote: >>> On Fri, Nov 13, 2015 at 4:52 P

Re: [FFmpeg-devel] [PATCHv4] avutil/common: add av_rint64_clip

2015-11-14 Thread Hendrik Leppkes
On Sat, Nov 14, 2015 at 3:51 AM, Ganesh Ajjanagadde wrote: > On Fri, Nov 13, 2015 at 7:17 PM, Ronald S. Bultje wrote: >> Hi, >> >> On Fri, Nov 13, 2015 at 6:16 PM, Ganesh Ajjanagadde >> wrote: >> >>> On Fri, Nov 13, 2015 at 4:52 PM, Ronald S. Bultje >>> wrote: >>> > Hi, >>> > >>> > On Fri, Nov

[FFmpeg-devel] [PATCH 2/2] avutil/eval: change sqrt to hypot

2015-11-14 Thread Ganesh Ajjanagadde
This improves the mathematical behavior of hypotenuse computation. Signed-off-by: Ganesh Ajjanagadde --- libavutil/eval.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libavutil/eval.c b/libavutil/eval.c index 7642b91..44129d6 100644 --- a/libavutil/eval.c +++ b/libavutil/e

[FFmpeg-devel] [PATCH 1/2] configure+libm.h: add hypot emulation

2015-11-14 Thread Ganesh Ajjanagadde
It is known that the naive sqrt(x*x + y*y) approach for computing the hypotenuse suffers from overflow and accuracy issues, see e.g http://www.johndcook.com/blog/2010/06/02/whats-so-hard-about-finding-a-hypotenuse/. This adds hypot support to FFmpeg, a C99 function. On platforms without hypot, thi

[FFmpeg-devel] [PATCH 0/2] initial support for hypot

2015-11-14 Thread Ganesh Ajjanagadde
The hypot function is very useful since the naive sqrt(x*x + y*y) has overflow and hence mathematical accuracy issues, see e.g http://www.johndcook.com/blog/2010/06/02/whats-so-hard-about-finding-a-hypotenuse/. 1/2 adds configure+libm support. The fallback is currently a naive one, and may be impr

Re: [FFmpeg-devel] [PATCH] all: use predefined mathematics macros

2015-11-14 Thread Ganesh Ajjanagadde
On Fri, Nov 13, 2015 at 11:43 AM, Ganesh Ajjanagadde wrote: > On Wed, Nov 11, 2015 at 6:53 AM, Michael Niedermayer > wrote: >> On Tue, Nov 10, 2015 at 10:35:23PM -0500, Ganesh Ajjanagadde wrote: >>> This uses M_SQRT2, M_PI, and M_E instead of the actual literals. >>> Benefits include: >>> 1. Redu

[FFmpeg-devel] [PATCH] all: use M_SQRT1_2, M_SQRT2, M_PI

2015-11-14 Thread Ganesh Ajjanagadde
This uses M_SQRT1_2, M_SQRT2, and M_PI instead of the actual literals. Benefits include: 1. Reduced scope for copy/paste errors and improved readability. 2. Consistency across the codebase. 3. Actually fixes an incorrect sqrt(2) in avcodec/ppc. 4. Greater precision in avcodec/ac3. Patch tested wit

Re: [FFmpeg-devel] [PATCH 5/5] lavfi/select: add support for concatdec_select option

2015-11-14 Thread Marton Balint
On Fri, 13 Nov 2015, Nicolas George wrote: [...] +AVDictionary *metadata = av_frame_get_metadata(frame); +AVDictionaryEntry *e1 = av_dict_get(metadata, "lavf.concatdec.start_time", NULL, 0); +AVDictionaryEntry *e2 = av_dict_get(metadata, "lavf.concatdec.duration", NULL, 0); +

[FFmpeg-devel] [PATCH] configure: Add option to use gmp

2015-11-14 Thread Ricardo Constantino
Enables RTMP(T)E support with SChannel (Not sure if this is the right way to enable this) Signed-off-by: Ricardo Constantino --- configure | 6 +- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/configure b/configure index 9a736ce..6c658f2 100755 --- a/configure +++ b/configure

Re: [FFmpeg-devel] [PATCHv2] avformat: implement SChannel SSP TLS protocol

2015-11-14 Thread Hendrik Leppkes
On Tue, Nov 10, 2015 at 5:19 PM, Hendrik Leppkes wrote: > On Tue, Nov 10, 2015 at 5:07 PM, Hendrik Leppkes wrote: >> This implementation does not support TLS listen sockets and loading >> CA/Certs from files. >> >> The Windows API does not support loading PEM certs, and would either >> require a

Re: [FFmpeg-devel] [PATCH 2/5] concatdec: calculate duration early if outpoint is known

2015-11-14 Thread Marton Balint
On Fri, 13 Nov 2015, Nicolas George wrote: Le decadi 20 brumaire, an CCXXIV, Marton Balint a écrit : Signed-off-by: Marton Balint --- libavformat/concatdec.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/libavformat/concatdec.c b/libavformat/concatdec.c index 0180a7e..560aa64 100644