Re: [FFmpeg-devel] [PATCHv2] doc/ffplay, ffplay: add information regarding volume control

2015-09-27 Thread Stefano Sabatini
On date Sunday 2015-09-27 12:38:34 -0400, Ganesh Ajjanagadde encoded:
> ffplay now supports dynamic volume control. This documents the supported
> behavior.
> 
> Signed-off-by: Ganesh Ajjanagadde 
> ---
>  doc/ffplay.texi | 9 +
>  ffplay.c| 3 +++
>  2 files changed, 12 insertions(+)

LGTM.
-- 
FFmpeg = Fabulous & Fascinating Mythic Powered EniGma
___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-devel


Re: [FFmpeg-devel] [PATCHv2 1/2] ffplay: add support for interactive volume control

2015-09-27 Thread Ganesh Ajjanagadde
On Sun, Sep 27, 2015 at 9:57 AM, Clément Bœsch  wrote:
> On Sat, Sep 26, 2015 at 11:36:42AM -0400, Ganesh Ajjanagadde wrote:
> [...]
>> -memcpy(stream, (uint8_t *)is->audio_buf + is->audio_buf_index, 
>> len1);
>> +if (is->muted)
>> +memset(stream, 0, len1);
>
> This doesn't work with u8 sampling.

Do you know of any clean alternative? For instance, is it possible to
obtain the zero point of the stream from some stream field?

>
> Would it make sense to insert + reconfigure a volume filter instead or
> it's too complicated?

Yes, I consider the current usage terrible unless I am missing
something. volume filter is static, so once set, I can't adjust the
volume until I reinsert a new volume filter, etc. I can't simply
adjust the volume like I can with vlc/mpv with a simple keybinding.

>
> [...]
>
> --
> Clément B.
>
> ___
> 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] [PATCHv2 1/2] ffplay: add support for interactive volume control

2015-09-27 Thread Ganesh Ajjanagadde
On Sun, Sep 27, 2015 at 11:40 AM, Clément Bœsch  wrote:
> On Sun, Sep 27, 2015 at 10:12:52AM -0400, Ganesh Ajjanagadde wrote:
> [...]
>> Yes, I consider the current usage terrible unless I am missing
>> something. volume filter is static, so once set, I can't adjust the
>> volume until I reinsert a new volume filter, etc. I can't simply
>> adjust the volume like I can with vlc/mpv with a simple keybinding.
>>
>
> There is a process_command() mechanism too if you want to change settings
> on the fly

Hmm... that seems to be a libavfilter thing. We could consider adding
that to the volume filter. However, I consider it independent of this
patch:
a user should not have to do an ffplay foo.mp4 -vf ... just to do
simple dynamic volume adjustment.
Again, my reference point is mpv/cvlc, where no such thing is required.

By the way, the silence_buf thing is currently ok due to the
av_mallocz in stream_open. This will need adjustment if we change
wanted_spec in the future. I see it as requiring no change for the
foreseeable future so I do not consider it worthwhile doing the more
"robust" initialization from the spec.silence value.

>
> --
> Clément B.
>
> ___
> 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] [PATCHv2 1/2] ffplay: add support for interactive volume control

2015-09-27 Thread Clément Bœsch
On Sun, Sep 27, 2015 at 11:57:41AM -0400, Ganesh Ajjanagadde wrote:
> On Sun, Sep 27, 2015 at 11:40 AM, Clément Bœsch  wrote:
> > On Sun, Sep 27, 2015 at 10:12:52AM -0400, Ganesh Ajjanagadde wrote:
> > [...]
> >> Yes, I consider the current usage terrible unless I am missing
> >> something. volume filter is static, so once set, I can't adjust the
> >> volume until I reinsert a new volume filter, etc. I can't simply
> >> adjust the volume like I can with vlc/mpv with a simple keybinding.
> >>
> >
> > There is a process_command() mechanism too if you want to change settings
> > on the fly
> 
> Hmm... that seems to be a libavfilter thing. We could consider adding
> that to the volume filter. 

volume filter already supports it (see avfilter_process_command() and
process_command callback in the filter code)

[...]

-- 
Clément B.


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/movenc: suppress -Wstrict-overflow warnings

2015-09-27 Thread Michael Niedermayer
On Sat, Sep 26, 2015 at 10:55:26PM -0400, Ganesh Ajjanagadde wrote:
> On Sat, Sep 26, 2015 at 10:32 PM, Ronald S. Bultje  wrote:
> > Hi,
> >
> > On Sat, Sep 26, 2015 at 7:19 PM, Ganesh Ajjanagadde 
> > wrote:
> >
> >> On Sat, Sep 26, 2015 at 7:11 PM, Michael Niedermayer 
> >> wrote:
> >> > On Fri, Sep 18, 2015 at 05:15:50PM -0400, Ganesh Ajjanagadde wrote:
> >> >> This patch results in identical behavior of movenc, and suppresses
> >> -Wstrict-overflow
> >> >> warnings observed in GCC 5.2.
> >> >> I have manually checked that all usages are safe, and overflow
> >> possibility does
> >> >> not exist with this expression rewrite.
> >> >>
> >> >> Signed-off-by: Ganesh Ajjanagadde 
> >> >> ---
> >> >>  libavformat/movenc.c | 2 +-
> >> >>  1 file changed, 1 insertion(+), 1 deletion(-)
> >> >>
> >> >> diff --git a/libavformat/movenc.c b/libavformat/movenc.c
> >> >> index af03d1e..6e4a1a6 100644
> >> >> --- a/libavformat/movenc.c
> >> >> +++ b/libavformat/movenc.c
> >> >> @@ -854,7 +854,7 @@ static int get_cluster_duration(MOVTrack *track,
> >> int cluster_idx)
> >> >>  {
> >> >>  int64_t next_dts;
> >> >>
> >> >> -if (cluster_idx >= track->entry)
> >> >> +if (cluster_idx - track->entry >= 0)
> >> >
> >> > i do not understand what this fixes or why
> >> > also plese quote the actual warnings which are fixed in the commit
> >> > message
> >>
> >> I have posted v2 with a more detailed commit message. It should be
> >> self explanatory.
> >
> >
> > Even with the new message, it's still not clear to me what's being fixed.
> > What does the warning check for? What is the problem in the initial
> > expression?
> 
> Compilers make transformations on the statements in order to possibly
> get better performance when compiled with optimizations. However, some
> of these optimizations require assumptions in the code. In particular,
> the compiler is internally rewriting cluster_idx >= track->entry to
> cluster_idx - track->entry >= 0 internally for some reason (I am not
> an asm/instruction set guy, so I can't comment why it likes this).
> However, such a transformation is NOT always safe as integer
> arithmetic can overflow (try e.g extreme values close to INT_MIN,
> INT_MAX). The warning is spit out since the compiler can't be sure
> that this is safe, but it still wants to do it (I suspect only the
> -O3/-O2 level that try this, can check if you want).

iam not sure i understand correctly but
if the compiler changes the code and then warns that what it just
did might be unsafe then the compiler is broken

[...]
-- 
Michael GnuPG fingerprint: 9FF2128B147EF6730BADF133611EC787040B0FAB

I know you won't believe me, but the highest form of Human Excellence is
to question oneself and others. -- Socrates


signature.asc
Description: Digital signature
___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-devel


Re: [FFmpeg-devel] [PATCH 3/3] configure: Disable automatic image base calculation

2015-09-27 Thread Michael Niedermayer
On Sun, Sep 27, 2015 at 04:59:25PM +0200, Hendrik Leppkes wrote:
> On Mon, Sep 21, 2015 at 6:41 AM, Alex Smith  wrote:
> > From: Alex Smith 
> >
> > There's no reason for it.  ASLR will rebase it regardless so "preventing
> > collisions" isn't really relevant.  This also brings it in line with
> > what a msvc produced dll will have (an image base of 0x1000).
> >
> > Signed-off-by: Alex Smith 
> > ---
> >  configure | 2 +-
> >  1 file changed, 1 insertion(+), 1 deletion(-)
> >
> > diff --git a/configure b/configure
> > index 0c60c03..a540ae7 100755
> > --- a/configure
> > +++ b/configure
> > @@ -4386,7 +4386,7 @@ case $target_os in
> >  SLIB_INSTALL_LINKS=
> >  SLIB_INSTALL_EXTRA_SHLIB='$(SLIBNAME:$(SLIBSUF)=.lib)'
> >  SLIB_INSTALL_EXTRA_LIB='lib$(SLIBNAME:$(SLIBSUF)=.dll.a) 
> > $(SLIBNAME_WITH_MAJOR:$(SLIBSUF)=.def)'
> > -SHFLAGS='-shared -Wl,--output-def,$$(@:$(SLIBSUF)=.orig.def) 
> > -Wl,--out-implib,$(SUBDIR)lib$(SLIBNAME:$(SLIBSUF)=.dll.a) 
> > -Wl,--enable-runtime-pseudo-reloc -Wl,--enable-auto-image-base'
> > +SHFLAGS='-shared -Wl,--output-def,$$(@:$(SLIBSUF)=.orig.def) 
> > -Wl,--out-implib,$(SUBDIR)lib$(SLIBNAME:$(SLIBSUF)=.dll.a) 
> > -Wl,--enable-runtime-pseudo-reloc -Wl,--disable-auto-image-base'
> >  objformat="win32"
> >  ranlib=:
> >  enable dos_paths
> > --
> > 1.9.5.msysgit.0
> 
> LGTM, as it matches msvc afterwards.

applied

thanks

[...]
-- 
Michael GnuPG fingerprint: 9FF2128B147EF6730BADF133611EC787040B0FAB

The misfortune of the wise is better than the prosperity of the fool.
-- Epicurus


signature.asc
Description: Digital signature
___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-devel


Re: [FFmpeg-devel] [PATCH] avfilter/f_ebur128: add dualmono measurement option

2015-09-27 Thread Clément Bœsch
On Fri, Sep 25, 2015 at 04:26:00PM -0500, Kyle Swanson wrote:
[...]
> This is a feature supported by many other loudness scanners. In the
> United States, this filter is used to measure loudness for much of our
> distributed public radio content. Our current workaround is to first
> determine channel count, and then alter our calls to FFmpeg
> accordingly. This is a simple, but quite useful feature to have.
> Compare the output of the following commands. The first is our
> workaround, and the second is an equivalent command which also
> provides an accurate measurement. The advantage to having this built
> in is that the same call can be used for multi-channel inputs as well.
> 
> ffmpeg -nostats -i mono.wav -filter_complex
> "[0:0][0:0]amerge=inputs=2[aout];[aout]ebur128=framelog=verbose:peak=sample+true"
> -f null -
> ffmpeg -nostats -i mono.wav -filter_complex ebur128=dualmono=true
> ebur128 -f null -
> 
> See also: https://ffmpeg.org/pipermail/ffmpeg-devel/2013-March/139910.html
> Also see this blog post:
> http://www.producenewmedia.com/podcast-loudness-mono-vs-stereo-perception/

questions:

- what happens if you resample the input (by prefixing ebur128 with
  aformat=channel_layout=stereo)?
- if I'm reading the blog correctly ("Note that In my discussions with
  leading experts in the space, it has come to my attention that this
  approach may not be sustainable. Many pros feel it is the responsibility
  of the playback device and/or delivery system to apply the necessary
  compensation.") this is not a standard behaviour at all. Do you confirm
  this?

-- 
Clément B.


signature.asc
Description: PGP signature
___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-devel


Re: [FFmpeg-devel] [PATCHv2 1/2] ffplay: add support for interactive volume control

2015-09-27 Thread Clément Bœsch
On Sat, Sep 26, 2015 at 11:36:42AM -0400, Ganesh Ajjanagadde wrote:
[...]
> -memcpy(stream, (uint8_t *)is->audio_buf + is->audio_buf_index, len1);
> +if (is->muted)
> +memset(stream, 0, len1);

This doesn't work with u8 sampling.

Would it make sense to insert + reconfigure a volume filter instead or
it's too complicated?

[...]

-- 
Clément B.


signature.asc
Description: PGP signature
___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-devel


Re: [FFmpeg-devel] [PATCH] ffmpeg/web/index: add news describing GSoC 2015 program outcome

2015-09-27 Thread Ganesh Ajjanagadde
On Sun, Sep 27, 2015 at 11:56 AM, Stefano Sabatini  wrote:
> On date Sunday 2015-09-27 09:44:33 -0400, Ganesh Ajjanagadde encoded:
>> On Sun, Sep 27, 2015 at 8:37 AM, Stefano Sabatini  wrote:
>> > ---
>> >  src/index | 234 
>> > ++
>> >  1 file changed, 234 insertions(+)
> [...]
>> > +  
>> > +During the program he extended the API with possibility to remove and
>> > +rename files on remote servers. He implemented/finished the
>> > +implementation of these features for file, Samba, SFTP, and FTP
>> > +protocols.
>> > +  
>>
>> nit: with possiblity -> with the possibility
>>
>
>> implemented/finished: is the vagueness necessary because some of these
>> were completed and others not? Otherwise, I prefer the more explicit
>> "implemented and finished".
>
> Changed to: finished the implementation (since "implement the
> implementations" sounds ugly/redundant).
>
>>
>> > +
>> > +  
>> > +At the end of the program, Mariusz provided a sketch of implementation
>> > +for HTTP directory listening.
>> > +  
>> > +
>> > +  Directshow digital video capture, mentee: Mate Sebok, mentor: Roger 
>> > Pack
>> > +
>> > +  
>> > +Mate was working on directshow input from digital video sources. He
>> > +got working input from ATSC input sources, with specifiable tuner.
>> > +  
>> > +
>> > +  
>> > +The code has not been committed, but a patch of it was sent to the
>> > +ffmpeg-devel mailing list for future use.
>> > +  
>> > +
>> > +  
>> > +The mentor plans on cleaning it up and committing up, at least for the
>> > +ATSC side of things. Mate and the mentor are still working trying to
>> > +finally figure out how to get DVB working.
>> > +  
>>
>> committing up - never heard this usage, perhaps "committing it" or
>> even a simple "committing"?
>
> => committing it
>
> [...]
>> > +libswscale refactoring, mentee: Pedro Arthur, mentors: Michael 
>> > Niedermayer, Ramiro Polla
>> > +
>> > +  
>> > +Pedro Arthur has modlularized the vertical and horizontal scalers.
>> > +To do this he designed and implemented a generic filter framework
>> > +and moved the existing scaler code into it. These changes now allow
>> > +easily adding removing, splitting or merging processing steps.
>> > +The implementation was benchmarked and several alternatives where
>> > +tried to avoid speedloss.
>> > +  
>>
>> modl.. -> modularized
>> where tried -> were tried
>>
>> > +
>> > +  
>> > +He also added gamma correct scaling support.
>> > +An example to use gamma corrected scaling would be:
>> > +
>> > +  ffmpeg -i input -vf scale=512:384:gamma=1 output
>> > +
>> > +  
>>
>> gamma correct scaling -> gamma corrected scaling
>>
>> > +
>> > +  
>> > +Pedro has done impressive work considering the short time available,
>> > +and he is a FFmpeg comitter now. He continues to contribute to
>> > +FFmpeg, and has fixed some bugs in libswscale after GSoC has
>> > +ended.
>> > +  
>>
>> comitter -> committer
>>
>> > +
>> > +  AAC Encoder Improvements, mentee: Rostislav Pehlivanov, mentor: 
>> > Claudio Freire
>> > +
>> > +  
>> > +Rostislav Pehlivanov has implemented PNS, TNS, I/S coding and main
>> > +prediction on the native AAC encoder. Of all those extensions, only
>> > +TNS was left in a less-than-usable state, but the implementation has
>> > +been pushed (disabled) anyway since it's a good basis for further
>> > +improvements.
>> > +  
>> > +
>> > +  
>> > +PNS replaces noisy bands with a single scalefactor representing the
>> > +energy of that band, gaining in coding efficiency considerably, and
>> > +the quality improvements on low bitrates are impressive for such a
>> > +simple feature.
>> > +  
>> > +
>> > +  
>> > +TNS still needs some polishing, but has the potential to reduce coding
>> > +artifacts by applying noise shaping in the temporal domain (something
>> > +that is a source of annoying, notable distortion on low-entropy
>> > +bands).
>> > +  
>> > +
>> > +  
>> > +Intensity Stereo coding (I/S) can double coding efficiency by
>> > +exploiting strong correlation between stereo channels, most effective
>> > +on pop-style tracks that employ panned mixing. The technique is not as
>> > +effective on classic X-Y recordings though.
>> > +  
>> > +
>> > +  
>> > +Finally, main prediction improves coding efficiency by exploiting
>> > +correlation among successive frames. While the gains have not been
>> > +huge at this point, Rostislav has remained active even after the GSoC,
>> > +and is polishing both TNS and main prediction, as well as looking for
>> > +furhter improvements to make.
>> > +  
>>
>> furhter -> further
>>
>> > +
>> > +  
>> > +In the process, the MIPS port of the encoder was broken a few times,
>> > +something he's also working to fix.

Re: [FFmpeg-devel] Getting timestamp from transport stream

2015-09-27 Thread Stefano Sabatini
On date Saturday 2015-09-26 12:48:33 -0700, Sabur Hassan Baidya encoded:
> Hi,
> 
> I am a newbie to ffmpeg. I created a transport stream from encoded mp4 file
> using ffmpeg command. Now I am trying to send the packets of the transport
> stream over UDP. I found that there are ffmpeg commands for client server
> communication which I tested with the .ts file.
> 
> But I want to control the packets at sender side and want to inject the
> packets manually to some protocol setup.
> 

> So, I wanted to ask if there is any ffmpeg/ffprobe command that gives the
> timestamp of each TS packets in the transport stream.

What's wrong with ffprobe -show_packets?

Also, this mailing-list is about ffmpeg *development*, this question
looks more about ffmpeg-user.
-- 
FFmpeg = Forgiving and Faithful Merciless Proud Extensive Goblin
___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-devel


Re: [FFmpeg-devel] [PATCHv4] ffplay: add support for interactive volume control

2015-09-27 Thread Ganesh Ajjanagadde
On Sun, Sep 27, 2015 at 12:06 PM, Stefano Sabatini  wrote:
> On date Sunday 2015-09-27 10:41:37 -0400, Ganesh Ajjanagadde encoded:
>> This is a feature heavily inspired by the mpv player. At the moment, methods
>> for adjusting volume in ffplay are rather clumsy: either one needs to set it
>> system-wide, or one needs to set it via the volume filter.
>>
>> This patch adds key bindings identical to the mpv defaults for 
>> muting/unmuting
>> and increasing/decreasing the volume interactively without any introduction 
>> of
>> external dependencies.
>>
>
>> TODO: doc update, possible mouse button bindings (mpv has this).
>
> Also update show_help_default() output while at it.

So I am adding it to the doc patch - I consider it ambiguous where it
needs to go - logically it is related to documentation, but it belongs
in the same file as ffplay. I personally like the "logical" split
more, so I have placed it in the doc patch.

>
> [...]
> --
> FFmpeg = Forgiving & Free Multipurpose Philosofic Elaborated Goblin
> ___
> 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


[FFmpeg-devel] [PATCHv2] doc/ffplay, ffplay: add information regarding volume control

2015-09-27 Thread Ganesh Ajjanagadde
ffplay now supports dynamic volume control. This documents the supported
behavior.

Signed-off-by: Ganesh Ajjanagadde 
---
 doc/ffplay.texi | 9 +
 ffplay.c| 3 +++
 2 files changed, 12 insertions(+)

diff --git a/doc/ffplay.texi b/doc/ffplay.texi
index be696c8..2a35c21 100644
--- a/doc/ffplay.texi
+++ b/doc/ffplay.texi
@@ -197,6 +197,15 @@ Toggle full screen.
 @item p, SPC
 Pause.
 
+@item m
+Toggle mute.
+
+@item 9, 0
+Decrease and increase volume respectively.
+
+@item /, *
+Decrease and increase volume respectively.
+
 @item a
 Cycle audio channel in the current program.
 
diff --git a/ffplay.c b/ffplay.c
index 2bb5d26..9016f7b 100644
--- a/ffplay.c
+++ b/ffplay.c
@@ -3647,6 +3647,9 @@ void show_help_default(const char *opt, const char *arg)
"q, ESC  quit\n"
"f   toggle full screen\n"
"p, SPC  pause\n"
+   "m   toggle mute\n"
+   "9, 0decrease and increase volume respectively\n"
+   "/, *decrease and increase volume respectively\n"
"a   cycle audio channel in the current program\n"
"v   cycle video channel\n"
"t   cycle subtitle channel in the current 
program\n"
-- 
2.5.3

___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-devel


Re: [FFmpeg-devel] [PATCH] ffmpeg/web/index: add news describing GSoC 2015 program outcome

2015-09-27 Thread Stefano Sabatini
On date Sunday 2015-09-27 18:26:04 +0200, Moritz Barsnick encoded:
> In addition to the others:
> 
> > +effort. We're looking forward participating to the next GSoC
> 
> looking forward to participating in the next
> 
> > +At the end of the program, Mariusz provided a sketch of implementation
> 
> of an implementation
> 
> > +with overlapping formatting (which other formats support) but Timed
> > +Text does not - so it requires breaking the overlapping sections into
> 

Both fixed.

> I think this is meant to read:
>   with overlapping formatting (which other formats support but Timed Text
>   does not)

> i.e. the "but" (Timed Text text) currently refers to text in the
> brackets.

changed that way.

[...]

Thanks.
-- 
FFmpeg = Faithless and Funny Mystic Perfectionist Entertaining Glue
>From 30992bf2ac753aba638afda96e82bce0b7df654d Mon Sep 17 00:00:00 2001
From: Stefano Sabatini 
Date: Sun, 27 Sep 2015 14:36:16 +0200
Subject: [PATCH] ffmpeg/web/index: add news describing GSoC 2015 program
 outcome

---
 src/index | 234 ++
 1 file changed, 234 insertions(+)

diff --git a/src/index b/src/index
index 9d12a7b..e637b2a 100644
--- a/src/index
+++ b/src/index
@@ -37,6 +37,240 @@
 News
   
 
+  September 27th, 2015, GSoC 2015 results
+
+  
+FFmpeg participated to the latest edition of
+the http://www.google-melange.com/gsoc/homepage/google/gsoc2015;>Google
+Summer of Code Project. FFmpeg got a total of 8 assigned
+projects, and 7 of them were successful.
+  
+
+  We want to thank https://www.google.com;>Google, the
+participating students, and especially the mentors who joined this
+effort. We're looking forward to participating in the next GSoC
+edition!
+  
+
+  
+Below you can find a brief description of the final outcome of
+each single project.
+  
+
+  Basic servers for network protocols, mentee: Stephan Holljes, mentor: Nicolas George
+
+  
+Stephan Holljes's project for this session of Google Summer of Code was to
+implement basic HTTP server features for libavformat, to complement the
+already present HTTP client and RTMP and RTSP server code.
+  
+
+  
+The first part of the project was to make the HTTP code capable of accepting
+a single client; it was completed partly during the qualification period and
+partly during the first week of the summer. Thanks to this work, it is now
+possible to make a simple HTTP stream using the following commands:
+
+  ffmpeg -i /dev/video0 -listen 1 -f matroska \
+  -c:v libx264 -preset fast -tune zerolatency http://:8080
+  ffplay http://localhost:8080/
+
+  
+
+  
+The next part of the project was to extend the code to be able to accept
+several clients, simultaneously or consecutively. Since libavformat did not
+have an API for that kind of task, it was necessary to design one. This part
+was mostly completed before the midterm and applied shortly afterwards.
+Since the ffmpeg command-line tool is not ready to serve several clients,
+the test ground for that new API is an example program serving hard-coded
+content.
+  
+
+  
+The last and most ambitious part of the project was to update ffserver to
+make use of the new API. It would prove that the API is usable to implement
+real HTTP servers, and expose the points where more control was needed. By
+the end of the summer, a first working patch series was undergoing code
+review.
+  
+
+  Browsing content on the server, mentee: Mariusz Szczepańczyk, mentor: Lukasz Marek
+
+  
+Mariusz finished an API prepared by the FFmpeg community and implemented
+Samba directory listing as qualification task.
+  
+
+  
+During the program he extended the API with the possibility to
+remove and rename files on remote servers. He completed the
+implementation of these features for file, Samba, SFTP, and FTP
+protocols.
+  
+
+  
+At the end of the program, Mariusz provided a sketch of an
+implementation for HTTP directory listening.
+  
+
+  Directshow digital video capture, mentee: Mate Sebok, mentor: Roger Pack
+
+  
+Mate was working on directshow input from digital video sources. He
+got working input from ATSC input sources, with specifiable tuner.
+  
+
+  
+The code has not been committed, but a patch of it was sent to the
+ffmpeg-devel mailing list for future use.
+  
+
+  
+The mentor plans on cleaning it up and committing it, at least for the
+ATSC side of things. Mate and the mentor are still working trying to
+finally figure out how to get DVB working.
+  
+
+  Implementing full support for 3GPP Timed Text Subtitles, mentee: Niklesh Lalwani, mentors: Philip Langdale
+
+  
+Niklesh's project was to expand our support for 3GPP Timed Text
+subtitles. This is the native subtitle format for mp4 containers, and
+is interesting 

Re: [FFmpeg-devel] [PATCH] doc/ffplay: add information regarding volume control

2015-09-27 Thread Ganesh Ajjanagadde
On Sun, Sep 27, 2015 at 10:38 AM, Ganesh Ajjanagadde
 wrote:
> ffplay now supports dynamic volume control. This documents the supported
> behavior.
>
> Signed-off-by: Ganesh Ajjanagadde 
> ---
>  doc/ffplay.texi | 9 +
>  1 file changed, 9 insertions(+)
>
> diff --git a/doc/ffplay.texi b/doc/ffplay.texi
> index be696c8..2a35c21 100644
> --- a/doc/ffplay.texi
> +++ b/doc/ffplay.texi
> @@ -197,6 +197,15 @@ Toggle full screen.
>  @item p, SPC
>  Pause.
>
> +@item m
> +Toggle mute.
> +
> +@item 9, 0
> +Decrease and increase volume respectively.
> +
> +@item /, *
> +Decrease and increase volume respectively.
> +
>  @item a
>  Cycle audio channel in the current program.
>
> --
> 2.5.3
>

oops, wrong patch
___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-devel


Re: [FFmpeg-devel] [PATCHv2 1/2] ffplay: add support for interactive volume control

2015-09-27 Thread Ganesh Ajjanagadde
On Sun, Sep 27, 2015 at 10:12 AM, Ganesh Ajjanagadde  wrote:
> On Sun, Sep 27, 2015 at 9:57 AM, Clément Bœsch  wrote:
>> On Sat, Sep 26, 2015 at 11:36:42AM -0400, Ganesh Ajjanagadde wrote:
>> [...]
>>> -memcpy(stream, (uint8_t *)is->audio_buf + is->audio_buf_index, 
>>> len1);
>>> +if (is->muted)
>>> +memset(stream, 0, len1);
>>
>> This doesn't work with u8 sampling.
>
> Do you know of any clean alternative? For instance, is it possible to
> obtain the zero point of the stream from some stream field?

Found one myself, see updated patch. I tested against u8 sample file
tests/data/fate/acodec-pcm-u8.wav.

>
>>
>> Would it make sense to insert + reconfigure a volume filter instead or
>> it's too complicated?
>
> Yes, I consider the current usage terrible unless I am missing
> something. volume filter is static, so once set, I can't adjust the
> volume until I reinsert a new volume filter, etc. I can't simply
> adjust the volume like I can with vlc/mpv with a simple keybinding.
>
>>
>> [...]
>>
>> --
>> Clément B.
>>
>> ___
>> 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


[FFmpeg-devel] [PATCHv4] ffplay: add support for interactive volume control

2015-09-27 Thread Ganesh Ajjanagadde
This is a feature heavily inspired by the mpv player. At the moment, methods
for adjusting volume in ffplay are rather clumsy: either one needs to set it
system-wide, or one needs to set it via the volume filter.

This patch adds key bindings identical to the mpv defaults for muting/unmuting
and increasing/decreasing the volume interactively without any introduction of
external dependencies.

TODO: doc update, possible mouse button bindings (mpv has this).

Signed-off-by: Ganesh Ajjanagadde 
---
 ffplay.c | 36 +++-
 1 file changed, 35 insertions(+), 1 deletion(-)

diff --git a/ffplay.c b/ffplay.c
index 2bb5d26..21600d0 100644
--- a/ffplay.c
+++ b/ffplay.c
@@ -73,6 +73,9 @@ const int program_birth_year = 2003;
 /* Calculate actual buffer size keeping in mind not cause too frequent audio 
callbacks */
 #define SDL_AUDIO_MAX_CALLBACKS_PER_SEC 30
 
+/* Step size for volume control */
+#define SDL_VOLUME_STEP (SDL_MIX_MAXVOLUME / 50)
+
 /* no AV sync correction is done if below the minimum AV sync threshold */
 #define AV_SYNC_THRESHOLD_MIN 0.04
 /* AV sync correction is done if above the maximum AV sync threshold */
@@ -246,6 +249,8 @@ typedef struct VideoState {
 unsigned int audio_buf1_size;
 int audio_buf_index; /* in bytes */
 int audio_write_buf_size;
+int audio_volume;
+int muted;
 struct AudioParams audio_src;
 #if CONFIG_AVFILTER
 struct AudioParams audio_filter_src;
@@ -1349,6 +1354,16 @@ static void toggle_pause(VideoState *is)
 is->step = 0;
 }
 
+static void toggle_mute(VideoState *is)
+{
+is->muted = !is->muted;
+}
+
+static void update_volume(VideoState *is, int sign, int step)
+{
+is->audio_volume = av_clip(is->audio_volume + sign * step, 0, 
SDL_MIX_MAXVOLUME);
+}
+
 static void step_to_next_frame(VideoState *is)
 {
 /* if the stream is paused unpause it, then step */
@@ -2448,7 +2463,13 @@ static void sdl_audio_callback(void *opaque, Uint8 
*stream, int len)
 len1 = is->audio_buf_size - is->audio_buf_index;
 if (len1 > len)
 len1 = len;
-memcpy(stream, (uint8_t *)is->audio_buf + is->audio_buf_index, len1);
+if (!is->muted && is->audio_volume == SDL_MIX_MAXVOLUME)
+memcpy(stream, (uint8_t *)is->audio_buf + is->audio_buf_index, 
len1);
+else {
+memset(stream, is->silence_buf[0], len1);
+if (!is->muted)
+SDL_MixAudio(stream, (uint8_t *)is->audio_buf + 
is->audio_buf_index, len1, is->audio_volume);
+}
 len -= len1;
 stream += len1;
 is->audio_buf_index += len1;
@@ -3125,6 +3146,8 @@ static VideoState *stream_open(const char *filename, 
AVInputFormat *iformat)
 init_clock(>audclk, >audioq.serial);
 init_clock(>extclk, >extclk.serial);
 is->audio_clock_serial = -1;
+is->audio_volume = SDL_MIX_MAXVOLUME;
+is->muted = 0;
 is->av_sync_type = av_sync_type;
 is->read_tid = SDL_CreateThread(read_thread, is);
 if (!is->read_tid) {
@@ -3314,6 +3337,17 @@ static void event_loop(VideoState *cur_stream)
 case SDLK_SPACE:
 toggle_pause(cur_stream);
 break;
+case SDLK_m:
+toggle_mute(cur_stream);
+break;
+case SDLK_KP_MULTIPLY:
+case SDLK_0:
+update_volume(cur_stream, 1, SDL_VOLUME_STEP);
+break;
+case SDLK_KP_DIVIDE:
+case SDLK_9:
+update_volume(cur_stream, -1, SDL_VOLUME_STEP);
+break;
 case SDLK_s: // S: Step to next frame
 step_to_next_frame(cur_stream);
 break;
-- 
2.5.3

___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-devel


Re: [FFmpeg-devel] [PATCHv2 1/2] ffplay: add support for interactive volume control

2015-09-27 Thread Ganesh Ajjanagadde
On Sun, Sep 27, 2015 at 10:40 AM, Ganesh Ajjanagadde  wrote:
> On Sun, Sep 27, 2015 at 10:12 AM, Ganesh Ajjanagadde  wrote:
>> On Sun, Sep 27, 2015 at 9:57 AM, Clément Bœsch  wrote:
>>> On Sat, Sep 26, 2015 at 11:36:42AM -0400, Ganesh Ajjanagadde wrote:
>>> [...]
 -memcpy(stream, (uint8_t *)is->audio_buf + is->audio_buf_index, 
 len1);
 +if (is->muted)
 +memset(stream, 0, len1);
>>>
>>> This doesn't work with u8 sampling.
>>
>> Do you know of any clean alternative? For instance, is it possible to
>> obtain the zero point of the stream from some stream field?
>
> Found one myself, see updated patch. I tested against u8 sample file
> tests/data/fate/acodec-pcm-u8.wav.

I can clarify this further: actually patchv4 (the latest) and the v3
and below to which the comment refers to are both correct, and in fact
silence_buf[0] = 0 currently. I still like v4 more since it is more
explicit in intent.

Here is why the code is correct. Lines 2511 or so set the
SDL_AudioSpec: https://wiki.libsdl.org/SDL_AudioSpec to signed 16
bits. It is irrelevant what the actual audio format is, I assume
something takes care of internal conversions to the desired format. 0
indeed represents silence.

That being said, I don't know where the wanted_spec.silence and really
spec.silence are being used to set the silence_buf uniformly to the
silence value. I will look into this and post a separate patch if it
is not being done.

>
>>
>>>
>>> Would it make sense to insert + reconfigure a volume filter instead or
>>> it's too complicated?
>>
>> Yes, I consider the current usage terrible unless I am missing
>> something. volume filter is static, so once set, I can't adjust the
>> volume until I reinsert a new volume filter, etc. I can't simply
>> adjust the volume like I can with vlc/mpv with a simple keybinding.
>>
>>>
>>> [...]
>>>
>>> --
>>> Clément B.
>>>
>>> ___
>>> 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] avformat/movenc: suppress -Wstrict-overflow warnings

2015-09-27 Thread Ganesh Ajjanagadde
On Sun, Sep 27, 2015 at 12:58 PM, Michael Niedermayer  wrote:
> On Sat, Sep 26, 2015 at 10:55:26PM -0400, Ganesh Ajjanagadde wrote:
>> On Sat, Sep 26, 2015 at 10:32 PM, Ronald S. Bultje  
>> wrote:
>> > Hi,
>> >
>> > On Sat, Sep 26, 2015 at 7:19 PM, Ganesh Ajjanagadde 
>> > wrote:
>> >
>> >> On Sat, Sep 26, 2015 at 7:11 PM, Michael Niedermayer 
>> >> wrote:
>> >> > On Fri, Sep 18, 2015 at 05:15:50PM -0400, Ganesh Ajjanagadde wrote:
>> >> >> This patch results in identical behavior of movenc, and suppresses
>> >> -Wstrict-overflow
>> >> >> warnings observed in GCC 5.2.
>> >> >> I have manually checked that all usages are safe, and overflow
>> >> possibility does
>> >> >> not exist with this expression rewrite.
>> >> >>
>> >> >> Signed-off-by: Ganesh Ajjanagadde 
>> >> >> ---
>> >> >>  libavformat/movenc.c | 2 +-
>> >> >>  1 file changed, 1 insertion(+), 1 deletion(-)
>> >> >>
>> >> >> diff --git a/libavformat/movenc.c b/libavformat/movenc.c
>> >> >> index af03d1e..6e4a1a6 100644
>> >> >> --- a/libavformat/movenc.c
>> >> >> +++ b/libavformat/movenc.c
>> >> >> @@ -854,7 +854,7 @@ static int get_cluster_duration(MOVTrack *track,
>> >> int cluster_idx)
>> >> >>  {
>> >> >>  int64_t next_dts;
>> >> >>
>> >> >> -if (cluster_idx >= track->entry)
>> >> >> +if (cluster_idx - track->entry >= 0)
>> >> >
>> >> > i do not understand what this fixes or why
>> >> > also plese quote the actual warnings which are fixed in the commit
>> >> > message
>> >>
>> >> I have posted v2 with a more detailed commit message. It should be
>> >> self explanatory.
>> >
>> >
>> > Even with the new message, it's still not clear to me what's being fixed.
>> > What does the warning check for? What is the problem in the initial
>> > expression?
>>
>> Compilers make transformations on the statements in order to possibly
>> get better performance when compiled with optimizations. However, some
>> of these optimizations require assumptions in the code. In particular,
>> the compiler is internally rewriting cluster_idx >= track->entry to
>> cluster_idx - track->entry >= 0 internally for some reason (I am not
>> an asm/instruction set guy, so I can't comment why it likes this).
>> However, such a transformation is NOT always safe as integer
>> arithmetic can overflow (try e.g extreme values close to INT_MIN,
>> INT_MAX). The warning is spit out since the compiler can't be sure
>> that this is safe, but it still wants to do it (I suspect only the
>> -O3/-O2 level that try this, can check if you want).
>
> iam not sure i understand correctly but
> if the compiler changes the code and then warns that what it just
> did might be unsafe then the compiler is broken

https://stackoverflow.com/questions/12984861/dont-understand-assuming-signed-overflow-warning
- gives a detailed explanation.

Some more info: this is triggered only when -finline-functions is
enabled (done by default on -O3, not enabled by default on -O2).
-finline-functions tries to inline stuff even when "inline" keyword is
absent (like in this case).
As for the warning, http://linux.die.net/man/1/gcc - search for
-Wstrict-overflow. It is enabled due to -Wall, and as the man page
suggests, it depends on optimization level as we can see in this
example.
I do consider the compiler broken in this case, but then again
compilers are broken in so many different ways it is not even funny:
see e.g -Warray-bounds, can't use the ISO C correct { 0 } initializer
for compound data types, etc.

If you don't like this, we should add a -Wnostrict-overflow either to
configure, or a local enable/disable via pragmas/macros. I don't like
either of these as compared to this simple workaround:
1. -Wnostrict-overflow: FFmpeg with the amount of integer arithmetic
being done should benefit from this warning in general, so disabling
it globally may be bad.
2. local enable/disable: too ugly and overkill when we need only 2
lines to be changed in trivial ways throughout the codebase: movenc
and xface. IMO, we should consider this only if we run into more false
positives.

>
> [...]
> --
> Michael GnuPG fingerprint: 9FF2128B147EF6730BADF133611EC787040B0FAB
>
> I know you won't believe me, but the highest form of Human Excellence is
> to question oneself and others. -- Socrates
>
> ___
> 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


[FFmpeg-devel] [PATCH] ffmpeg/web/index: add news describing GSoC 2015 program outcome

2015-09-27 Thread Stefano Sabatini
---
 src/index | 234 ++
 1 file changed, 234 insertions(+)

diff --git a/src/index b/src/index
index 9d12a7b..8937172 100644
--- a/src/index
+++ b/src/index
@@ -37,6 +37,240 @@
 News
   
 
+  September 27th, 2015, GSoC 2015 results
+
+  
+FFmpeg participated to the latest edition of
+the http://www.google-melange.com/gsoc/homepage/google/gsoc2015;>Google
+Summer of Code Project. FFmpeg got a total of 8 assigned
+projects, and 7 of them were successfull.
+  
+
+  We want to thank https://www.google.com;>Google, the
+participating students, and especially the mentors who joined this
+effort. We're looking forward participating to the next GSoC
+edition!
+  
+
+  
+Below you can find a brief description of the final outcome of
+each single project.
+  
+
+  Basic servers for network protocols, mentee: klaxa, mentor: Nicolas 
George
+
+  
+Stephan Holljes's project for this session of Google Summer of Code was to
+implement basic HTTP server features for libavformat, to complement the
+already present HTTP client and RTMP and RTSP server code.
+  
+
+  
+The first part of the project was to make the HTTP code capable of 
accepting
+a single client; it was completed partly during the qualification period 
and
+partly during the first week of the summer. Thanks to this work, it is now
+possible to make a simple HTTP stream using the following commands:
+
+  ffmpeg -i /dev/video0 -listen 1 -f matroska \
+  -c:v libx264 -preset fast -tune zerolatency http://:8080
+  ffplay http://localhost:8080/
+
+  
+
+  
+The next part of the project was to extend the code to be able to accept
+several clients, simultaneously or consecutively. Since libavformat did not
+have an API for that kind of task, it was necessary to design on. This part
+was mostly completed before the midterm and applied shortly afterwards.
+Since the ffmpeg command-line tool is not ready to serve several clients,
+the test ground for that new API is an example program serving hard-coded
+content.
+  
+
+  
+The last and most ambitious part of the project was to update ffserver to
+make use of the new API. It would prove that the API is usable to implement
+real HTTP servers, and expose the points where more control was needed. By
+the end of the summer, a first working patch series was undergoing code
+review.
+  
+
+  Browsing content on the server, mentee: Mariusz Szczepańczyk, mentor: 
Lukasz Marek
+
+  
+Mariusz finished an API prepared by FFmpeg community and implemented
+Samba directory listing as qualification task.
+  
+
+  
+During the program he extended the API with possibility to remove and
+rename files on remote servers. He implemented/finished the
+implementation of these features for file, Samba, SFTP, and FTP
+protocols.
+  
+
+  
+At the end of the program, Mariusz provided a sketch of implementation
+for HTTP directory listening.
+  
+
+  Directshow digital video capture, mentee: Mate Sebok, mentor: Roger 
Pack
+
+  
+Mate was working on directshow input from digital video sources. He
+got working input from ATSC input sources, with specifiable tuner.
+  
+
+  
+The code has not been committed, but a patch of it was sent to the
+ffmpeg-devel mailing list for future use.
+  
+
+  
+The mentor plans on cleaning it up and committing up, at least for the
+ATSC side of things. Mate and the mentor are still working trying to
+finally figure out how to get DVB working.
+  
+
+  Implementing full support for 3GPP Timed Text Subtitles, mentee: Niklesh 
Lalwani, mentors: Philip Langdale
+
+  
+Niklesh's project was to expand our support for 3GPP Timed Text
+subtitles. This is the native subtitle format for mp4 containers, and
+is interesting because it's usually the only subtitle format supported
+by the stock playback applications on iOS and Android devices.
+  
+
+  
+ffmpeg already had basic support for these subtitles which ignored all
+formatting information - it just provided basic plain-text support.
+  
+
+  
+Niklesh did work to add support on both the encode and decode side for
+text formatting capabilities, such as font size/colour and effects like
+bold/italics, highlighting, etc.
+  
+
+  
+The main challenge here is that Timed Text handles formatting in a very
+different way from most common subtitle formats. It uses a binary
+encoding (based on mp4 boxes, naturally) and stores information
+separately from the text itself. This requires additional work to track
+which parts of the text formatting applies to, and explicitly dealing
+with overlapping formatting (which other formats support) but Timed
+Text does not - so it requires breaking the overlapping sections into
+separate non-overlapping ones with 

Re: [FFmpeg-devel] [PATCH 3/3] configure: Disable automatic image base calculation

2015-09-27 Thread Hendrik Leppkes
On Mon, Sep 21, 2015 at 6:41 AM, Alex Smith  wrote:
> From: Alex Smith 
>
> There's no reason for it.  ASLR will rebase it regardless so "preventing
> collisions" isn't really relevant.  This also brings it in line with
> what a msvc produced dll will have (an image base of 0x1000).
>
> Signed-off-by: Alex Smith 
> ---
>  configure | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/configure b/configure
> index 0c60c03..a540ae7 100755
> --- a/configure
> +++ b/configure
> @@ -4386,7 +4386,7 @@ case $target_os in
>  SLIB_INSTALL_LINKS=
>  SLIB_INSTALL_EXTRA_SHLIB='$(SLIBNAME:$(SLIBSUF)=.lib)'
>  SLIB_INSTALL_EXTRA_LIB='lib$(SLIBNAME:$(SLIBSUF)=.dll.a) 
> $(SLIBNAME_WITH_MAJOR:$(SLIBSUF)=.def)'
> -SHFLAGS='-shared -Wl,--output-def,$$(@:$(SLIBSUF)=.orig.def) 
> -Wl,--out-implib,$(SUBDIR)lib$(SLIBNAME:$(SLIBSUF)=.dll.a) 
> -Wl,--enable-runtime-pseudo-reloc -Wl,--enable-auto-image-base'
> +SHFLAGS='-shared -Wl,--output-def,$$(@:$(SLIBSUF)=.orig.def) 
> -Wl,--out-implib,$(SUBDIR)lib$(SLIBNAME:$(SLIBSUF)=.dll.a) 
> -Wl,--enable-runtime-pseudo-reloc -Wl,--disable-auto-image-base'
>  objformat="win32"
>  ranlib=:
>  enable dos_paths
> --
> 1.9.5.msysgit.0

LGTM, as it matches msvc afterwards.

- Hendrik
___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-devel


Re: [FFmpeg-devel] [PATCH]h264: Fix ticket #3147 H264 - Wrong field order

2015-09-27 Thread Thomas Mundt
Fate always stops at vf_mergeplanes with error, with or without my 
patch:[AVFilterGraph @ 00eb4500] No such filter: ''
Error initializing complex filters.
Invalid argument
Is there a way to limit fate that it just checks h264 part?



 Kieran Kunhya  schrieb am 13:23 Sonntag, 27.September 2015:
   

 On 27 September 2015 at 09:09, Thomas Mundt
 wrote:
> Hi Kieran,
> no, you´re right. I misinterpreted SEI_PIC_STRUCT_FRAME because it´s also the 
> default when pic_struct_present_flag is 0. Just checked avci header - no 
> pic_struct_present_flag. Sorry!But fixing avci field order detection should 
> be done.Does attached patch make more sense to you?
> Regards,Thomas

Hi,

Yes patch makes sense assuming it doesn't break fate etc.

Kieran
___
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] ffmpeg/web/index: add news describing GSoC 2015 program outcome

2015-09-27 Thread Stefano Sabatini
On date Sunday 2015-09-27 09:44:33 -0400, Ganesh Ajjanagadde encoded:
> On Sun, Sep 27, 2015 at 8:37 AM, Stefano Sabatini  wrote:
> > ---
> >  src/index | 234 
> > ++
> >  1 file changed, 234 insertions(+)
[...]
> > +  
> > +During the program he extended the API with possibility to remove and
> > +rename files on remote servers. He implemented/finished the
> > +implementation of these features for file, Samba, SFTP, and FTP
> > +protocols.
> > +  
> 
> nit: with possiblity -> with the possibility
> 

> implemented/finished: is the vagueness necessary because some of these
> were completed and others not? Otherwise, I prefer the more explicit
> "implemented and finished".

Changed to: finished the implementation (since "implement the
implementations" sounds ugly/redundant).

> 
> > +
> > +  
> > +At the end of the program, Mariusz provided a sketch of implementation
> > +for HTTP directory listening.
> > +  
> > +
> > +  Directshow digital video capture, mentee: Mate Sebok, mentor: Roger 
> > Pack
> > +
> > +  
> > +Mate was working on directshow input from digital video sources. He
> > +got working input from ATSC input sources, with specifiable tuner.
> > +  
> > +
> > +  
> > +The code has not been committed, but a patch of it was sent to the
> > +ffmpeg-devel mailing list for future use.
> > +  
> > +
> > +  
> > +The mentor plans on cleaning it up and committing up, at least for the
> > +ATSC side of things. Mate and the mentor are still working trying to
> > +finally figure out how to get DVB working.
> > +  
> 
> committing up - never heard this usage, perhaps "committing it" or
> even a simple "committing"?

=> committing it

[...]
> > +libswscale refactoring, mentee: Pedro Arthur, mentors: Michael 
> > Niedermayer, Ramiro Polla
> > +
> > +  
> > +Pedro Arthur has modlularized the vertical and horizontal scalers.
> > +To do this he designed and implemented a generic filter framework
> > +and moved the existing scaler code into it. These changes now allow
> > +easily adding removing, splitting or merging processing steps.
> > +The implementation was benchmarked and several alternatives where
> > +tried to avoid speedloss.
> > +  
> 
> modl.. -> modularized
> where tried -> were tried
> 
> > +
> > +  
> > +He also added gamma correct scaling support.
> > +An example to use gamma corrected scaling would be:
> > +
> > +  ffmpeg -i input -vf scale=512:384:gamma=1 output
> > +
> > +  
> 
> gamma correct scaling -> gamma corrected scaling
> 
> > +
> > +  
> > +Pedro has done impressive work considering the short time available,
> > +and he is a FFmpeg comitter now. He continues to contribute to
> > +FFmpeg, and has fixed some bugs in libswscale after GSoC has
> > +ended.
> > +  
> 
> comitter -> committer
> 
> > +
> > +  AAC Encoder Improvements, mentee: Rostislav Pehlivanov, mentor: 
> > Claudio Freire
> > +
> > +  
> > +Rostislav Pehlivanov has implemented PNS, TNS, I/S coding and main
> > +prediction on the native AAC encoder. Of all those extensions, only
> > +TNS was left in a less-than-usable state, but the implementation has
> > +been pushed (disabled) anyway since it's a good basis for further
> > +improvements.
> > +  
> > +
> > +  
> > +PNS replaces noisy bands with a single scalefactor representing the
> > +energy of that band, gaining in coding efficiency considerably, and
> > +the quality improvements on low bitrates are impressive for such a
> > +simple feature.
> > +  
> > +
> > +  
> > +TNS still needs some polishing, but has the potential to reduce coding
> > +artifacts by applying noise shaping in the temporal domain (something
> > +that is a source of annoying, notable distortion on low-entropy
> > +bands).
> > +  
> > +
> > +  
> > +Intensity Stereo coding (I/S) can double coding efficiency by
> > +exploiting strong correlation between stereo channels, most effective
> > +on pop-style tracks that employ panned mixing. The technique is not as
> > +effective on classic X-Y recordings though.
> > +  
> > +
> > +  
> > +Finally, main prediction improves coding efficiency by exploiting
> > +correlation among successive frames. While the gains have not been
> > +huge at this point, Rostislav has remained active even after the GSoC,
> > +and is polishing both TNS and main prediction, as well as looking for
> > +furhter improvements to make.
> > +  
> 
> furhter -> further
> 
> > +
> > +  
> > +In the process, the MIPS port of the encoder was broken a few times,
> > +something he's also working to fix.
> > +  
> > +
> > +  Animated Portable Network Graphics (APNG), mentee: Donny Yang, 
> > mentor: Paul B Mahol
> > +
> > +  
> > +Donny Yang implemented basic keyframe only APNG encoder as 
> > qualification

Re: [FFmpeg-devel] [PATCH] ffmpeg/web/index: add news describing GSoC 2015 program outcome

2015-09-27 Thread James Darnley
On 2015-09-27 14:37, Stefano Sabatini wrote:
> ---
>  src/index | 234 
> ++
>  1 file changed, 234 insertions(+)
> 
> diff --git a/src/index b/src/index
> index 9d12a7b..8937172 100644
> --- a/src/index
> +++ b/src/index
> @@ -37,6 +37,240 @@
>  News
>
>  
> +  September 27th, 2015, GSoC 2015 
> results
> +
> +  
> +FFmpeg participated to the latest edition of
> +the  href="http://www.google-melange.com/gsoc/homepage/google/gsoc2015;>Google
> +Summer of Code Project. FFmpeg got a total of 8 assigned
> +projects, and 7 of them were successfull.
^^^
successful

> +  
> +
> +  We want to thank https://www.google.com;>Google, the
> +participating students, and especially the mentors who joined this
> +effort. We're looking forward participating to the next GSoC
> +edition!
> +  
> +
> +  
> +Below you can find a brief description of the final outcome of
> +each single project.
> +  
> +
> +  Basic servers for network protocols, mentee: klaxa, mentor: Nicolas 
> George
> +
> +  
> +Stephan Holljes's project for this session of Google Summer of Code was 
> to

Are you deliberately using an IRC nick and a name separately here?

> +implement basic HTTP server features for libavformat, to complement the
> +already present HTTP client and RTMP and RTSP server code.
> +  
> +
> +  
> +The first part of the project was to make the HTTP code capable of 
> accepting
> +a single client; it was completed partly during the qualification period 
> and
> +partly during the first week of the summer. Thanks to this work, it is 
> now
> +possible to make a simple HTTP stream using the following commands:
> +
> +  ffmpeg -i /dev/video0 -listen 1 -f matroska \
> +  -c:v libx264 -preset fast -tune zerolatency http://:8080
> +  ffplay http://localhost:8080/
> +
> +  
> +
> +  
> +The next part of the project was to extend the code to be able to accept
> +several clients, simultaneously or consecutively. Since libavformat did 
> not
> +have an API for that kind of task, it was necessary to design on. This 
> part

"it was necessary to design on" does not read very well.  Perhaps it
should be "it was necessary to design _it_"

> +was mostly completed before the midterm and applied shortly afterwards.
> +Since the ffmpeg command-line tool is not ready to serve several clients,
> +the test ground for that new API is an example program serving hard-coded
> +content.
> +  
> +
> +  
> +The last and most ambitious part of the project was to update ffserver to
> +make use of the new API. It would prove that the API is usable to 
> implement
> +real HTTP servers, and expose the points where more control was needed. 
> By
> +the end of the summer, a first working patch series was undergoing code
> +review.
> +  
> +
> +  Browsing content on the server, mentee: Mariusz Szczepańczyk, mentor: 
> Lukasz Marek
> +
> +  
> +Mariusz finished an API prepared by FFmpeg community and implemented
> +Samba directory listing as qualification task.
> +  
> +
> +  
> +During the program he extended the API with possibility to remove and
> +rename files on remote servers. He implemented/finished the
> +implementation of these features for file, Samba, SFTP, and FTP
> +protocols.
> +  
> +
> +  
> +At the end of the program, Mariusz provided a sketch of implementation
> +for HTTP directory listening.
> +  
> +
> +  Directshow digital video capture, mentee: Mate Sebok, mentor: Roger 
> Pack
> +
> +  
> +Mate was working on directshow input from digital video sources. He
> +got working input from ATSC input sources, with specifiable tuner.
> +  
> +
> +  
> +The code has not been committed, but a patch of it was sent to the
> +ffmpeg-devel mailing list for future use.
> +  
> +
> +  
> +The mentor plans on cleaning it up and committing up, at least for the
> +ATSC side of things. Mate and the mentor are still working trying to
> +finally figure out how to get DVB working.
> +  
> +
> +  Implementing full support for 3GPP Timed Text Subtitles, mentee: 
> Niklesh Lalwani, mentors: Philip Langdale
> +
> +  
> +Niklesh's project was to expand our support for 3GPP Timed Text
> +subtitles. This is the native subtitle format for mp4 containers, and
> +is interesting because it's usually the only subtitle format supported
> +by the stock playback applications on iOS and Android devices.
> +  
> +
> +  
> +ffmpeg already had basic support for these subtitles which ignored all
> +formatting information - it just provided basic plain-text support.
> +  
> +
> +  
> +Niklesh did work to add support on both the encode and decode side for
> +text formatting capabilities, such as font size/colour and effects like
> +bold/italics, 

Re: [FFmpeg-devel] [PATCH] ffmpeg/web/index: add news describing GSoC 2015 program outcome

2015-09-27 Thread Ganesh Ajjanagadde
On Sun, Sep 27, 2015 at 8:37 AM, Stefano Sabatini  wrote:
> ---
>  src/index | 234 
> ++
>  1 file changed, 234 insertions(+)
>
> diff --git a/src/index b/src/index
> index 9d12a7b..8937172 100644
> --- a/src/index
> +++ b/src/index
> @@ -37,6 +37,240 @@
>  News
>
>
> +  September 27th, 2015, GSoC 2015 
> results
> +
> +  
> +FFmpeg participated to the latest edition of
> +the  href="http://www.google-melange.com/gsoc/homepage/google/gsoc2015;>Google
> +Summer of Code Project. FFmpeg got a total of 8 assigned
> +projects, and 7 of them were successfull.
> +  
> +
> +  We want to thank https://www.google.com;>Google, the
> +participating students, and especially the mentors who joined this
> +effort. We're looking forward participating to the next GSoC
> +edition!
> +  
> +
> +  
> +Below you can find a brief description of the final outcome of
> +each single project.
> +  
> +
> +  Basic servers for network protocols, mentee: klaxa, mentor: Nicolas 
> George

any reason real name of the mentee is not used here but is used in the
body para?

> +
> +  
> +Stephan Holljes's project for this session of Google Summer of Code was 
> to
> +implement basic HTTP server features for libavformat, to complement the
> +already present HTTP client and RTMP and RTSP server code.
> +  
> +
> +  
> +The first part of the project was to make the HTTP code capable of 
> accepting
> +a single client; it was completed partly during the qualification period 
> and
> +partly during the first week of the summer. Thanks to this work, it is 
> now
> +possible to make a simple HTTP stream using the following commands:
> +
> +  ffmpeg -i /dev/video0 -listen 1 -f matroska \
> +  -c:v libx264 -preset fast -tune zerolatency http://:8080
> +  ffplay http://localhost:8080/
> +
> +  
> +
> +  
> +The next part of the project was to extend the code to be able to accept
> +several clients, simultaneously or consecutively. Since libavformat did 
> not
> +have an API for that kind of task, it was necessary to design on. This 
> part
> +was mostly completed before the midterm and applied shortly afterwards.
> +Since the ffmpeg command-line tool is not ready to serve several clients,
> +the test ground for that new API is an example program serving hard-coded
> +content.
> +  

design on -> design one

> +
> +  
> +The last and most ambitious part of the project was to update ffserver to
> +make use of the new API. It would prove that the API is usable to 
> implement
> +real HTTP servers, and expose the points where more control was needed. 
> By
> +the end of the summer, a first working patch series was undergoing code
> +review.
> +  
> +
> +  Browsing content on the server, mentee: Mariusz Szczepańczyk, mentor: 
> Lukasz Marek
> +
> +  
> +Mariusz finished an API prepared by FFmpeg community and implemented
> +Samba directory listing as qualification task.

nit: by FFmpeg community -> by the FFmpeg community

> +  
> +
> +  
> +During the program he extended the API with possibility to remove and
> +rename files on remote servers. He implemented/finished the
> +implementation of these features for file, Samba, SFTP, and FTP
> +protocols.
> +  

nit: with possiblity -> with the possibility

implemented/finished: is the vagueness necessary because some of these
were completed and others not? Otherwise, I prefer the more explicit
"implemented and finished".

> +
> +  
> +At the end of the program, Mariusz provided a sketch of implementation
> +for HTTP directory listening.
> +  
> +
> +  Directshow digital video capture, mentee: Mate Sebok, mentor: Roger 
> Pack
> +
> +  
> +Mate was working on directshow input from digital video sources. He
> +got working input from ATSC input sources, with specifiable tuner.
> +  
> +
> +  
> +The code has not been committed, but a patch of it was sent to the
> +ffmpeg-devel mailing list for future use.
> +  
> +
> +  
> +The mentor plans on cleaning it up and committing up, at least for the
> +ATSC side of things. Mate and the mentor are still working trying to
> +finally figure out how to get DVB working.
> +  

committing up - never heard this usage, perhaps "committing it" or
even a simple "committing"?

> +
> +  Implementing full support for 3GPP Timed Text Subtitles, mentee: 
> Niklesh Lalwani, mentors: Philip Langdale
> +
> +  
> +Niklesh's project was to expand our support for 3GPP Timed Text
> +subtitles. This is the native subtitle format for mp4 containers, and
> +is interesting because it's usually the only subtitle format supported
> +by the stock playback applications on iOS and Android devices.
> +  
> +
> +  
> +ffmpeg already had basic support for these subtitles which ignored all
> +

Re: [FFmpeg-devel] [PATCHv2 1/2] ffplay: add support for interactive volume control

2015-09-27 Thread Clément Bœsch
On Sun, Sep 27, 2015 at 10:12:52AM -0400, Ganesh Ajjanagadde wrote:
[...]
> Yes, I consider the current usage terrible unless I am missing
> something. volume filter is static, so once set, I can't adjust the
> volume until I reinsert a new volume filter, etc. I can't simply
> adjust the volume like I can with vlc/mpv with a simple keybinding.
> 

There is a process_command() mechanism too if you want to change settings
on the fly

-- 
Clément B.


signature.asc
Description: PGP signature
___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-devel


Re: [FFmpeg-devel] [PATCH] libx264: copy A53 closed captions from source

2015-09-27 Thread DeHackEd
Assumes 'GA94' format (ATSC standard)

Signed-off-by: DHE 
---
 doc/encoders.texi|  4 
 libavcodec/libx264.c | 46 ++
 2 files changed, 50 insertions(+)

diff --git a/doc/encoders.texi b/doc/encoders.texi
index 3550bcc..f2d46dc 100644
--- a/doc/encoders.texi
+++ b/doc/encoders.texi
@@ -2069,6 +2069,10 @@ For example to specify libx264 encoding options with 
@command{ffmpeg}:
 ffmpeg -i foo.mpg -vcodec libx264 -x264opts keyint=123:min-keyint=20 -an 
out.mkv
 @end example
 
+@item a53cc @var{boolean}
+Import closed captions (which must be ATSC compatible format) into output.
+Only the mpeg2 and h264 decoders provide these. Default is 0 (off).
+
 @item x264-params (N.A.)
 Override the x264 configuration using a :-separated list of key=value
 parameters.
diff --git a/libavcodec/libx264.c b/libavcodec/libx264.c
index 58fcfb0..9dc342a 100644
--- a/libavcodec/libx264.c
+++ b/libavcodec/libx264.c
@@ -83,6 +83,7 @@ typedef struct X264Context {
 int avcintra_class;
 int motion_est;
 int forced_idr;
+int a53_cc;
 char *x264_params;
 } X264Context;
 
@@ -256,6 +257,7 @@ static int X264_frame(AVCodecContext *ctx, AVPacket *pkt, 
const AVFrame *frame,
 int nnal, i, ret;
 x264_picture_t pic_out = {0};
 int pict_type;
+AVFrameSideData *side_data;
 
 x264_picture_init( >pic );
 x4->pic.img.i_csp   = x4->params.i_csp;
@@ -278,7 +280,50 @@ static int X264_frame(AVCodecContext *ctx, AVPacket *pkt, 
const AVFrame *frame,
 X264_TYPE_AUTO;
 
 reconfig_encoder(ctx, frame);
+
+if (x4->a53_cc) {
+side_data = av_frame_get_side_data(frame, AV_FRAME_DATA_A53_CC);
+if (side_data) {
+x4->pic.extra_sei.payloads = 
av_mallocz(sizeof(x4->pic.extra_sei.payloads[0]));
+if (x4->pic.extra_sei.payloads == NULL) {
+av_log(ctx, AV_LOG_ERROR, "Not enough memory for closed 
captions, skipping\n");
+goto skip_a53cc;
+}
+x4->pic.extra_sei.sei_free = av_free;
+
+x4->pic.extra_sei.payloads[0].payload_size = side_data->size + 
11;
+x4->pic.extra_sei.payloads[0].payload = 
av_mallocz(x4->pic.extra_sei.payloads[0].payload_size);
+if (x4->pic.extra_sei.payloads[0].payload == NULL) {
+av_log(ctx, AV_LOG_ERROR, "Not enough memory for closed 
captions, skipping\n");
+av_freep(>pic.extra_sei.payloads);
+goto skip_a53cc;
+}
+x4->pic.extra_sei.num_payloads = 1;
+x4->pic.extra_sei.payloads[0].payload_type = 4;
+memcpy(x4->pic.extra_sei.payloads[0].payload + 10, 
side_data->data, side_data->size);
+x4->pic.extra_sei.payloads[0].payload[0] = 181;
+x4->pic.extra_sei.payloads[0].payload[1] = 0;
+x4->pic.extra_sei.payloads[0].payload[2] = 49;
+
+/**
+ * 'GA94' is standard in North America for ATSC, but hard 
coding
+ * this style may not be the right thing to do -- other formats
+ * do exist. This information is not available in the side_data
+ * so we are going with this right now.
+ */
+x4->pic.extra_sei.payloads[0].payload[3] = 'G';
+x4->pic.extra_sei.payloads[0].payload[4] = 'A';
+x4->pic.extra_sei.payloads[0].payload[5] = '9';
+x4->pic.extra_sei.payloads[0].payload[6] = '4';
+x4->pic.extra_sei.payloads[0].payload[7] = 3;
+x4->pic.extra_sei.payloads[0].payload[8] =
+((side_data->size/3) & 0x1f) | 0x40;
+x4->pic.extra_sei.payloads[0].payload[9] = 0;
+x4->pic.extra_sei.payloads[0].payload[side_data->size+10] = 
255;
+}
+}
 }
+skip_a53cc:
 do {
 if (x264_encoder_encode(x4->enc, , , frame? >pic: NULL, 
_out) < 0)
 return AVERROR_EXTERNAL;
@@ -821,6 +866,7 @@ static const AVOption options[] = {
 {"level", "Specify level (as defined by Annex A)", OFFSET(level), 
AV_OPT_TYPE_STRING, {.str=NULL}, 0, 0, VE},
 {"passlogfile", "Filename for 2 pass stats", OFFSET(stats), 
AV_OPT_TYPE_STRING, {.str=NULL}, 0, 0, VE},
 {"wpredp", "Weighted prediction for P-frames", OFFSET(wpredp), 
AV_OPT_TYPE_STRING, {.str=NULL}, 0, 0, VE},
+{"a53cc",  "Use A53 Closed Captions (if available)",  
OFFSET(a53_cc),AV_OPT_TYPE_BOOL,   {.i64 = 0}, 0, 1, VE},
 {"x264opts", "x264 options", OFFSET(x264opts), AV_OPT_TYPE_STRING, 
{.str=NULL}, 0, 0, VE},
 { "crf",   "Select the quality for constant quality mode",
OFFSET(crf),   AV_OPT_TYPE_FLOAT,  {.dbl = -1 }, -1, FLT_MAX, VE },
 { "crf_max",   "In CRF mode, prevents VBV from 

Re: [FFmpeg-devel] [PATCHv2 1/2] ffplay: add support for interactive volume control

2015-09-27 Thread Marton Balint



On Sun, 27 Sep 2015, Clément Bœsch wrote:


On Sun, Sep 27, 2015 at 11:57:41AM -0400, Ganesh Ajjanagadde wrote:

On Sun, Sep 27, 2015 at 11:40 AM, Clément Bœsch  wrote:

On Sun, Sep 27, 2015 at 10:12:52AM -0400, Ganesh Ajjanagadde wrote:
[...]

Yes, I consider the current usage terrible unless I am missing
something. volume filter is static, so once set, I can't adjust the
volume until I reinsert a new volume filter, etc. I can't simply
adjust the volume like I can with vlc/mpv with a simple keybinding.



There is a process_command() mechanism too if you want to change settings
on the fly


Hmm... that seems to be a libavfilter thing. We could consider adding
that to the volume filter.


volume filter already supports it (see avfilter_process_command() and
process_command callback in the filter code)



FFplay pre-calculates up to 9 frames in the audio decoder thread, so using 
a filter for volume control would add (a codec-specific) latency. Not 
impossible to find compromise between latency and using a filter for 
control, but it requires a bit of further tuning and/or changes.


Regards,
Marton
___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-devel


Re: [FFmpeg-devel] [PATCH] ffmpeg/web/index: add news describing GSoC 2015 program outcome

2015-09-27 Thread Stefano Sabatini
On date Sunday 2015-09-27 15:28:50 +0200, James Darnley encoded:
> On 2015-09-27 14:37, Stefano Sabatini wrote:
> > ---
> >  src/index | 234 
> > ++
> >  1 file changed, 234 insertions(+)
> > 
> > diff --git a/src/index b/src/index
> > index 9d12a7b..8937172 100644
> > --- a/src/index
> > +++ b/src/index
> > @@ -37,6 +37,240 @@
> >  News
> >
> >  
[...]
> > +  Basic servers for network protocols, mentee: klaxa, mentor: Nicolas 
> > George
> > +
> > +  
> > +Stephan Holljes's project for this session of Google Summer of Code 
> > was to
> 
> Are you deliberately using an IRC nick and a name separately here?

Good catch.

[...]
> > +  
> > +TNS still needs some polishing, but has the potential to reduce coding
> > +artifacts by applying noise shaping in the temporal domain (something
>^
> artefacts

I think both "artifact" and "artefact" are valid, but fixed.

[...] 
> There are many more technical terms that my spell checker insists should
> be hyphenated--inter-frame, intra-frame, key-frame--but I always see
> them written as one word.

Thanks. I will send an updated patch as reply to the other reply.
-- 
FFmpeg = Fast Frenzy Meaningless Purposeless Elastic God
___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-devel


Re: [FFmpeg-devel] [PATCH]h264: Fix ticket #3147 H264 - Wrong field order

2015-09-27 Thread Michael Niedermayer
On Sun, Sep 27, 2015 at 03:24:48PM +, Thomas Mundt wrote:
> Fate always stops at vf_mergeplanes with error, with or without my 
> patch:[AVFilterGraph @ 00eb4500] No such filter: ''
> Error initializing complex filters.
> Invalid argument

that should not happen, how can this be reproduced ?


> Is there a way to limit fate that it just checks h264 part?

make fate-h264

also please submit a git patch (which includes a commit message)
git format-patch if you lack teh setup for working send-email

[...]
-- 
Michael GnuPG fingerprint: 9FF2128B147EF6730BADF133611EC787040B0FAB

Opposition brings concord. Out of discord comes the fairest harmony.
-- Heraclitus


signature.asc
Description: Digital signature
___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-devel


Re: [FFmpeg-devel] [PATCH]h264: Fix ticket #3147 H264 - Wrong field order

2015-09-27 Thread Thomas Mundt
Michael Niedermayer  schrieb am 18:04 Sonntag, 27.September 
2015:
 >On Sun, Sep 27, 2015 at 03:24:48PM +, Thomas Mundt wrote:
>> Fate always stops at vf_mergeplanes with error, with or without my 
>> patch:[AVFilterGraph @ 00eb4500] No such filter: ''
>> Error initializing complex filters.
>> Invalid argument
>that should not happen, how can this be reproduced ?

I´m on Win7 64Bit using latest media autobuild suite (msys2) from hereI started 
fate with this command after rsync the testfiles:make fate 
SAMPLES="D:/ffmpeg/fate-suite/">> Is there a way to limit fate that it just 
checks h264 part?>make fate-h264Thanks! fate-h264 passed without errors.
>also please submit a git patch (which includes a commit message)
>git format-patch if you lack teh setup for working send-emailI will do in a 
>separate email...

Regards,Thomas
___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-devel


Re: [FFmpeg-devel] [PATCH 3/7] dnxhddec: check and report bitstream errors

2015-09-27 Thread Michael Niedermayer
On Sun, Sep 27, 2015 at 10:09:04AM +0200, Christophe Gisquet wrote:
> This only occur when an overrun in coefficient decoding is
> detected.
> ---
>  libavcodec/dnxhddec.c | 48 ++--
>  1 file changed, 34 insertions(+), 14 deletions(-)

applied

it might be better to conceal the damaged areas by copying from the
previous frame instead of discarding the whole frame, but i have not
tried so i might miss something

Thanks

[...]
-- 
Michael GnuPG fingerprint: 9FF2128B147EF6730BADF133611EC787040B0FAB

The real ebay dictionary, page 3
"Rare item" - "Common item with rare defect or maybe just a lie"
"Professional" - "'Toy' made in china, not functional except as doorstop"
"Experts will know" - "The seller hopes you are not an expert"


signature.asc
Description: Digital signature
___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-devel


Re: [FFmpeg-devel] [PATCH] ffmpeg/web/index: add news describing GSoC 2015 program outcome

2015-09-27 Thread Ganesh Ajjanagadde
On Sun, Sep 27, 2015 at 5:00 PM, James Darnley  wrote:
> On 2015-09-27 17:43, Stefano Sabatini wrote:
>> On date Sunday 2015-09-27 15:28:50 +0200, James Darnley encoded:
>>> On 2015-09-27 14:37, Stefano Sabatini wrote:
 +  
 +TNS still needs some polishing, but has the potential to reduce coding
 +artifacts by applying noise shaping in the temporal domain (something
>>>^
>>> artefacts
>>
>> I think both "artifact" and "artefact" are valid, but fixed.
>
> After consulting some references I have discovered that "artifact" with
> an 'i' is the usual American spelling.  Sorry about the noise.

If we are indeed following American spelling, then I missed something
- somewhere "colour" should be "color". This one is a relatively more
serious one to consider (although both are minor nits), since
http://grammarist.com/spelling/artefact-artifact/ shows that both were
used in the UK until recently.

>
>
> ___
> 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]h264: Fix ticket #3147 H264 - Wrong field order

2015-09-27 Thread Thomas Mundt
Seems yahoo emails become scrambled and links are not supported. Sorry!

I´m on Win7 64Bit using latest media autobuild suite (msys2) from 
here:https://github.com/jb-alvarado/media-autobuild_suite


I started fate with this command after rsync the testfiles:make fate 
SAMPLES="D:/ffmpeg/fate-suite/"
fate-h264 passed without errors.The attached patch was unified diff. I thought 
this is okay.I´m using tortoise git which makes makes me crazy in combination 
with yahoo mail. But I ´ll try to send a git format-patch soon.

Regards,Thomas

  
___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-devel


Re: [FFmpeg-devel] [PATCH]libx264: Disable global header for AVC-Intra encoding

2015-09-27 Thread Michael Niedermayer
On Sat, Sep 26, 2015 at 02:25:04PM +, Thomas Mundt wrote:
> This will fix AVC-Intra encoding in .mov container.
> Regards,Thomas

>  libx264.c |4 +++-
>  1 file changed, 3 insertions(+), 1 deletion(-)
> 1d153d16cdb505ea33cab12979de3b0e50e3b459  libx264.diff
>  libavcodec/libx264.c | 4 +++-
>  1 file changed, 3 insertions(+), 1 deletion(-)
> 
> diff --git a/libavcodec/libx264.c b/libavcodec/libx264.c
> index 58fcfb0..b4a14cf 100644
> --- a/libavcodec/libx264.c
> +++ b/libavcodec/libx264.c
> @@ -560,13 +560,15 @@ static av_cold int X264_init(AVCodecContext *avctx)
>  x4->params.b_bluray_compat = x4->bluray_compat;
>  x4->params.b_vfr_input = 0;
>  }
> -if (x4->avcintra_class >= 0)
> +if (x4->avcintra_class >= 0) {
>  #if X264_BUILD >= 142
>  x4->params.i_avcintra_class = x4->avcintra_class;
> +avctx->flags &= ~CODEC_FLAG_GLOBAL_HEADER;
>  #else

AVCodecContext.flags is set by the user application not by the codec
see libavcodec/avcodec.h

[...]

-- 
Michael GnuPG fingerprint: 9FF2128B147EF6730BADF133611EC787040B0FAB

What does censorship reveal? It reveals fear. -- Julian Assange


signature.asc
Description: Digital signature
___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-devel


Re: [FFmpeg-devel] [PATCHv4] ffplay: add support for interactive volume control

2015-09-27 Thread Marton Balint


On Sun, 27 Sep 2015, Ganesh Ajjanagadde wrote:


This is a feature heavily inspired by the mpv player. At the moment, methods
for adjusting volume in ffplay are rather clumsy: either one needs to set it
system-wide, or one needs to set it via the volume filter.

This patch adds key bindings identical to the mpv defaults for muting/unmuting
and increasing/decreasing the volume interactively without any introduction of
external dependencies.

TODO: doc update, possible mouse button bindings (mpv has this).

Signed-off-by: Ganesh Ajjanagadde 
---
ffplay.c | 36 +++-
1 file changed, 35 insertions(+), 1 deletion(-)



Applied, thanks.

Marton
___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-devel


Re: [FFmpeg-devel] [PATCHv2] doc/ffplay, ffplay: add information regarding volume control

2015-09-27 Thread Marton Balint



On Sun, 27 Sep 2015, Stefano Sabatini wrote:


On date Sunday 2015-09-27 12:38:34 -0400, Ganesh Ajjanagadde encoded:

ffplay now supports dynamic volume control. This documents the supported
behavior.

Signed-off-by: Ganesh Ajjanagadde 
---
 doc/ffplay.texi | 9 +
 ffplay.c| 3 +++
 2 files changed, 12 insertions(+)


LGTM.


Applied, thanks.

Marton
___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-devel


Re: [FFmpeg-devel] [PATCH]h264: Fix ticket #3147 H264 - Wrong field order

2015-09-27 Thread Michael Niedermayer
On Sun, Sep 27, 2015 at 10:11:47PM +0100, Thomas Mundt wrote:
> IME-Version: 1.0
> Content-Type: text/plain; charset=UTF-8
> Content-Transfer-Encoding: 8bit
> 
> Default field order to top field first when interlaced frame is detected and 
> pic_struct_present_flag is not set.
> Since bottom field first comes from the old NTSC standard and is not used 
> with HD anymore I think it??s straight forward to favor the majority.
> 
> Signed-off-by: Thomas Mundt 
> ---
>  libavcodec/h264.c | 6 +-
>  1 file changed, 5 insertions(+), 1 deletion(-)

applied

thanks

[...]

-- 
Michael GnuPG fingerprint: 9FF2128B147EF6730BADF133611EC787040B0FAB

Its not that you shouldnt use gotos but rather that you should write
readable code and code with gotos often but not always is less readable


signature.asc
Description: Digital signature
___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-devel


Re: [FFmpeg-devel] [PATCH] ffmpeg/web/index: add news describing GSoC 2015 program outcome

2015-09-27 Thread James Darnley
On 2015-09-27 17:43, Stefano Sabatini wrote:
> On date Sunday 2015-09-27 15:28:50 +0200, James Darnley encoded:
>> On 2015-09-27 14:37, Stefano Sabatini wrote:
>>> +  
>>> +TNS still needs some polishing, but has the potential to reduce coding
>>> +artifacts by applying noise shaping in the temporal domain (something
>>^
>> artefacts
> 
> I think both "artifact" and "artefact" are valid, but fixed.

After consulting some references I have discovered that "artifact" with
an 'i' is the usual American spelling.  Sorry about the noise.



signature.asc
Description: OpenPGP digital signature
___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-devel


Re: [FFmpeg-devel] [PATCH] ffmpeg/web/index: add news describing GSoC 2015 program outcome

2015-09-27 Thread James Darnley
On 2015-09-27 23:06, Ganesh Ajjanagadde wrote:
> On Sun, Sep 27, 2015 at 5:00 PM, James Darnley  
> wrote:
>> On 2015-09-27 17:43, Stefano Sabatini wrote:
>>> On date Sunday 2015-09-27 15:28:50 +0200, James Darnley encoded:
 On 2015-09-27 14:37, Stefano Sabatini wrote:
> +  
> +TNS still needs some polishing, but has the potential to reduce 
> coding
> +artifacts by applying noise shaping in the temporal domain (something
^
 artefacts
>>>
>>> I think both "artifact" and "artefact" are valid, but fixed.
>>
>> After consulting some references I have discovered that "artifact" with
>> an 'i' is the usual American spelling.  Sorry about the noise.
> 
> If we are indeed following American spelling, then I missed something
> - somewhere "colour" should be "color". This one is a relatively more
> serious one to consider (although both are minor nits), since
> http://grammarist.com/spelling/artefact-artifact/ shows that both were
> used in the UK until recently.

Oh typical...

> The British preference for artefact is a new development




signature.asc
Description: OpenPGP digital signature
___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-devel


[FFmpeg-devel] [PATCH]h264: Fix ticket #3147 H264 - Wrong field order

2015-09-27 Thread Thomas Mundt
IME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit

Default field order to top field first when interlaced frame is detected and 
pic_struct_present_flag is not set.
Since bottom field first comes from the old NTSC standard and is not used with 
HD anymore I think it´s straight forward to favor the majority.

Signed-off-by: Thomas Mundt 
---
 libavcodec/h264.c | 6 +-
 1 file changed, 5 insertions(+), 1 deletion(-)

diff --git a/libavcodec/h264.c b/libavcodec/h264.c
index b797893..8b95003 100644
--- a/libavcodec/h264.c
+++ b/libavcodec/h264.c
@@ -803,7 +803,7 @@ static void decode_postinit(H264Context *h, int 
setup_finished)
 /* Derive top_field_first from field pocs. */
 cur->f->top_field_first = cur->field_poc[0] < cur->field_poc[1];
 } else {
-if (cur->f->interlaced_frame || h->sps.pic_struct_present_flag) {
+if (h->sps.pic_struct_present_flag) {
 /* Use picture timing SEI information. Even if it is a
  * information of a past frame, better than nothing. */
 if (h->sei_pic_struct == SEI_PIC_STRUCT_TOP_BOTTOM ||
@@ -811,6 +811,10 @@ static void decode_postinit(H264Context *h, int 
setup_finished)
 cur->f->top_field_first = 1;
 else
 cur->f->top_field_first = 0;
+} else if (cur->f->interlaced_frame) {
+/* Default to top field first when pic_struct_present_flag
+ * is not set but interlaced frame detected */
+cur->f->top_field_first = 1;
 } else {
 /* Most likely progressive */
 cur->f->top_field_first = 0;
-- 
1.9.2


___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-devel


Re: [FFmpeg-devel] [PATCH 4/7] dnxhddec: use unsafe bitstream reader

2015-09-27 Thread Michael Niedermayer
On Sun, Sep 27, 2015 at 10:09:05AM +0200, Christophe Gisquet wrote:
> Each line is padded by the format, and errors are now reported and
> stop the decoding. Around 5% speedup.
> ---
>  libavcodec/dnxhddec.c | 1 +
>  1 file changed, 1 insertion(+)

applied

thanks

[...]
-- 
Michael GnuPG fingerprint: 9FF2128B147EF6730BADF133611EC787040B0FAB

Complexity theory is the science of finding the exact solution to an
approximation. Benchmarking OTOH is finding an approximation of the exact


signature.asc
Description: Digital signature
___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-devel


Re: [FFmpeg-devel] [PATCH] avformat/movenc: suppress -Wstrict-overflow warnings

2015-09-27 Thread Michael Niedermayer
On Sun, Sep 27, 2015 at 01:23:03PM -0400, Ganesh Ajjanagadde wrote:
> On Sun, Sep 27, 2015 at 12:58 PM, Michael Niedermayer  
> wrote:
> > On Sat, Sep 26, 2015 at 10:55:26PM -0400, Ganesh Ajjanagadde wrote:
> >> On Sat, Sep 26, 2015 at 10:32 PM, Ronald S. Bultje  
> >> wrote:
> >> > Hi,
> >> >
> >> > On Sat, Sep 26, 2015 at 7:19 PM, Ganesh Ajjanagadde 
> >> > wrote:
> >> >
> >> >> On Sat, Sep 26, 2015 at 7:11 PM, Michael Niedermayer 
> >> >> wrote:
> >> >> > On Fri, Sep 18, 2015 at 05:15:50PM -0400, Ganesh Ajjanagadde wrote:
> >> >> >> This patch results in identical behavior of movenc, and suppresses
> >> >> -Wstrict-overflow
> >> >> >> warnings observed in GCC 5.2.
> >> >> >> I have manually checked that all usages are safe, and overflow
> >> >> possibility does
> >> >> >> not exist with this expression rewrite.
> >> >> >>
> >> >> >> Signed-off-by: Ganesh Ajjanagadde 
> >> >> >> ---
> >> >> >>  libavformat/movenc.c | 2 +-
> >> >> >>  1 file changed, 1 insertion(+), 1 deletion(-)
> >> >> >>
> >> >> >> diff --git a/libavformat/movenc.c b/libavformat/movenc.c
> >> >> >> index af03d1e..6e4a1a6 100644
> >> >> >> --- a/libavformat/movenc.c
> >> >> >> +++ b/libavformat/movenc.c
> >> >> >> @@ -854,7 +854,7 @@ static int get_cluster_duration(MOVTrack *track,
> >> >> int cluster_idx)
> >> >> >>  {
> >> >> >>  int64_t next_dts;
> >> >> >>
> >> >> >> -if (cluster_idx >= track->entry)
> >> >> >> +if (cluster_idx - track->entry >= 0)
> >> >> >
> >> >> > i do not understand what this fixes or why
> >> >> > also plese quote the actual warnings which are fixed in the commit
> >> >> > message
> >> >>
> >> >> I have posted v2 with a more detailed commit message. It should be
> >> >> self explanatory.
> >> >
> >> >
> >> > Even with the new message, it's still not clear to me what's being fixed.
> >> > What does the warning check for? What is the problem in the initial
> >> > expression?
> >>
> >> Compilers make transformations on the statements in order to possibly
> >> get better performance when compiled with optimizations. However, some
> >> of these optimizations require assumptions in the code. In particular,
> >> the compiler is internally rewriting cluster_idx >= track->entry to
> >> cluster_idx - track->entry >= 0 internally for some reason (I am not
> >> an asm/instruction set guy, so I can't comment why it likes this).
> >> However, such a transformation is NOT always safe as integer
> >> arithmetic can overflow (try e.g extreme values close to INT_MIN,
> >> INT_MAX). The warning is spit out since the compiler can't be sure
> >> that this is safe, but it still wants to do it (I suspect only the
> >> -O3/-O2 level that try this, can check if you want).
> >
> > iam not sure i understand correctly but
> > if the compiler changes the code and then warns that what it just
> > did might be unsafe then the compiler is broken
> 
> https://stackoverflow.com/questions/12984861/dont-understand-assuming-signed-overflow-warning
> - gives a detailed explanation.
> 
> Some more info: this is triggered only when -finline-functions is
> enabled (done by default on -O3, not enabled by default on -O2).
> -finline-functions tries to inline stuff even when "inline" keyword is
> absent (like in this case).
> As for the warning, http://linux.die.net/man/1/gcc - search for
> -Wstrict-overflow. It is enabled due to -Wall, and as the man page
> suggests, it depends on optimization level as we can see in this
> example.
> I do consider the compiler broken in this case, but then again
> compilers are broken in so many different ways it is not even funny:
> see e.g -Warray-bounds, can't use the ISO C correct { 0 } initializer
> for compound data types, etc.
> 
> If you don't like this, we should add a -Wnostrict-overflow either to
> configure, or a local enable/disable via pragmas/macros. I don't like
> either of these as compared to this simple workaround:
> 1. -Wnostrict-overflow: FFmpeg with the amount of integer arithmetic
> being done should benefit from this warning in general, so disabling
> it globally may be bad.

how many actual bugs has Wstrict-overflow found ?

[...]
-- 
Michael GnuPG fingerprint: 9FF2128B147EF6730BADF133611EC787040B0FAB

The real ebay dictionary, page 3
"Rare item" - "Common item with rare defect or maybe just a lie"
"Professional" - "'Toy' made in china, not functional except as doorstop"
"Experts will know" - "The seller hopes you are not an expert"


signature.asc
Description: Digital signature
___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-devel


Re: [FFmpeg-devel] [PATCH] avformat/movenc: suppress -Wstrict-overflow warnings

2015-09-27 Thread Ganesh Ajjanagadde
On Sun, Sep 27, 2015 at 9:18 PM, Michael Niedermayer  wrote:
> On Sun, Sep 27, 2015 at 01:23:03PM -0400, Ganesh Ajjanagadde wrote:
>> On Sun, Sep 27, 2015 at 12:58 PM, Michael Niedermayer  
>> wrote:
>> > On Sat, Sep 26, 2015 at 10:55:26PM -0400, Ganesh Ajjanagadde wrote:
>> >> On Sat, Sep 26, 2015 at 10:32 PM, Ronald S. Bultje  
>> >> wrote:
>> >> > Hi,
>> >> >
>> >> > On Sat, Sep 26, 2015 at 7:19 PM, Ganesh Ajjanagadde 
>> >> > wrote:
>> >> >
>> >> >> On Sat, Sep 26, 2015 at 7:11 PM, Michael Niedermayer 
>> >> >> wrote:
>> >> >> > On Fri, Sep 18, 2015 at 05:15:50PM -0400, Ganesh Ajjanagadde wrote:
>> >> >> >> This patch results in identical behavior of movenc, and suppresses
>> >> >> -Wstrict-overflow
>> >> >> >> warnings observed in GCC 5.2.
>> >> >> >> I have manually checked that all usages are safe, and overflow
>> >> >> possibility does
>> >> >> >> not exist with this expression rewrite.
>> >> >> >>
>> >> >> >> Signed-off-by: Ganesh Ajjanagadde 
>> >> >> >> ---
>> >> >> >>  libavformat/movenc.c | 2 +-
>> >> >> >>  1 file changed, 1 insertion(+), 1 deletion(-)
>> >> >> >>
>> >> >> >> diff --git a/libavformat/movenc.c b/libavformat/movenc.c
>> >> >> >> index af03d1e..6e4a1a6 100644
>> >> >> >> --- a/libavformat/movenc.c
>> >> >> >> +++ b/libavformat/movenc.c
>> >> >> >> @@ -854,7 +854,7 @@ static int get_cluster_duration(MOVTrack *track,
>> >> >> int cluster_idx)
>> >> >> >>  {
>> >> >> >>  int64_t next_dts;
>> >> >> >>
>> >> >> >> -if (cluster_idx >= track->entry)
>> >> >> >> +if (cluster_idx - track->entry >= 0)
>> >> >> >
>> >> >> > i do not understand what this fixes or why
>> >> >> > also plese quote the actual warnings which are fixed in the commit
>> >> >> > message
>> >> >>
>> >> >> I have posted v2 with a more detailed commit message. It should be
>> >> >> self explanatory.
>> >> >
>> >> >
>> >> > Even with the new message, it's still not clear to me what's being 
>> >> > fixed.
>> >> > What does the warning check for? What is the problem in the initial
>> >> > expression?
>> >>
>> >> Compilers make transformations on the statements in order to possibly
>> >> get better performance when compiled with optimizations. However, some
>> >> of these optimizations require assumptions in the code. In particular,
>> >> the compiler is internally rewriting cluster_idx >= track->entry to
>> >> cluster_idx - track->entry >= 0 internally for some reason (I am not
>> >> an asm/instruction set guy, so I can't comment why it likes this).
>> >> However, such a transformation is NOT always safe as integer
>> >> arithmetic can overflow (try e.g extreme values close to INT_MIN,
>> >> INT_MAX). The warning is spit out since the compiler can't be sure
>> >> that this is safe, but it still wants to do it (I suspect only the
>> >> -O3/-O2 level that try this, can check if you want).
>> >
>> > iam not sure i understand correctly but
>> > if the compiler changes the code and then warns that what it just
>> > did might be unsafe then the compiler is broken
>>
>> https://stackoverflow.com/questions/12984861/dont-understand-assuming-signed-overflow-warning
>> - gives a detailed explanation.
>>
>> Some more info: this is triggered only when -finline-functions is
>> enabled (done by default on -O3, not enabled by default on -O2).
>> -finline-functions tries to inline stuff even when "inline" keyword is
>> absent (like in this case).
>> As for the warning, http://linux.die.net/man/1/gcc - search for
>> -Wstrict-overflow. It is enabled due to -Wall, and as the man page
>> suggests, it depends on optimization level as we can see in this
>> example.
>> I do consider the compiler broken in this case, but then again
>> compilers are broken in so many different ways it is not even funny:
>> see e.g -Warray-bounds, can't use the ISO C correct { 0 } initializer
>> for compound data types, etc.
>>
>> If you don't like this, we should add a -Wnostrict-overflow either to
>> configure, or a local enable/disable via pragmas/macros. I don't like
>> either of these as compared to this simple workaround:
>> 1. -Wnostrict-overflow: FFmpeg with the amount of integer arithmetic
>> being done should benefit from this warning in general, so disabling
>> it globally may be bad.
>
> how many actual bugs has Wstrict-overflow found ?

No idea; maybe a good place to check is the Google fuzzing effort
where many bugs were fixed.

>
> [...]
> --
> Michael GnuPG fingerprint: 9FF2128B147EF6730BADF133611EC787040B0FAB
>
> The real ebay dictionary, page 3
> "Rare item" - "Common item with rare defect or maybe just a lie"
> "Professional" - "'Toy' made in china, not functional except as doorstop"
> "Experts will know" - "The seller hopes you are not an expert"
>
> ___
> ffmpeg-devel mailing list
> ffmpeg-devel@ffmpeg.org
> http://ffmpeg.org/mailman/listinfo/ffmpeg-devel
>

Re: [FFmpeg-devel] [PATCH v2] checkasm: Fix the function name sorting algorithm

2015-09-27 Thread Michael Niedermayer
On Sun, Sep 27, 2015 at 07:55:06PM +0200, Henrik Gramner wrote:
> The previous implementation was behaving incorrectly in some corner cases.
> ---
> The first version of this patch didn't take care of all possible corner cases,
> but I believe this one does.
> ---
>  tests/checkasm/checkasm.c | 8 ++--
>  1 file changed, 6 insertions(+), 2 deletions(-)
> 
> diff --git a/tests/checkasm/checkasm.c b/tests/checkasm/checkasm.c
> index 8c75cc9..d7c2e8a 100644
> --- a/tests/checkasm/checkasm.c
> +++ b/tests/checkasm/checkasm.c
> @@ -289,12 +289,16 @@ static void print_benchs(CheckasmFunc *f)
>  /* ASCIIbetical sort except preserving natural order for numbers */
>  static int cmp_func_names(const char *a, const char *b)
>  {
> +const char *start = a;
>  int ascii_diff, digit_diff;
>  
> -for (; !(ascii_diff = *a - *b) && *a; a++, b++);
> +for (; !(ascii_diff = *(const unsigned char*)a - *(const unsigned 
> char*)b) && *a; a++, b++);
>  for (; av_isdigit(*a) && av_isdigit(*b); a++, b++);
>  
> -return (digit_diff = av_isdigit(*a) - av_isdigit(*b)) ? digit_diff : 
> ascii_diff;
> +if (a > start && av_isdigit(a[-1]) && (digit_diff = av_isdigit(*a) - 
> av_isdigit(*b)))
> +return digit_diff;
> +
> +return ascii_diff;
>  }

LGTM

thx

[...]
-- 
Michael GnuPG fingerprint: 9FF2128B147EF6730BADF133611EC787040B0FAB

What does censorship reveal? It reveals fear. -- Julian Assange


signature.asc
Description: Digital signature
___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-devel


Re: [FFmpeg-devel] pngdec failing with an assertion

2015-09-27 Thread Gonzalo



El 27/09/15 a las 22:45, Gonzalo escribió:

$ ffplay /media/Linux/anims/wildlife/wildlife.%04d.png
ffplay version N-75563-g235381e Copyright (c) 2003-2015 the FFmpeg 
developers

  built with gcc 4.8 (Ubuntu 4.8.4-2ubuntu1~14.04)
  configuration: --enable-gpl --enable-shared --enable-gray 
--enable-runtime-cpudetect --enable-bzlib --enable-libfreetype 
--enable-libmp3lame --enable-libtheora --enable-libvorbis 
--enable-libvpx --enable-libx264 --enable-zlib

  libavutil  55.  2.100 / 55.  2.100
  libavcodec 57.  3.100 / 57.  3.100
  libavformat57.  2.100 / 57.  2.100
  libavdevice57.  0.100 / 57.  0.100
  libavfilter 6.  8.100 /  6.  8.100
  libswscale  4.  0.100 /  4.  0.100
  libswresample   2.  0.100 /  2.  0.100
  libpostproc54.  0.100 / 54.  0.100
Input #0, image2, from '/media/Linux/anims/wildlife/wildlife.%04d.png':
  Duration: 00:00:10.08, start: 0.00, bitrate: N/A
Stream #0:0: Video: png, rgba64be(pc), 1280x720 [SAR 2834:2834 DAR 
16:9], 25 fps, 25 tbr, 25 tbn, 25 tbc

Assertion 0 failed at libavcodec/pngdec.c:666
Abortado (`core' generado)

The same set of files loads fine with a previous ffmpeg version (6 
months ago).


Also, the individual files load fine.  It is just the sequence that does 
not work.



___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-devel


Re: [FFmpeg-devel] [PATCH 2/3 v2] configure: Support for HEASLR on mingw targets

2015-09-27 Thread Hendrik Leppkes
On Sat, Sep 26, 2015 at 8:43 AM, Alex Smith  wrote:
> From: Alex Smith 
>
> The appropriate flag for HEASLR (--high-entropy-va) was added in
> binutils 2.25.
>
> Also set the image base >4GB so higher entropy gets applied to image
> base randomization when used with HEASLR (8 -> 17 bits of
> randomization).  Windows does this for compatibility because of "latent
> pointer truncation issues".
>
> Signed-off-by: Alex Smith 
> ---
>  configure | 4 
>  1 file changed, 4 insertions(+)
>
> diff --git a/configure b/configure
> index f6bc622..0a4b4ed 100755
> --- a/configure
> +++ b/configure
> @@ -4401,6 +4401,10 @@ case $target_os in
>  add_ldexeflags -Wl,--pic-executable,-e,_mainCRTStartup
>  elif enabled x86_64; then
>  add_ldexeflags -Wl,--pic-executable,-e,mainCRTStartup
> +check_ldflags -Wl,--high-entropy-va # binutils 2.25
> +# Set image base >4GB for extra entropy with HEASLR
> +add_ldexeflags -Wl,--image-base,0x14000
> +append SHFLAGS -Wl,--image-base,0x18000
>  fi
>  ;;
>  win32|win64)
> --
> 1.9.5.msysgit.0

LGTM, will push later.
___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-devel


Re: [FFmpeg-devel] [PATCH] ffmpeg/web/index: add news describing GSoC 2015 program outcome

2015-09-27 Thread Moritz Barsnick
In addition to the others:

> +effort. We're looking forward participating to the next GSoC

looking forward to participating in the next

> +At the end of the program, Mariusz provided a sketch of implementation

of an implementation

> +with overlapping formatting (which other formats support) but Timed
> +Text does not - so it requires breaking the overlapping sections into

I think this is meant to read:
  with overlapping formatting (which other formats support but Timed Text
  does not)
i.e. the "but" (Timed Text text) currently refers to text in the
brackets.


Moritz
___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-devel


[FFmpeg-devel] [PATCH] avcodec/pngdec: mark previous_picture as done on end of decode_frame_common()

2015-09-27 Thread Michael Niedermayer
From: Michael Niedermayer 

Fixes deadlock with threads

Found-by: Paul B Mahol
Signed-off-by: Michael Niedermayer 
---
 libavcodec/pngdec.c |2 ++
 1 file changed, 2 insertions(+)

diff --git a/libavcodec/pngdec.c b/libavcodec/pngdec.c
index ee11f12..743144b 100644
--- a/libavcodec/pngdec.c
+++ b/libavcodec/pngdec.c
@@ -1217,6 +1217,7 @@ exit_loop:
 }
 }
 ff_thread_report_progress(>picture, INT_MAX, 0);
+ff_thread_report_progress(>previous_picture, INT_MAX, 0);
 
 av_frame_set_metadata(p, metadata);
 metadata   = NULL;
@@ -1225,6 +1226,7 @@ exit_loop:
 fail:
 av_dict_free();
 ff_thread_report_progress(>picture, INT_MAX, 0);
+ff_thread_report_progress(>previous_picture, INT_MAX, 0);
 return ret;
 }
 
-- 
1.7.9.5

___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-devel


Re: [FFmpeg-devel] pngdec failing with an assertion

2015-09-27 Thread Timothy Gu
El domingo, 27 de septiembre de 2015, Gonzalo  escribió:

>
>
> El 27/09/15 a las 22:45, Gonzalo escribió:
>
>> $ ffplay /media/Linux/anims/wildlife/wildlife.%04d.png
>> ffplay version N-75563-g235381e Copyright (c) 2003-2015 the FFmpeg
>> developers
>>   built with gcc 4.8 (Ubuntu 4.8.4-2ubuntu1~14.04)
>>   configuration: --enable-gpl --enable-shared --enable-gray
>> --enable-runtime-cpudetect --enable-bzlib --enable-libfreetype
>> --enable-libmp3lame --enable-libtheora --enable-libvorbis --enable-libvpx
>> --enable-libx264 --enable-zlib
>>   libavutil  55.  2.100 / 55.  2.100
>>   libavcodec 57.  3.100 / 57.  3.100
>>   libavformat57.  2.100 / 57.  2.100
>>   libavdevice57.  0.100 / 57.  0.100
>>   libavfilter 6.  8.100 /  6.  8.100
>>   libswscale  4.  0.100 /  4.  0.100
>>   libswresample   2.  0.100 /  2.  0.100
>>   libpostproc54.  0.100 / 54.  0.100
>> Input #0, image2, from '/media/Linux/anims/wildlife/wildlife.%04d.png':
>>   Duration: 00:00:10.08, start: 0.00, bitrate: N/A
>> Stream #0:0: Video: png, rgba64be(pc), 1280x720 [SAR 2834:2834 DAR
>> 16:9], 25 fps, 25 tbr, 25 tbn, 25 tbc
>> Assertion 0 failed at libavcodec/pngdec.c:666
>> Abortado (`core' generado)
>>
>> The same set of files loads fine with a previous ffmpeg version (6 months
>> ago).
>>
>
> Also, the individual files load fine.  It is just the sequence that does
> not work.
>
>
Please file a ticket at trac.ffmpeg.org with the source PNGs attached to it.

Timothy
___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-devel


[FFmpeg-devel] [PATCH] ffplay: more robust mutex, condition variable handling

2015-09-27 Thread Ganesh Ajjanagadde
SDL_CreateMutex and SDL_CreateCond can fail:
https://wiki.libsdl.org/SDL_CreateMutex.
This patch makes handling more robust in one instance.

Signed-off-by: Ganesh Ajjanagadde 
---
 ffplay.c | 23 +--
 1 file changed, 17 insertions(+), 6 deletions(-)

diff --git a/ffplay.c b/ffplay.c
index 10887e1..27af336 100644
--- a/ffplay.c
+++ b/ffplay.c
@@ -451,12 +451,21 @@ static int packet_queue_put_nullpacket(PacketQueue *q, 
int stream_index)
 }
 
 /* packet queue handling */
-static void packet_queue_init(PacketQueue *q)
+static int packet_queue_init(PacketQueue *q)
 {
 memset(q, 0, sizeof(PacketQueue));
 q->mutex = SDL_CreateMutex();
+if (!q->mutex) {
+av_log(q, AV_LOG_FATAL, "SDL_CreateMutex(): %s\n", SDL_GetError());
+return AVERROR(EINVAL);
+}
 q->cond = SDL_CreateCond();
+if (!q->cond) {
+av_log(q, AV_LOG_FATAL, "SDL_CreateCond(): %s\n", SDL_GetError());
+return AVERROR(EINVAL);
+}
 q->abort_request = 1;
+return 0;
 }
 
 static void packet_queue_flush(PacketQueue *q)
@@ -479,8 +488,10 @@ static void packet_queue_flush(PacketQueue *q)
 static void packet_queue_destroy(PacketQueue *q)
 {
 packet_queue_flush(q);
-SDL_DestroyMutex(q->mutex);
-SDL_DestroyCond(q->cond);
+if (q->mutex)
+SDL_DestroyMutex(q->mutex);
+if (q->cond)
+SDL_DestroyCond(q->cond);
 }
 
 static void packet_queue_abort(PacketQueue *q)
@@ -3136,9 +3147,9 @@ static VideoState *stream_open(const char *filename, 
AVInputFormat *iformat)
 if (frame_queue_init(>sampq, >audioq, SAMPLE_QUEUE_SIZE, 1) < 0)
 goto fail;
 
-packet_queue_init(>videoq);
-packet_queue_init(>audioq);
-packet_queue_init(>subtitleq);
+if (!packet_queue_init(>videoq) || !packet_queue_init(>audioq)
+|| packet_queue_init(>subtitleq))
+goto fail;
 
 is->continue_read_thread = SDL_CreateCond();
 
-- 
2.5.3

___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-devel


[FFmpeg-devel] pngdec failing with an assertion

2015-09-27 Thread Gonzalo

$ ffplay /media/Linux/anims/wildlife/wildlife.%04d.png
ffplay version N-75563-g235381e Copyright (c) 2003-2015 the FFmpeg 
developers

  built with gcc 4.8 (Ubuntu 4.8.4-2ubuntu1~14.04)
  configuration: --enable-gpl --enable-shared --enable-gray 
--enable-runtime-cpudetect --enable-bzlib --enable-libfreetype 
--enable-libmp3lame --enable-libtheora --enable-libvorbis 
--enable-libvpx --enable-libx264 --enable-zlib

  libavutil  55.  2.100 / 55.  2.100
  libavcodec 57.  3.100 / 57.  3.100
  libavformat57.  2.100 / 57.  2.100
  libavdevice57.  0.100 / 57.  0.100
  libavfilter 6.  8.100 /  6.  8.100
  libswscale  4.  0.100 /  4.  0.100
  libswresample   2.  0.100 /  2.  0.100
  libpostproc54.  0.100 / 54.  0.100
Input #0, image2, from '/media/Linux/anims/wildlife/wildlife.%04d.png':
  Duration: 00:00:10.08, start: 0.00, bitrate: N/A
Stream #0:0: Video: png, rgba64be(pc), 1280x720 [SAR 2834:2834 DAR 
16:9], 25 fps, 25 tbr, 25 tbn, 25 tbc

Assertion 0 failed at libavcodec/pngdec.c:666
Abortado (`core' generado)

The same set of files loads fine with a previous ffmpeg version (6 
months ago).

___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-devel


Re: [FFmpeg-devel] [PATCH] ffplay: more robust mutex, condition variable handling

2015-09-27 Thread Ganesh Ajjanagadde
On Sun, Sep 27, 2015 at 9:35 PM, Ganesh Ajjanagadde
 wrote:
> SDL_CreateMutex and SDL_CreateCond can fail:
> https://wiki.libsdl.org/SDL_CreateMutex.
> This patch makes handling more robust in one instance.
>
> Signed-off-by: Ganesh Ajjanagadde 
> ---
>  ffplay.c | 23 +--
>  1 file changed, 17 insertions(+), 6 deletions(-)
>
> diff --git a/ffplay.c b/ffplay.c
> index 10887e1..27af336 100644
> --- a/ffplay.c
> +++ b/ffplay.c
> @@ -451,12 +451,21 @@ static int packet_queue_put_nullpacket(PacketQueue *q, 
> int stream_index)
>  }
>
>  /* packet queue handling */
> -static void packet_queue_init(PacketQueue *q)
> +static int packet_queue_init(PacketQueue *q)
>  {
>  memset(q, 0, sizeof(PacketQueue));
>  q->mutex = SDL_CreateMutex();
> +if (!q->mutex) {
> +av_log(q, AV_LOG_FATAL, "SDL_CreateMutex(): %s\n", SDL_GetError());
> +return AVERROR(EINVAL);
> +}
>  q->cond = SDL_CreateCond();
> +if (!q->cond) {
> +av_log(q, AV_LOG_FATAL, "SDL_CreateCond(): %s\n", SDL_GetError());
> +return AVERROR(EINVAL);
> +}
>  q->abort_request = 1;
> +return 0;
>  }
>
>  static void packet_queue_flush(PacketQueue *q)
> @@ -479,8 +488,10 @@ static void packet_queue_flush(PacketQueue *q)
>  static void packet_queue_destroy(PacketQueue *q)
>  {
>  packet_queue_flush(q);
> -SDL_DestroyMutex(q->mutex);
> -SDL_DestroyCond(q->cond);
> +if (q->mutex)
> +SDL_DestroyMutex(q->mutex);
> +if (q->cond)
> +SDL_DestroyCond(q->cond);
>  }
>
>  static void packet_queue_abort(PacketQueue *q)
> @@ -3136,9 +3147,9 @@ static VideoState *stream_open(const char *filename, 
> AVInputFormat *iformat)
>  if (frame_queue_init(>sampq, >audioq, SAMPLE_QUEUE_SIZE, 1) < 0)
>  goto fail;
>
> -packet_queue_init(>videoq);
> -packet_queue_init(>audioq);
> -packet_queue_init(>subtitleq);
> +if (!packet_queue_init(>videoq) || !packet_queue_init(>audioq)
> +|| packet_queue_init(>subtitleq))
> +goto fail;
>
>  is->continue_read_thread = SDL_CreateCond();
>
> --
> 2.5.3
>

please ignore this - wrong patch. Apologies.
___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-devel


[FFmpeg-devel] [PATCH] doc/ffplay: add information regarding volume control

2015-09-27 Thread Ganesh Ajjanagadde
ffplay now supports dynamic volume control. This documents the supported
behavior.

Signed-off-by: Ganesh Ajjanagadde 
---
 doc/ffplay.texi | 9 +
 1 file changed, 9 insertions(+)

diff --git a/doc/ffplay.texi b/doc/ffplay.texi
index be696c8..2a35c21 100644
--- a/doc/ffplay.texi
+++ b/doc/ffplay.texi
@@ -197,6 +197,15 @@ Toggle full screen.
 @item p, SPC
 Pause.
 
+@item m
+Toggle mute.
+
+@item 9, 0
+Decrease and increase volume respectively.
+
+@item /, *
+Decrease and increase volume respectively.
+
 @item a
 Cycle audio channel in the current program.
 
-- 
2.5.3

___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-devel


Re: [FFmpeg-devel] [PATCHv2 1/2] ffplay: add support for interactive volume control

2015-09-27 Thread Ganesh Ajjanagadde
On Sun, Sep 27, 2015 at 12:16 PM, Clément Bœsch  wrote:
> On Sun, Sep 27, 2015 at 11:57:41AM -0400, Ganesh Ajjanagadde wrote:
>> On Sun, Sep 27, 2015 at 11:40 AM, Clément Bœsch  wrote:
>> > On Sun, Sep 27, 2015 at 10:12:52AM -0400, Ganesh Ajjanagadde wrote:
>> > [...]
>> >> Yes, I consider the current usage terrible unless I am missing
>> >> something. volume filter is static, so once set, I can't adjust the
>> >> volume until I reinsert a new volume filter, etc. I can't simply
>> >> adjust the volume like I can with vlc/mpv with a simple keybinding.
>> >>
>> >
>> > There is a process_command() mechanism too if you want to change settings
>> > on the fly
>>
>> Hmm... that seems to be a libavfilter thing. We could consider adding
>> that to the volume filter.
>
> volume filter already supports it (see avfilter_process_command() and
> process_command callback in the filter code)

That "support" is IMHO not usable for interactive purposes in ffplay.
Typing "volume" everytime volume needs to be changed is IMHO not as
usable as the approach of this patch (in addition to the -af/-vf
whatever which by itself for me is bad compared to mpv/cvlc).
Furthermore, as I argued, this patch is correct.

>
> [...]
>
> --
> Clément B.
>
> ___
> 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


[FFmpeg-devel] [PATCH v2] checkasm: Fix the function name sorting algorithm

2015-09-27 Thread Henrik Gramner
The previous implementation was behaving incorrectly in some corner cases.
---
The first version of this patch didn't take care of all possible corner cases,
but I believe this one does.
---
 tests/checkasm/checkasm.c | 8 ++--
 1 file changed, 6 insertions(+), 2 deletions(-)

diff --git a/tests/checkasm/checkasm.c b/tests/checkasm/checkasm.c
index 8c75cc9..d7c2e8a 100644
--- a/tests/checkasm/checkasm.c
+++ b/tests/checkasm/checkasm.c
@@ -289,12 +289,16 @@ static void print_benchs(CheckasmFunc *f)
 /* ASCIIbetical sort except preserving natural order for numbers */
 static int cmp_func_names(const char *a, const char *b)
 {
+const char *start = a;
 int ascii_diff, digit_diff;
 
-for (; !(ascii_diff = *a - *b) && *a; a++, b++);
+for (; !(ascii_diff = *(const unsigned char*)a - *(const unsigned char*)b) 
&& *a; a++, b++);
 for (; av_isdigit(*a) && av_isdigit(*b); a++, b++);
 
-return (digit_diff = av_isdigit(*a) - av_isdigit(*b)) ? digit_diff : 
ascii_diff;
+if (a > start && av_isdigit(a[-1]) && (digit_diff = av_isdigit(*a) - 
av_isdigit(*b)))
+return digit_diff;
+
+return ascii_diff;
 }
 
 /* Perform a tree rotation in the specified direction and return the new root 
*/
-- 
1.9.1

___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-devel


[FFmpeg-devel] [PATCH 0/7] dnxhddec cleanup

2015-09-27 Thread Christophe Gisquet
Nothing major, mostly related to error reporting.

Christophe Gisquet (7):
  dnxhddec: remove unused qscale parameter
  dnxhddec: simplify block parsing calls
  dnxhddec: check and report bitstream errors
  dnxhddec: use unsafe bitstream reader
  dnxhddec: reindent/cosmetics
  dnxhddata: deduplicate table
  dnxhddec: add my contributions

 libavcodec/dnxhddata.c |  16 ++--
 libavcodec/dnxhddec.c  | 103 +++--
 2 files changed, 60 insertions(+), 59 deletions(-)

-- 
2.5.2

___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-devel


[FFmpeg-devel] [PATCH 4/7] dnxhddec: use unsafe bitstream reader

2015-09-27 Thread Christophe Gisquet
Each line is padded by the format, and errors are now reported and
stop the decoding. Around 5% speedup.
---
 libavcodec/dnxhddec.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/libavcodec/dnxhddec.c b/libavcodec/dnxhddec.c
index 8d30446..06d4780 100644
--- a/libavcodec/dnxhddec.c
+++ b/libavcodec/dnxhddec.c
@@ -26,6 +26,7 @@
 #include "libavutil/timer.h"
 #include "avcodec.h"
 #include "blockdsp.h"
+#define  UNCHECKED_BITSTREAM_READER 1
 #include "get_bits.h"
 #include "dnxhddata.h"
 #include "idctdsp.h"
-- 
2.5.2

___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-devel


[FFmpeg-devel] [PATCH 2/7] dnxhddec: simplify block parsing calls

2015-09-27 Thread Christophe Gisquet
Fewer arguments, less duplicated code.
---
 libavcodec/dnxhddec.c | 43 ---
 1 file changed, 16 insertions(+), 27 deletions(-)

diff --git a/libavcodec/dnxhddec.c b/libavcodec/dnxhddec.c
index 34cf379..007eabe 100644
--- a/libavcodec/dnxhddec.c
+++ b/libavcodec/dnxhddec.c
@@ -62,22 +62,18 @@ typedef struct DNXHDContext {
 int mbaff;
 int act;
 void (*decode_dct_block)(const struct DNXHDContext *ctx,
- RowContext *row, int16_t *block,
- int n);
+ RowContext *row, int n);
 } DNXHDContext;
 
 #define DNXHD_VLC_BITS 9
 #define DNXHD_DC_VLC_BITS 7
 
 static void dnxhd_decode_dct_block_8(const DNXHDContext *ctx,
- RowContext *row, int16_t *block,
- int n);
+ RowContext *row, int n);
 static void dnxhd_decode_dct_block_10(const DNXHDContext *ctx,
-  RowContext *row, int16_t *block,
-  int n);
+  RowContext *row, int n);
 static void dnxhd_decode_dct_block_10_444(const DNXHDContext *ctx,
-  RowContext *row, int16_t *block,
-  int n);
+  RowContext *row, int n);
 
 static av_cold int dnxhd_decode_init(AVCodecContext *avctx)
 {
@@ -271,7 +267,7 @@ static int dnxhd_decode_header(DNXHDContext *ctx, AVFrame 
*frame,
 
 static av_always_inline void dnxhd_decode_dct_block(const DNXHDContext *ctx,
 RowContext *row,
-int16_t *block, int n,
+int n,
 int index_bits,
 int level_bias,
 int level_shift)
@@ -282,9 +278,12 @@ static av_always_inline void dnxhd_decode_dct_block(const 
DNXHDContext *ctx,
 const uint8_t *weight_matrix;
 const uint8_t *ac_level = ctx->cid_table->ac_level;
 const uint8_t *ac_flags = ctx->cid_table->ac_flags;
+int16_t *block = row->blocks[n];
 const int eob_index = ctx->cid_table->eob_index;
 OPEN_READER(bs, >gb);
 
+ctx->bdsp.clear_block(block);
+
 if (!ctx->is_444) {
 if (n & 2) {
 component = 1 + (n & 1);
@@ -364,24 +363,21 @@ static av_always_inline void dnxhd_decode_dct_block(const 
DNXHDContext *ctx,
 }
 
 static void dnxhd_decode_dct_block_8(const DNXHDContext *ctx,
- RowContext *row, int16_t *block,
- int n)
+ RowContext *row, int n)
 {
-dnxhd_decode_dct_block(ctx, row, block, n, 4, 32, 6);
+dnxhd_decode_dct_block(ctx, row, n, 4, 32, 6);
 }
 
 static void dnxhd_decode_dct_block_10(const DNXHDContext *ctx,
-  RowContext *row, int16_t *block,
-  int n)
+  RowContext *row, int n)
 {
-dnxhd_decode_dct_block(ctx, row, block, n, 6, 8, 4);
+dnxhd_decode_dct_block(ctx, row, n, 6, 8, 4);
 }
 
 static void dnxhd_decode_dct_block_10_444(const DNXHDContext *ctx,
-  RowContext *row, int16_t *block,
-  int n)
+  RowContext *row, int n)
 {
-dnxhd_decode_dct_block(ctx, row, block, n, 6, 32, 6);
+dnxhd_decode_dct_block(ctx, row, n, 6, 32, 6);
 }
 
 static int dnxhd_decode_macroblock(const DNXHDContext *ctx, RowContext *row,
@@ -418,15 +414,8 @@ static int dnxhd_decode_macroblock(const DNXHDContext 
*ctx, RowContext *row,
 row->last_qscale = qscale;
 }
 
-for (i = 0; i < 8; i++) {
-ctx->bdsp.clear_block(row->blocks[i]);
-ctx->decode_dct_block(ctx, row, row->blocks[i], i);
-}
-if (ctx->is_444) {
-for (; i < 12; i++) {
-ctx->bdsp.clear_block(row->blocks[i]);
-ctx->decode_dct_block(ctx, row, row->blocks[i], i);
-}
+for (i = 0; i < 8 + 4 * ctx->is_444; i++) {
+ctx->decode_dct_block(ctx, row, i);
 }
 
 if (frame->interlaced_frame) {
-- 
2.5.2

___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-devel


[FFmpeg-devel] [PATCH 3/7] dnxhddec: check and report bitstream errors

2015-09-27 Thread Christophe Gisquet
This only occur when an overrun in coefficient decoding is
detected.
---
 libavcodec/dnxhddec.c | 48 ++--
 1 file changed, 34 insertions(+), 14 deletions(-)

diff --git a/libavcodec/dnxhddec.c b/libavcodec/dnxhddec.c
index 007eabe..8d30446 100644
--- a/libavcodec/dnxhddec.c
+++ b/libavcodec/dnxhddec.c
@@ -39,6 +39,7 @@ typedef struct RowContext {
 GetBitContext gb;
 int last_dc[3];
 int last_qscale;
+int errors;
 } RowContext;
 
 typedef struct DNXHDContext {
@@ -61,18 +62,18 @@ typedef struct DNXHDContext {
 int is_444;
 int mbaff;
 int act;
-void (*decode_dct_block)(const struct DNXHDContext *ctx,
+int (*decode_dct_block)(const struct DNXHDContext *ctx,
  RowContext *row, int n);
 } DNXHDContext;
 
 #define DNXHD_VLC_BITS 9
 #define DNXHD_DC_VLC_BITS 7
 
-static void dnxhd_decode_dct_block_8(const DNXHDContext *ctx,
+static int dnxhd_decode_dct_block_8(const DNXHDContext *ctx,
  RowContext *row, int n);
-static void dnxhd_decode_dct_block_10(const DNXHDContext *ctx,
+static int dnxhd_decode_dct_block_10(const DNXHDContext *ctx,
   RowContext *row, int n);
-static void dnxhd_decode_dct_block_10_444(const DNXHDContext *ctx,
+static int dnxhd_decode_dct_block_10_444(const DNXHDContext *ctx,
   RowContext *row, int n);
 
 static av_cold int dnxhd_decode_init(AVCodecContext *avctx)
@@ -265,7 +266,7 @@ static int dnxhd_decode_header(DNXHDContext *ctx, AVFrame 
*frame,
 return 0;
 }
 
-static av_always_inline void dnxhd_decode_dct_block(const DNXHDContext *ctx,
+static av_always_inline int dnxhd_decode_dct_block(const DNXHDContext *ctx,
 RowContext *row,
 int n,
 int index_bits,
@@ -280,6 +281,7 @@ static av_always_inline void dnxhd_decode_dct_block(const 
DNXHDContext *ctx,
 const uint8_t *ac_flags = ctx->cid_table->ac_flags;
 int16_t *block = row->blocks[n];
 const int eob_index = ctx->cid_table->eob_index;
+int ret = 0;
 OPEN_READER(bs, >gb);
 
 ctx->bdsp.clear_block(block);
@@ -343,6 +345,7 @@ static av_always_inline void dnxhd_decode_dct_block(const 
DNXHDContext *ctx,
 
 if (++i > 63) {
 av_log(ctx->avctx, AV_LOG_ERROR, "ac tex damaged %d, %d\n", n, i);
+ret = -1;
 break;
 }
 
@@ -360,24 +363,25 @@ static av_always_inline void dnxhd_decode_dct_block(const 
DNXHDContext *ctx,
 }
 
 CLOSE_READER(bs, >gb);
+return ret;
 }
 
-static void dnxhd_decode_dct_block_8(const DNXHDContext *ctx,
+static int dnxhd_decode_dct_block_8(const DNXHDContext *ctx,
  RowContext *row, int n)
 {
-dnxhd_decode_dct_block(ctx, row, n, 4, 32, 6);
+return dnxhd_decode_dct_block(ctx, row, n, 4, 32, 6);
 }
 
-static void dnxhd_decode_dct_block_10(const DNXHDContext *ctx,
+static int dnxhd_decode_dct_block_10(const DNXHDContext *ctx,
   RowContext *row, int n)
 {
-dnxhd_decode_dct_block(ctx, row, n, 6, 8, 4);
+return dnxhd_decode_dct_block(ctx, row, n, 6, 8, 4);
 }
 
-static void dnxhd_decode_dct_block_10_444(const DNXHDContext *ctx,
+static int dnxhd_decode_dct_block_10_444(const DNXHDContext *ctx,
   RowContext *row, int n)
 {
-dnxhd_decode_dct_block(ctx, row, n, 6, 32, 6);
+return dnxhd_decode_dct_block(ctx, row, n, 6, 32, 6);
 }
 
 static int dnxhd_decode_macroblock(const DNXHDContext *ctx, RowContext *row,
@@ -415,7 +419,8 @@ static int dnxhd_decode_macroblock(const DNXHDContext *ctx, 
RowContext *row,
 }
 
 for (i = 0; i < 8 + 4 * ctx->is_444; i++) {
-ctx->decode_dct_block(ctx, row, i);
+if (ctx->decode_dct_block(ctx, row, i) < 0)
+return AVERROR_INVALIDDATA;
 }
 
 if (frame->interlaced_frame) {
@@ -488,7 +493,11 @@ static int dnxhd_decode_row(AVCodecContext *avctx, void 
*data,
 init_get_bits(>gb, ctx->buf + offset, (ctx->buf_size - offset) << 3);
 for (x = 0; x < ctx->mb_width; x++) {
 //START_TIMER;
-dnxhd_decode_macroblock(ctx, row, data, x, rownb);
+int ret = dnxhd_decode_macroblock(ctx, row, data, x, rownb);
+if (ret < 0) {
+row->errors++;
+return ret;
+}
 //STOP_TIMER("decode macroblock");
 }
 
@@ -504,7 +513,7 @@ static int dnxhd_decode_frame(AVCodecContext *avctx, void 
*data,
 ThreadFrame frame = { .f = data };
 AVFrame *picture = data;
 int first_field = 1;
-int ret;
+int ret, i;
 
 ff_dlog(avctx, "frame size %d\n", buf_size);
 
@@ -547,6 +556,17 @@ decode_coding_unit:
 goto decode_coding_unit;
 }
 
+ret = 0;
+for (i = 0; i < avctx->thread_count; i++) {

[FFmpeg-devel] [PATCH 1/7] dnxhddec: remove unused qscale parameter

2015-09-27 Thread Christophe Gisquet
---
 libavcodec/dnxhddec.c | 25 -
 1 file changed, 12 insertions(+), 13 deletions(-)

diff --git a/libavcodec/dnxhddec.c b/libavcodec/dnxhddec.c
index fa93407..34cf379 100644
--- a/libavcodec/dnxhddec.c
+++ b/libavcodec/dnxhddec.c
@@ -63,7 +63,7 @@ typedef struct DNXHDContext {
 int act;
 void (*decode_dct_block)(const struct DNXHDContext *ctx,
  RowContext *row, int16_t *block,
- int n, int qscale);
+ int n);
 } DNXHDContext;
 
 #define DNXHD_VLC_BITS 9
@@ -71,13 +71,13 @@ typedef struct DNXHDContext {
 
 static void dnxhd_decode_dct_block_8(const DNXHDContext *ctx,
  RowContext *row, int16_t *block,
- int n, int qscale);
+ int n);
 static void dnxhd_decode_dct_block_10(const DNXHDContext *ctx,
   RowContext *row, int16_t *block,
-  int n, int qscale);
+  int n);
 static void dnxhd_decode_dct_block_10_444(const DNXHDContext *ctx,
   RowContext *row, int16_t *block,
-  int n, int qscale);
+  int n);
 
 static av_cold int dnxhd_decode_init(AVCodecContext *avctx)
 {
@@ -272,7 +272,6 @@ static int dnxhd_decode_header(DNXHDContext *ctx, AVFrame 
*frame,
 static av_always_inline void dnxhd_decode_dct_block(const DNXHDContext *ctx,
 RowContext *row,
 int16_t *block, int n,
-int qscale,
 int index_bits,
 int level_bias,
 int level_shift)
@@ -366,23 +365,23 @@ static av_always_inline void dnxhd_decode_dct_block(const 
DNXHDContext *ctx,
 
 static void dnxhd_decode_dct_block_8(const DNXHDContext *ctx,
  RowContext *row, int16_t *block,
- int n, int qscale)
+ int n)
 {
-dnxhd_decode_dct_block(ctx, row, block, n, qscale, 4, 32, 6);
+dnxhd_decode_dct_block(ctx, row, block, n, 4, 32, 6);
 }
 
 static void dnxhd_decode_dct_block_10(const DNXHDContext *ctx,
   RowContext *row, int16_t *block,
-  int n, int qscale)
+  int n)
 {
-dnxhd_decode_dct_block(ctx, row, block, n, qscale, 6, 8, 4);
+dnxhd_decode_dct_block(ctx, row, block, n, 6, 8, 4);
 }
 
 static void dnxhd_decode_dct_block_10_444(const DNXHDContext *ctx,
   RowContext *row, int16_t *block,
-  int n, int qscale)
+  int n)
 {
-dnxhd_decode_dct_block(ctx, row, block, n, qscale, 6, 32, 6);
+dnxhd_decode_dct_block(ctx, row, block, n, 6, 32, 6);
 }
 
 static int dnxhd_decode_macroblock(const DNXHDContext *ctx, RowContext *row,
@@ -421,12 +420,12 @@ static int dnxhd_decode_macroblock(const DNXHDContext 
*ctx, RowContext *row,
 
 for (i = 0; i < 8; i++) {
 ctx->bdsp.clear_block(row->blocks[i]);
-ctx->decode_dct_block(ctx, row, row->blocks[i], i, qscale);
+ctx->decode_dct_block(ctx, row, row->blocks[i], i);
 }
 if (ctx->is_444) {
 for (; i < 12; i++) {
 ctx->bdsp.clear_block(row->blocks[i]);
-ctx->decode_dct_block(ctx, row, row->blocks[i], i, qscale);
+ctx->decode_dct_block(ctx, row, row->blocks[i], i);
 }
 }
 
-- 
2.5.2

___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-devel


Re: [FFmpeg-devel] [PATCH]h264: Fix ticket #3147 H264 - Wrong field order

2015-09-27 Thread Thomas Mundt
Hi Kieran,
no, you´re right. I misinterpreted SEI_PIC_STRUCT_FRAME because it´s also the 
default when pic_struct_present_flag is 0. Just checked avci header - no 
pic_struct_present_flag. Sorry!But fixing avci field order detection should be 
done.Does attached patch make more sense to you?
Regards,Thomas


 Kieran Kunhya  schrieb am 20:59 Samstag, 26.September 2015:
   

 On 26 September 2015 at 16:59, Thomas Mundt
 wrote:
> Hi,
> some h264 encoders, like broadcast avc-intra in this case

avc-intra sets pic-struct. Is this new?

Kieran
___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-devel


  

h264.diff
Description: Binary data
___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-devel


[FFmpeg-devel] [PATCH 6/7] dnxhddata: deduplicate table

2015-09-27 Thread Christophe Gisquet
CID 1256 chroma table is the same as luma table for CID 1235 and 1256,
which is consistent with the content being (normally) RGB.

CID 1244 weight tables are identica to CID 1244, but as this was not
tested against a real sample, it was not added.
---
 libavcodec/dnxhddata.c | 16 +++-
 1 file changed, 3 insertions(+), 13 deletions(-)

diff --git a/libavcodec/dnxhddata.c b/libavcodec/dnxhddata.c
index cc304e4..2fbc162 100644
--- a/libavcodec/dnxhddata.c
+++ b/libavcodec/dnxhddata.c
@@ -25,7 +25,7 @@
 
 /* The quantization tables below are in zigzag order! */
 
-/* Used in CID 1235, 1256 */
+/* Used in CID 1235, 1256 luma/chroma*/
 static const uint8_t dnxhd_1235_luma_weight[] = {
  0, 32, 32, 32, 33, 32, 32, 32,
 32, 31, 32, 33, 33, 33, 33, 35,
@@ -228,17 +228,7 @@ static const uint8_t dnxhd_1252_chroma_weight[] = {
 114, 128, 125, 129, 134, 125, 116, 116,
 };
 
-static const uint8_t dnxhd_1256_chroma_weight[] = {
- 0, 32, 32, 32, 32, 32, 32, 32,
-32, 32, 32, 32, 32, 32, 32, 32,
-32, 32, 32, 32, 32, 32, 37, 32,
-32, 32, 32, 32, 33, 32, 32, 32,
-32, 32, 33, 34, 37, 36, 32, 32,
-32, 33, 34, 37, 36, 34, 35, 36,
-39, 44, 40, 40, 39, 39, 44, 43,
-43, 51, 56, 50, 49, 60, 61, 70,
-};
-
+/* Also used in CID 1244, but not yet implemented */
 static const uint8_t dnxhd_1260_luma_weight[] = {
  0, 32, 33, 34, 36, 37, 37, 36,
 34, 33, 34, 35, 37, 38, 40, 41,
@@ -1041,7 +1031,7 @@ const CIDEntry ff_dnxhd_cid_table[] = {
   { 36, 36, 45, 75, 90 },
   { { 24000, 1001 }, { 25, 1 }, { 3, 1001 }, { 50, 1 }, { 6, 1001 
} } },
 { 1256, 1920, 1080, 0, 1835008, 1835008, 6, 10, 4,
-  dnxhd_1235_luma_weight, dnxhd_1256_chroma_weight,
+  dnxhd_1235_luma_weight, dnxhd_1235_luma_weight,
   dnxhd_1235_dc_codes, dnxhd_1235_dc_bits,
   dnxhd_1235_ac_codes, dnxhd_1235_ac_bits, dnxhd_1235_ac_level,
   dnxhd_1235_ac_flags,
-- 
2.5.2

___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-devel


[FFmpeg-devel] [PATCH 5/7] dnxhddec: reindent/cosmetics

2015-09-27 Thread Christophe Gisquet
---
 libavcodec/dnxhddec.c | 32 
 1 file changed, 16 insertions(+), 16 deletions(-)

diff --git a/libavcodec/dnxhddec.c b/libavcodec/dnxhddec.c
index 06d4780..7b96004 100644
--- a/libavcodec/dnxhddec.c
+++ b/libavcodec/dnxhddec.c
@@ -64,18 +64,18 @@ typedef struct DNXHDContext {
 int mbaff;
 int act;
 int (*decode_dct_block)(const struct DNXHDContext *ctx,
- RowContext *row, int n);
+RowContext *row, int n);
 } DNXHDContext;
 
 #define DNXHD_VLC_BITS 9
 #define DNXHD_DC_VLC_BITS 7
 
 static int dnxhd_decode_dct_block_8(const DNXHDContext *ctx,
- RowContext *row, int n);
+RowContext *row, int n);
 static int dnxhd_decode_dct_block_10(const DNXHDContext *ctx,
-  RowContext *row, int n);
+ RowContext *row, int n);
 static int dnxhd_decode_dct_block_10_444(const DNXHDContext *ctx,
-  RowContext *row, int n);
+ RowContext *row, int n);
 
 static av_cold int dnxhd_decode_init(AVCodecContext *avctx)
 {
@@ -153,8 +153,8 @@ static int dnxhd_decode_header(DNXHDContext *ctx, AVFrame 
*frame,
 int old_bit_depth = ctx->bit_depth;
 
 if (buf_size < 0x280) {
-av_log(ctx->avctx, AV_LOG_ERROR, "buffer too small (%d < 640).\n",
-   buf_size);
+av_log(ctx->avctx, AV_LOG_ERROR,
+   "buffer too small (%d < 640).\n", buf_size);
 return AVERROR_INVALIDDATA;
 }
 
@@ -199,8 +199,8 @@ static int dnxhd_decode_header(DNXHDContext *ctx, AVFrame 
*frame,
 ctx->is_444 = 0;
 ctx->decode_dct_block = dnxhd_decode_dct_block_8;
 } else {
-av_log(ctx->avctx, AV_LOG_ERROR, "invalid bit depth value (%d).\n",
-   buf[0x21]);
+av_log(ctx->avctx, AV_LOG_ERROR,
+   "invalid bit depth value (%d).\n", buf[0x21]);
 return AVERROR_INVALIDDATA;
 }
 if (ctx->bit_depth != old_bit_depth) {
@@ -268,11 +268,11 @@ static int dnxhd_decode_header(DNXHDContext *ctx, AVFrame 
*frame,
 }
 
 static av_always_inline int dnxhd_decode_dct_block(const DNXHDContext *ctx,
-RowContext *row,
-int n,
-int index_bits,
-int level_bias,
-int level_shift)
+   RowContext *row,
+   int n,
+   int index_bits,
+   int level_bias,
+   int level_shift)
 {
 int i, j, index1, index2, len, flags;
 int level, component, sign;
@@ -368,19 +368,19 @@ static av_always_inline int dnxhd_decode_dct_block(const 
DNXHDContext *ctx,
 }
 
 static int dnxhd_decode_dct_block_8(const DNXHDContext *ctx,
- RowContext *row, int n)
+RowContext *row, int n)
 {
 return dnxhd_decode_dct_block(ctx, row, n, 4, 32, 6);
 }
 
 static int dnxhd_decode_dct_block_10(const DNXHDContext *ctx,
-  RowContext *row, int n)
+ RowContext *row, int n)
 {
 return dnxhd_decode_dct_block(ctx, row, n, 6, 8, 4);
 }
 
 static int dnxhd_decode_dct_block_10_444(const DNXHDContext *ctx,
-  RowContext *row, int n)
+ RowContext *row, int n)
 {
 return dnxhd_decode_dct_block(ctx, row, n, 6, 32, 6);
 }
-- 
2.5.2

___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-devel


[FFmpeg-devel] [PATCH 7/7] dnxhddec: add my contributions

2015-09-27 Thread Christophe Gisquet
---
 libavcodec/dnxhddec.c | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/libavcodec/dnxhddec.c b/libavcodec/dnxhddec.c
index 7b96004..423bce2 100644
--- a/libavcodec/dnxhddec.c
+++ b/libavcodec/dnxhddec.c
@@ -2,8 +2,10 @@
  * VC3/DNxHD decoder.
  * Copyright (c) 2007 SmartJog S.A., Baptiste Coudurier 
  * Copyright (c) 2011 MirriAd Ltd
+ * Copyright (c) 2015 Christophe Gisquet
  *
  * 10 bit support added by MirriAd Ltd, Joseph Artsimovich 
+ * Slice multithreading and MB interlaced support added by Christophe Gisquet
  *
  * This file is part of FFmpeg.
  *
-- 
2.5.2

___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-devel


Re: [FFmpeg-devel] [PATCH 2/7] dnxhddec: simplify block parsing calls

2015-09-27 Thread Michael Niedermayer
On Sun, Sep 27, 2015 at 10:09:03AM +0200, Christophe Gisquet wrote:
> Fewer arguments, less duplicated code.
> ---
>  libavcodec/dnxhddec.c | 43 ---
>  1 file changed, 16 insertions(+), 27 deletions(-)

applied

thanks

[...]
-- 
Michael GnuPG fingerprint: 9FF2128B147EF6730BADF133611EC787040B0FAB

Republics decline into democracies and democracies degenerate into
despotisms. -- Aristotle


signature.asc
Description: Digital signature
___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-devel


Re: [FFmpeg-devel] [PATCH 1/7] dnxhddec: remove unused qscale parameter

2015-09-27 Thread Michael Niedermayer
On Sun, Sep 27, 2015 at 10:09:02AM +0200, Christophe Gisquet wrote:
> ---
>  libavcodec/dnxhddec.c | 25 -
>  1 file changed, 12 insertions(+), 13 deletions(-)

applied

thanks

[...]
-- 
Michael GnuPG fingerprint: 9FF2128B147EF6730BADF133611EC787040B0FAB

If you think the mosad wants you dead since a long time then you are either
wrong or dead since a long time.


signature.asc
Description: Digital signature
___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-devel


Re: [FFmpeg-devel] [PATCH] avformat/hls: remove unused function

2015-09-27 Thread compn
On Sat, 26 Sep 2015 19:20:57 +0200
Hendrik Leppkes  wrote:

> On Sat, Sep 26, 2015 at 7:00 PM, wm4  wrote:
> > On Sat, 26 Sep 2015 12:53:58 -0400
> > Ganesh Ajjanagadde  wrote:
> >
> >> On Sat, Sep 26, 2015 at 12:37 PM, wm4 
> >> wrote:
> >> > On Sat, 26 Sep 2015 12:12:44 -0400
> >> > Ganesh Ajjanagadde  wrote:
> >> >
> >> >> On Sat, Sep 26, 2015 at 12:06 PM, wm4 
> >> >> wrote:
> >> >> > On Sat, 26 Sep 2015 10:59:44 -0400
> >> >> > Ganesh Ajjanagadde  wrote:
> >> >> >
> >> >> >> On Fri, Sep 18, 2015 at 11:16 AM, Ganesh Ajjanagadde
> >> >> >>  wrote:
> >> >> >> > On Fri, Sep 18, 2015 at 11:08 AM, wm4
> >> >> >> >  wrote:
> >> >> >> >> On 18.09.2015 15:09, Ganesh Ajjanagadde wrote:
> >> >> >> >>>
> >> >> >> >>> On Wed, Sep 16, 2015 at 8:26 PM, Ganesh Ajjanagadde
> >> >> >> >>>  wrote:
> >> >> >> 
> >> >> >>  Fixes -Wunused-function from
> >> >> >> 
> >> >> >>  http://fate.ffmpeg.org/report.cgi?time=20150820031140=arm64-darwin-clang-apple-5.1
> >> >> >> 
> >> >> >>  Signed-off-by: Ganesh Ajjanagadde
> >> >> >>   ---
> >> >> >>    libavformat/hls.c | 13 -
> >> >> >>    1 file changed, 13 deletions(-)
> >> >> >> 
> >> >> >>  diff --git a/libavformat/hls.c b/libavformat/hls.c
> >> >> >>  index c16c770..2ea3a22 100644
> >> >> >>  --- a/libavformat/hls.c
> >> >> >>  +++ b/libavformat/hls.c
> >> >> >>  @@ -495,19 +495,6 @@ static int
> >> >> >>  ensure_playlist(HLSContext *c, struct playlist **pls,
> >> >> >>  const char *url return 0;
> >> >> >>    }
> >> >> >> 
> >> >> >>  -static int open_in(HLSContext *c, AVIOContext **in,
> >> >> >>  const char *url) -{
> >> >> >>  -AVDictionary *tmp = NULL;
> >> >> >>  -int ret;
> >> >> >>  -
> >> >> >>  -av_dict_copy(, c->avio_opts, 0);
> >> >> >>  -
> >> >> >>  -ret = avio_open2(in, url, AVIO_FLAG_READ,
> >> >> >>  c->interrupt_callback, );
> >> >> >>  -
> >> >> >>  -av_dict_free();
> >> >> >>  -return ret;
> >> >> >>  -}
> >> >> >>  -
> >> >> >>    static int url_connect(struct playlist *pls,
> >> >> >>  AVDictionary *opts, AVDictionary *opts2)
> >> >> >>    {
> >> >> >>    AVDictionary *tmp = NULL;
> >> >> >>  --
> >> >> >>  2.5.2
> >> >> >> 
> >> >> >> >>>
> >> >> >> >>> ping; wm4 basically did not like my old patch: see
> >> >> >> >>> https://ffmpeg.org/pipermail/ffmpeg-devel/2015-August/177769.html
> >> >> >> >>> for his thoughts and my response. Here, I delete as
> >> >> >> >>> opposed to comment out the lines. I personally do not
> >> >> >> >>> care about deleting vs commenting out; but one of the
> >> >> >> >>> two should be used.
> >> >> >> >>
> >> >> >> >>
> >> >> >> >> If you think the inactive code is worth keeping, put it
> >> >> >> >> into a git branch or tag the commit removing the code.t
> >> >> >> >
> >> >> >> > I do not have write access, so I will leave it up to you
> >> >> >> > (or anyone else pushing) to either apply the old patch or
> >> >> >> > this one (and possibly tag it if desired).
> >> >> >>
> >> >> >> See above for two possiblities on resolving this: either
> >> >> >> this patch (optionally tagging it), or simply commenting out
> >> >> >> the function (see above for link to old patch).
> >> >> >> Ping.
> >> >> >
> >> >> > Just get rid of this. I had to deal with the HLS code lately,
> >> >> > and it was utterly confusing that there was this unused
> >> >> > function.
> >> >> >
> >> >> > Also, this function is so trivial, that anyone really needing
> >> >> > it could rewrite it in under a minute, and it'd probably be
> >> >> > an improvement too. Even discussing keeping this is a waste
> >> >> > of energy.
> >> >>
> >> >> Please push this patch then; you have write access and I don't.
> >> >
> >> > Send your SSH key to Michael Niedermayer. I'll apply this patch
> >> > in a moment.
> >>
> >> Michael offered write access a month back, to which I replied
> >> saying that I do not trust myself with it at the moment and would
> >> like to wait a year. I also said that I would reconsider if it is
> >> leading to wasted maintainer time. Our back and forth here
> >> suggests that there is some wastage.
> >>
> >> If no one objects to me getting write access, I will send it to
> >> Michael. Please note that the intention right now is not for any
> >> "maintainership" duties, but simply to ease the application of
> >> reviewed patches.
> >
> > Yes, it's much better for everyone if you just push your own
> > patches, after they have been OK'ed.
> 
> Personally I find giving new people push access after only 3 months of
> activity slightly premature.

so if they have been around for 6 months its better?

i figure if anyone is here, 

Re: [FFmpeg-devel] [PATCH] avformat/hls: remove unused function

2015-09-27 Thread Hendrik Leppkes
On Sun, Sep 27, 2015 at 12:32 PM, compn  wrote:
> On Sat, 26 Sep 2015 19:20:57 +0200
> Hendrik Leppkes  wrote:
>
>> On Sat, Sep 26, 2015 at 7:00 PM, wm4  wrote:
>> > On Sat, 26 Sep 2015 12:53:58 -0400
>> > Ganesh Ajjanagadde  wrote:
>> >
>> >> On Sat, Sep 26, 2015 at 12:37 PM, wm4 
>> >> wrote:
>> >> > On Sat, 26 Sep 2015 12:12:44 -0400
>> >> > Ganesh Ajjanagadde  wrote:
>> >> >
>> >> >> On Sat, Sep 26, 2015 at 12:06 PM, wm4 
>> >> >> wrote:
>> >> >> > On Sat, 26 Sep 2015 10:59:44 -0400
>> >> >> > Ganesh Ajjanagadde  wrote:
>> >> >> >
>> >> >> >> On Fri, Sep 18, 2015 at 11:16 AM, Ganesh Ajjanagadde
>> >> >> >>  wrote:
>> >> >> >> > On Fri, Sep 18, 2015 at 11:08 AM, wm4
>> >> >> >> >  wrote:
>> >> >> >> >> On 18.09.2015 15:09, Ganesh Ajjanagadde wrote:
>> >> >> >> >>>
>> >> >> >> >>> On Wed, Sep 16, 2015 at 8:26 PM, Ganesh Ajjanagadde
>> >> >> >> >>>  wrote:
>> >> >> >> 
>> >> >> >>  Fixes -Wunused-function from
>> >> >> >> 
>> >> >> >>  http://fate.ffmpeg.org/report.cgi?time=20150820031140=arm64-darwin-clang-apple-5.1
>> >> >> >> 
>> >> >> >>  Signed-off-by: Ganesh Ajjanagadde
>> >> >> >>   ---
>> >> >> >>    libavformat/hls.c | 13 -
>> >> >> >>    1 file changed, 13 deletions(-)
>> >> >> >> 
>> >> >> >>  diff --git a/libavformat/hls.c b/libavformat/hls.c
>> >> >> >>  index c16c770..2ea3a22 100644
>> >> >> >>  --- a/libavformat/hls.c
>> >> >> >>  +++ b/libavformat/hls.c
>> >> >> >>  @@ -495,19 +495,6 @@ static int
>> >> >> >>  ensure_playlist(HLSContext *c, struct playlist **pls,
>> >> >> >>  const char *url return 0;
>> >> >> >>    }
>> >> >> >> 
>> >> >> >>  -static int open_in(HLSContext *c, AVIOContext **in,
>> >> >> >>  const char *url) -{
>> >> >> >>  -AVDictionary *tmp = NULL;
>> >> >> >>  -int ret;
>> >> >> >>  -
>> >> >> >>  -av_dict_copy(, c->avio_opts, 0);
>> >> >> >>  -
>> >> >> >>  -ret = avio_open2(in, url, AVIO_FLAG_READ,
>> >> >> >>  c->interrupt_callback, );
>> >> >> >>  -
>> >> >> >>  -av_dict_free();
>> >> >> >>  -return ret;
>> >> >> >>  -}
>> >> >> >>  -
>> >> >> >>    static int url_connect(struct playlist *pls,
>> >> >> >>  AVDictionary *opts, AVDictionary *opts2)
>> >> >> >>    {
>> >> >> >>    AVDictionary *tmp = NULL;
>> >> >> >>  --
>> >> >> >>  2.5.2
>> >> >> >> 
>> >> >> >> >>>
>> >> >> >> >>> ping; wm4 basically did not like my old patch: see
>> >> >> >> >>> https://ffmpeg.org/pipermail/ffmpeg-devel/2015-August/177769.html
>> >> >> >> >>> for his thoughts and my response. Here, I delete as
>> >> >> >> >>> opposed to comment out the lines. I personally do not
>> >> >> >> >>> care about deleting vs commenting out; but one of the
>> >> >> >> >>> two should be used.
>> >> >> >> >>
>> >> >> >> >>
>> >> >> >> >> If you think the inactive code is worth keeping, put it
>> >> >> >> >> into a git branch or tag the commit removing the code.t
>> >> >> >> >
>> >> >> >> > I do not have write access, so I will leave it up to you
>> >> >> >> > (or anyone else pushing) to either apply the old patch or
>> >> >> >> > this one (and possibly tag it if desired).
>> >> >> >>
>> >> >> >> See above for two possiblities on resolving this: either
>> >> >> >> this patch (optionally tagging it), or simply commenting out
>> >> >> >> the function (see above for link to old patch).
>> >> >> >> Ping.
>> >> >> >
>> >> >> > Just get rid of this. I had to deal with the HLS code lately,
>> >> >> > and it was utterly confusing that there was this unused
>> >> >> > function.
>> >> >> >
>> >> >> > Also, this function is so trivial, that anyone really needing
>> >> >> > it could rewrite it in under a minute, and it'd probably be
>> >> >> > an improvement too. Even discussing keeping this is a waste
>> >> >> > of energy.
>> >> >>
>> >> >> Please push this patch then; you have write access and I don't.
>> >> >
>> >> > Send your SSH key to Michael Niedermayer. I'll apply this patch
>> >> > in a moment.
>> >>
>> >> Michael offered write access a month back, to which I replied
>> >> saying that I do not trust myself with it at the moment and would
>> >> like to wait a year. I also said that I would reconsider if it is
>> >> leading to wasted maintainer time. Our back and forth here
>> >> suggests that there is some wastage.
>> >>
>> >> If no one objects to me getting write access, I will send it to
>> >> Michael. Please note that the intention right now is not for any
>> >> "maintainership" duties, but simply to ease the application of
>> >> reviewed patches.
>> >
>> > Yes, it's much better for everyone if you just push your own
>> > patches, after they have been OK'ed.
>>
>>