Re: [FFmpeg-devel] Google Summer of Code

2017-03-03 Thread Reynaldo H. Verdejo Pinochet

Hi Vidur. Please double check you got Paul's email as it
might contain additional information. However, the
generalities of the program are documented in the following
webpage. Please do take a look at it if you haven't already:

https://trac.ffmpeg.org/wiki/SponsoringPrograms/GSoC/2017

Bests,

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


Re: [FFmpeg-devel] GSoC 2017 MPEG-4 ALS codec project

2017-02-27 Thread Reynaldo H. Verdejo Pinochet


On 02/19/2017 09:30 AM, Thilo Borgmann wrote:

[..]

Although, be aware that the list of accepted organizations is yet to be 
published - we do not know yet if FFmpeg will be part of GSoC 2017.



We can confirm this now. Participating orgs were announced today.

Good luck with your quali George!

Bests,

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


Re: [FFmpeg-devel] [DECISION] Revoke the decision of dropping ffserver

2016-12-04 Thread Reynaldo H. Verdejo Pinochet

I support the decision to keep ffserver

Bests,

--
Reynaldo H. Verdejo Pinochet
Open Source Group - Samsung Research America

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


Re: [FFmpeg-devel] [PATCH 1/6] tests/ffserver.regression.ref: Update ffserver checksums

2016-12-01 Thread Reynaldo H. Verdejo Pinochet

Good to go

On 12/01/2016 08:37 AM, Michael Niedermayer wrote:

They have changed due to 122190392b297b7cd9783641d880df887fd80d07

Signed-off-by: Michael Niedermayer <mich...@niedermayer.cc>
---
  tests/ffserver.regression.ref | 4 ++--
  1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/tests/ffserver.regression.ref b/tests/ffserver.regression.ref
index 3106f85..398c285 100644
--- a/tests/ffserver.regression.ref
+++ b/tests/ffserver.regression.ref
@@ -1,5 +1,5 @@
-233020d119085ba47535d5f2faf73cc0 *ff-test_h.avi
-431b75d1f12cb039acebad61a3d39225 *ff-test_l.avi
+0c9639f09decbc54c9f091dcf1ca0e8f *ff-test_h.avi
+e28ba75853caf975e06d92955c9f7f73 *ff-test_l.avi
  a767dbdf5d1bded3450279f812f97b37 *ff-test.swf
  dc16f607e13328a832e73801cd21ec98 *ff-test_h.asf
  69337d6c8cd7ac7e626338decdbf41d3 *ff-test_l.asf


--
Reynaldo H. Verdejo Pinochet
Open Source Group - Samsung Research America

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


Re: [FFmpeg-devel] [PATCH] ffserver: set format bitexact flag, eliminate warnings about it not being set

2016-12-01 Thread Reynaldo H. Verdejo Pinochet

Looks good & works correctly Michael. Please feel free to push. Thank you.

On 12/01/2016 09:02 AM, Michael Niedermayer wrote:

if (src->codec->flags & AV_CODEC_FLAG_BITEXACT)
+c->pfmt_ctx->flags |= AVFMT_FLAG_BITEXACT;


--
Reynaldo H. Verdejo Pinochet
Open Source Group - Samsung Research America

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


Re: [FFmpeg-devel] [PATCH] ffserver: Add client requested urls to the status page

2016-11-29 Thread Reynaldo H. Verdejo Pinochet

Looks good to go. Thank you!


On 11/29/2016 01:38 PM, Michael Niedermayer wrote:

Fixes Ticket3791

Signed-off-by: Michael Niedermayer <mich...@niedermayer.cc>
---
  ffserver.c| 38 +++---
  tests/ffserver-regression.sh  |  2 +-
  tests/ffserver.regression.ref |  2 +-
  3 files changed, 37 insertions(+), 5 deletions(-)

diff --git a/ffserver.c b/ffserver.c
index 20f5995..8745181 100644
--- a/ffserver.c
+++ b/ffserver.c
@@ -164,6 +164,7 @@ typedef struct HTTPContext {
  char protocol[16];
  char method[16];
  char url[128];
+char clean_url[128*7];
  int buffer_size;
  uint8_t *buffer;
  int is_packetized; /* if true, the stream is packetized */
@@ -1920,6 +1921,34 @@ static inline void print_stream_params(AVIOContext *pb, 
FFServerStream *stream)
   avio_printf(pb, "\n");
  }
  
+static void clean_html(char *clean, int clean_len, char *dirty)

+{
+int i, o;
+
+for (o = i = 0; o+10 < clean_len && dirty[i];) {
+int len = strspn(dirty+i, 
"0123456789abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ$-_.+!*(),?/ 
:;%");
+if (len) {
+if (o + len >= clean_len)
+break;
+memcpy(clean + o, dirty + i, len);
+i += len;
+o += len;
+} else {
+int c = dirty[i++];
+switch (c) {
+case  '&': av_strlcat(clean+o, ""  , clean_len - o); break;
+case  '<': av_strlcat(clean+o, ""   , clean_len - o); break;
+case  '>': av_strlcat(clean+o, ""   , clean_len - o); break;
+case '\'': av_strlcat(clean+o, "" , clean_len - o); break;
+case '\"': av_strlcat(clean+o, "" , clean_len - o); break;
+default:   av_strlcat(clean+o, "", clean_len - o); break;
+}
+o += strlen(clean+o);
+}
+}
+clean[o] = 0;
+}
+
  static void compute_status(HTTPContext *c)
  {
  HTTPContext *c1;
@@ -2107,7 +2136,7 @@ static void compute_status(HTTPContext *c)
  current_bandwidth, config.max_bandwidth);
  
  avio_printf(pb, "\n");

-avio_printf(pb, "#FileIPProtoStateTarget "
+avio_printf(pb, "#FileIPURLProtoStateTarget 
"
  "bit/sActual bit/sBytes transferred\n");
  c1 = first_http_ctx;
  i = 0;
@@ -2127,10 +2156,13 @@ static void compute_status(HTTPContext *c)
  
  i++;

  p = inet_ntoa(c1->from_addr.sin_addr);
-avio_printf(pb, "%d%s%s%s%s%s"
+clean_html(c1->clean_url, sizeof(c1->clean_url), c1->url);
+avio_printf(pb, "%d%s%s%s%s%s%s"
  "",
  i, c1->stream ? c1->stream->filename : "",
-c1->state == HTTPSTATE_RECEIVE_DATA ? "(input)" : "", p,
+c1->state == HTTPSTATE_RECEIVE_DATA ? "(input)" : "",
+p,
+c1->clean_url,
  c1->protocol, http_state[c1->state]);
  fmt_bytecount(pb, bitrate);
  avio_printf(pb, "");
diff --git a/tests/ffserver-regression.sh b/tests/ffserver-regression.sh
index b776bad..17e9060 100755
--- a/tests/ffserver-regression.sh
+++ b/tests/ffserver-regression.sh
@@ -28,7 +28,7 @@ sleep 2
  fi
  do_md5sum ff-$file >>ffserver.regression
  done
-wget  $WGET_OPTIONS -O - teststat.html http://localhost:/teststat.html > 
ff-stat 2>/dev/null
+wget  $WGET_OPTIONS -O - 'http://localhost:/teststat.html?abc' > ff-stat 
2>/dev/null
  do_md5sum ff-stat >>ffserver.regression
  )
  kill $FFSERVER_PID
diff --git a/tests/ffserver.regression.ref b/tests/ffserver.regression.ref
index ec7b37c..8629d52 100644
--- a/tests/ffserver.regression.ref
+++ b/tests/ffserver.regression.ref
@@ -8,4 +8,4 @@ d41d8cd98f00b204e9800998ecf8427e *ff-test_l.rm
  4c887dfc1dd0f6ea1a3a2be6dd32e495 *ff-test.jpg
  1d04b73b04aad27793cc762d5afabac1 *ff-test_small.jpg
  bc36c40ee34ebee6ffe50f3094aab733 *ff-test.mjpg
-9b72c3d6d89a038fa141fe636baa2c0e *ff-stat
+56c8b3ba2c4f3eebfa6d2a895e042ee3 *ff-stat


--
Reynaldo H. Verdejo Pinochet
Open Source Group - Samsung Research America

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


Re: [FFmpeg-devel] [PATCH 1/3] tests: print errors from ffserver

2016-11-29 Thread Reynaldo H. Verdejo Pinochet

The entire set looks good to go. Please feel free to push.

Thank you!


On 11/29/2016 05:27 PM, Andreas Cadhalpun wrote:

Not doing so makes debugging unnecessarily hard.

Signed-off-by: Andreas Cadhalpun <andreas.cadhal...@googlemail.com>
---
  tests/ffserver-regression.sh | 2 +-
  1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/tests/ffserver-regression.sh b/tests/ffserver-regression.sh
index b776bad..47d6016 100755
--- a/tests/ffserver-regression.sh
+++ b/tests/ffserver-regression.sh
@@ -12,7 +12,7 @@ target_path=$5
  FILES=$(sed -n 's/^[^#]*.*/\1/p' $2 | grep -v html)
  
  rm -f tests/feed1.ffm

-$target_exec ${target_path}/ffserver${PROGSUF} -d -f "$2" 2> /dev/null &
+$target_exec ${target_path}/ffserver${PROGSUF} -d -f "$2" &
  FFSERVER_PID=$!
  echo "Waiting for feeds to startup..."
  sleep 2


--
Reynaldo H. Verdejo Pinochet
Open Source Group - Samsung Research America

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


Re: [FFmpeg-devel] [PATCH 1/2] tests/ffserver-regression.sh: give wget a timeout and prevent retries

2016-11-29 Thread Reynaldo H. Verdejo Pinochet

Both OK. Thanks.

--
Reynaldo H. Verdejo Pinochet
Open Source Group - Samsung Research America

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


Re: [FFmpeg-devel] [PATCH] ffserver: Remove last use of AVStream size

2016-11-28 Thread Reynaldo H. Verdejo Pinochet

Hi Michael

Looks good too. Please feel free to push
alongside the ones on the "Remove use of
AVStream.." thread.

Bests,

--
Reynaldo H. Verdejo Pinochet
Open Source Group - Samsung Research America
___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-devel


Re: [FFmpeg-devel] [PATCH 1/3] ffserver: drop FeedData, its unused

2016-11-28 Thread Reynaldo H. Verdejo Pinochet

Looks good. Thank you!

Bests,


--
Reynaldo H. Verdejo Pinochet
Open Source Group - Samsung Research America
___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-devel


Re: [FFmpeg-devel] [PATCH] Remove the ffserver program and the ffm muxer/demuxer

2016-11-28 Thread Reynaldo H. Verdejo Pinochet



On 11/26/2016 01:00 PM, Rostislav Pehlivanov wrote:

[..]
Since a month has passed, reynaldo still hasn't responded, I think it's


This is not correct. I have been working on weeding
out it's private API usage problems. Last commit to
this effect is from 3 weeks ago.

Bests,

--
Reynaldo H. Verdejo Pinochet
Open Source Group - Samsung Research America
___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-devel


Re: [FFmpeg-devel] [FFmpeg-cvslog] ffserver: get time_base from AVStream in print_stream_params()

2016-11-08 Thread Reynaldo H. Verdejo Pinochet



On 11/08/2016 06:29 AM, James Almer wrote:

[..]

Right now it just returns st->codec->time_base, but after st->codec is 
deprecated
it will be adapted to use st->internal->avctx->time_base.



Perfect! Will do. Thanks for the hint James.

Bests,

--
Reynaldo H. Verdejo Pinochet
Open Source Group - Samsung Research America
___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-devel


Re: [FFmpeg-devel] [PATCH 1/2] Move av_show_help_children() to avutil/opt

2016-11-07 Thread Reynaldo H. Verdejo Pinochet

Hi

On 11/07/2016 01:34 PM, Andreas Cadhalpun wrote:

[...]
Isn't the causality the other way around?
Because ffserver uses internal API it was decided to remove it.
If it gets fixed, there is no point in removing it, or is there?
[..]


I see no reason to remove it if it works properly.

Bests,

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


Re: [FFmpeg-devel] [PATCH 0/2] Move show_*() code from cmdutils to libs

2016-11-04 Thread Reynaldo H. Verdejo Pinochet



On 11/04/2016 01:16 PM, Michael Niedermayer wrote:


Printing the available codecs, decoders, encoders, bitstream filters and their
options and capabilities is usefull for Apps in general and not just ffmpeg.
[..]


We had a chat about this with Michael and I think it indeed makes
sense so +1 from me.

Bests,

--
Reynaldo H. Verdejo Pinochet
Open Source Group - Samsung Research America
___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-devel


Re: [FFmpeg-devel] [PATCH] news: add final report for summer of code 2016

2016-10-30 Thread Reynaldo H. Verdejo Pinochet

Thanks for the comments and corrections. Fixed the typos and pushed as:

commit f06598a8e1fcccef8c38a657162db309773d1515
Author: Reynaldo H. Verdejo Pinochet <reyna...@osg.samsung.com>
Date:   Sun Oct 30 01:37:26 2016 -0700

news: add final report for summer of code 2016


Bests,

--
Reynaldo H. Verdejo Pinochet
Open Source Group - Samsung Research America

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


Re: [FFmpeg-devel] [PATCH] Remove the ffserver program and the ffm muxer/demuxer

2016-10-28 Thread Reynaldo H. Verdejo Pinochet

Hi

I'm already working on what I think it's a proper transition in
line with the idea presented on my first reply to this thread.

My impression from today's discussion on IRC is that James
and Rostislav are willing to give this process some time but
nothing past next release.

Bests,


--
Reynaldo H. Verdejo Pinochet
Open Source Group - Samsung Research America

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


Re: [FFmpeg-devel] [PATCH] Remove the ffserver program and the ffm muxer/demuxer

2016-10-27 Thread Reynaldo H. Verdejo Pinochet

Hello

On 10/27/2016 11:25 AM, James Almer wrote:

[..]

This is not how things were agreed.



I haven't agreed to this.

The patch fixes nothing while breaking master
for ffserver users. There's a way forward, but
the patch can't be applied before it happens.

Bests,

--
Reynaldo H. Verdejo Pinochet
Open Source Group - Samsung Research America
___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-devel


Re: [FFmpeg-devel] [PATCH] Remove the ffserver program and the ffm muxer/demuxer

2016-10-27 Thread Reynaldo H. Verdejo Pinochet

I understand you might be upset but please refrain from
using bad language.

The way I see it your removal will happen once there's a
solution in place just not before. This is why the patch
is not rejected.

Bests,

--
Reynaldo H. Verdejo Pinochet
Open Source Group - Samsung Research America
___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-devel


Re: [FFmpeg-devel] [PATCH] Remove the ffserver program and the ffm muxer/demuxer

2016-10-27 Thread Reynaldo H. Verdejo Pinochet

I'm not OK with this patch. My reasons are:

* There are users relying on it
* We gain nothing by removing ffserver without a
  replacement or alternate solution

One solution I would support is a transition made by
moving all applications to a separate repo hosted within
the same infra. With a commitment not break our own apps.
The server will be fixed to work using public API in the
process. I can work on this with whoever wants to help.

Bests,


--
Reynaldo H. Verdejo Pinochet
Open Source Group - Samsung Research America
___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-devel


Re: [FFmpeg-devel] [PATCH 00/13] check all fclose usage

2016-01-12 Thread Reynaldo H. Verdejo Pinochet
Hi Ganesh

Somehow I'm missing your ffserver patches on this thread, had
to check them on gmame. Probably something odd with my local
filters. Commenting offline for the time being:

09/13 Its OK but actually introduces the error (-  }) you fix on
10/13... clean up accordingly
11, 12 & 13 LGTM


Bests,

-- 
Reynaldo H. Verdejo Pinochet
Open Source Group
Samsung Research America / Silicon Valley
___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-devel


Re: [FFmpeg-devel] [PATCH]ffserver: Cast time_t value when using it in a format string.

2015-12-27 Thread Reynaldo H. Verdejo Pinochet
Looks good.

On 12/22/2015 12:40 AM, Carl Eugen Hoyos wrote:
> Hi!
> 
> Attached patch should fix ticket #5103.
> 
> Please comment, Carl Eugen
> 
> 
> 
> ___
> ffmpeg-devel mailing list
> ffmpeg-devel@ffmpeg.org
> http://ffmpeg.org/mailman/listinfo/ffmpeg-devel
> 

-- 
Reynaldo H. Verdejo Pinochet
Open Source Group
Samsung Research America / Silicon Valley
___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-devel


Re: [FFmpeg-devel] [PATCH] libavtuil: add version component accessor macros

2015-12-06 Thread Reynaldo H. Verdejo Pinochet


On 12/05/2015 11:36 AM, Ganesh Ajjanagadde wrote:
> [...]
> 
> minor nit: commit message typo (libavtuil -> libavutil).
> 

True. Corrected. Thanks for taking a look

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


Re: [FFmpeg-devel] [PATCH] libavtuil: add version component accessor macros

2015-12-06 Thread Reynaldo H. Verdejo Pinochet
Pushed as:

commit 21c34cb26154a5eadd6e10df86c20e2df3a7bd55
Author: Reynaldo H. Verdejo Pinochet <reyna...@osg.samsung.com>
Date:   Fri Dec 4 14:07:23 2015 -0800

libavutil: add version component accessor macros

[..]

Thanks

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


Re: [FFmpeg-devel] [PATCH] libavtuil: add version component accessor macros

2015-12-05 Thread Reynaldo H. Verdejo Pinochet


On 12/05/2015 10:31 AM, Reynaldo H. Verdejo Pinochet wrote:
> Pretty standard macros, these should help libav*
> users avoid repeating ver.si.on parsing code,
> which aids in compatibility-checking tasks like
> identifying FFmpeg from Libav (_MICRO >= 100 check).

Actually ran into this while working on the GStreamer issue
here:

https://bugzilla.gnome.org/show_bug.cgi?id=758183

Bests,


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


[FFmpeg-devel] [PATCH] libavtuil: add version component accessor macros

2015-12-05 Thread Reynaldo H. Verdejo Pinochet
Pretty standard macros, these should help libav*
users avoid repeating ver.si.on parsing code,
which aids in compatibility-checking tasks like
identifying FFmpeg from Libav (_MICRO >= 100 check).
Something many are doing since we are not
intercompatible anymore.

Signed-off-by: Reynaldo H. Verdejo Pinochet <reyna...@osg.samsung.com>
---
 libavutil/version.h | 10 +-
 1 file changed, 9 insertions(+), 1 deletion(-)

diff --git a/libavutil/version.h b/libavutil/version.h
index e0ddfd2..22b67d1 100644
--- a/libavutil/version.h
+++ b/libavutil/version.h
@@ -37,6 +37,14 @@
 #define AV_VERSION(a, b, c) AV_VERSION_DOT(a, b, c)
 
 /**
+ * Extract version components from the full ::AV_VERSION_INT int as returned
+ * by functions like ::avformat_version() and ::avcodec_version()
+ */
+#define AV_VERSION_MAJOR(a) ((a) >> 16)
+#define AV_VERSION_MINOR(a) (((a) & 0x00FF00) >> 8)
+#define AV_VERSION_MICRO(a) ((a) & 0xFF)
+
+/**
  * @}
  */
 
@@ -56,7 +64,7 @@
  */
 
 #define LIBAVUTIL_VERSION_MAJOR  55
-#define LIBAVUTIL_VERSION_MINOR   9
+#define LIBAVUTIL_VERSION_MINOR  10
 #define LIBAVUTIL_VERSION_MICRO 100
 
 #define LIBAVUTIL_VERSION_INT   AV_VERSION_INT(LIBAVUTIL_VERSION_MAJOR, \
-- 
2.6.2

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


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

2015-11-30 Thread Reynaldo H. Verdejo Pinochet
This one looks OK (pending a final decision on
av_clipd64())

Bests,

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


Re: [FFmpeg-devel] [PATCH 2/2] ffserver: Clear avio context after closing it

2015-11-30 Thread Reynaldo H. Verdejo Pinochet


On 11/01/2015 09:34 AM, Michael Niedermayer wrote:
> [...]
> --- a/ffserver.c
> +++ b/ffserver.c
> @@ -2366,6 +2366,7 @@ static int http_prepare_data(HTTPContext *c)
>  
>  av_freep(>pb_buffer);
>  len = avio_close_dyn_buf(ctx->pb, >pb_buffer);
> +ctx->pb = NULL;

Looks good. I think there's a similar issue at the end
of rtp_new_av_stream() you might want to handle too but
please feel free to push as-is.

Bests,

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


Re: [FFmpeg-devel] [PATCH] ffserver: Fix memory leak and uncheked av_strdup return

2015-11-23 Thread Reynaldo H. Verdejo Pinochet


On 11/22/2015 11:10 AM, wm4 wrote:
> [..]
> 
> The function that's called here is generated by:
> 
> MAKE_ACCESSORS(AVStream, stream, char *, recommended_encoder_configuration)
> 
> This just copies the pointer. So I guess freeing it would generate a
> dangling pointer? And if the field was already set, you need to get and
> free the previous pointer?
> 
> (If this is correct, neither code makes sense. I must be missing
> something.)

Confused too. Will double check but in the mean time, I think it
would make sense to avoid calling get_recommended_() twice while
we are at this. The check and re-get seems racy although it might
not matter much in this context.

Bests,


-- 
Reynaldo H. Verdejo Pinochet
Open Source Group
Samsung Research America / Silicon Valley
___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-devel


[FFmpeg-devel] [PATCH] news: add thank you note for telepoint/mediahub

2015-10-12 Thread Reynaldo H. Verdejo Pinochet
Signed-off-by: Reynaldo H. Verdejo Pinochet <reyna...@osg.samsung.com>
---
 src/index | 33 +
 1 file changed, 33 insertions(+)

diff --git a/src/index b/src/index
index 77946a4..4dec768 100644
--- a/src/index
+++ b/src/index
@@ -37,6 +37,39 @@
 News
   
 
+  Telepoint & MediaHub are now supporting 
our project
+  
+A big thank you note goes to our newest supporters: MediaHub and Telepoint.
+Both companies have donated a dedicated server with free of charge internet
+connectivity. Here is a little bit about them on their own words:
+  
+
+  
+
+  
+http://www.telepoint.bg/en;>Telepoint is the biggest
+carrier-neutral data center in Bulgaria. Located in the heart of Sofia
+on a cross-road of many Bulgarian and International networks, the
+facility is a fully featured Tier 3 data center that provides flexible
+customer-oriented colocation solutions (ranging from a server to a
+private collocation hall) and a high level of security.
+  
+
+
+
+  
+MediaHub Ltd. is a Bulgarian IPTV platform and services provider which
+uses FFmpeg heavily since it started operating a year ago. "Donating
+to help keep FFmpeg online is our way of giving back to the community"
+.
+  
+
+  
+
+  
+Thanks Telepoint and MediaHub for their support!
+  
+
   September 29th, 2015, GSoC 2015 results
 
   
-- 
2.5.1

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


[FFmpeg-devel] [PATCH] af_pan: avoid null dereference on query_formats()

2015-10-08 Thread Reynaldo H. Verdejo Pinochet
Fixes Coverity CID 1325680

Signed-off-by: Reynaldo H. Verdejo Pinochet <reyna...@osg.samsung.com>
---
 libavfilter/af_pan.c | 4 
 1 file changed, 4 insertions(+)

diff --git a/libavfilter/af_pan.c b/libavfilter/af_pan.c
index 9117cc0..91cc434 100644
--- a/libavfilter/af_pan.c
+++ b/libavfilter/af_pan.c
@@ -239,6 +239,10 @@ static int query_formats(AVFilterContext *ctx)
 
 // inlink supports any channel layout
 layouts = ff_all_channel_counts();
+if (!layouts) {
+av_freep(formats);
+return AVERROR(ENOMEM);
+}
 ff_channel_layouts_ref(layouts, >out_channel_layouts);
 
 // outlink supports only requested output channel layout
-- 
2.5.1

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


Re: [FFmpeg-devel] [PATCH] af_pan: avoid null dereference on query_formats()

2015-10-08 Thread Reynaldo H. Verdejo Pinochet
Totally missed it. Thanks & please ignore. Proly a good idea
to update entry at coverity.com though.

Bests.

-- 
Reynaldo H. Verdejo Pinochet
Open Source Group
Samsung Research America / Silicon Valley
___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-devel


Re: [FFmpeg-devel] [PATCH] ffserver: Check allocations (likely not all)

2015-06-06 Thread Reynaldo H. Verdejo Pinochet
Hi

On 06/06/2015 10:43 AM, Michael Niedermayer wrote:
 Signed-off-by: Michael Niedermayer michae...@gmx.at
 ---
  ffserver.c |   20 
  1 file changed, 20 insertions(+)
 
 [..]

Looks good. Thanks!

Bests,


-- 
Reynaldo H. Verdejo Pinochet
Open Source Group
Samsung Research America / Silicon Valley
___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-devel


Re: [FFmpeg-devel] ffserver jpg patch

2015-05-06 Thread Reynaldo H. Verdejo Pinochet
Patch looks OK at a first glance. Any chance you can attach
the relevant feed and stream sections of the ffserver.conf
file you used in your tests? Also, it would be great if you
can use git format-patch with your email/name so we can preserve
autorship information on the commit.

Bests,

-- 
Reynaldo H. Verdejo Pinochet
Open Source Group
Samsung Research America / Silicon Valley
___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-devel


Re: [FFmpeg-devel] [ANNOUNCE] Outreachy (former OPW) application deadline

2015-04-05 Thread Reynaldo H. Verdejo Pinochet


On 04/05/2015 01:46 PM, Reynaldo H. Verdejo Pinochet wrote:
 Hi everyone
 
 OPW/Outreachy internships for this round are starting
 in May and we are about to hit the deadline for applications
 set for Tuesday next week.
 [..]

Deadline for applications has just been extended to April 10.

Bests,

-- 
Reynaldo H. Verdejo Pinochet
Open Source Group
Samsung Research America / Silicon Valley
___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-devel


[FFmpeg-devel] [ANNOUNCE] Outreachy (former OPW) application deadline

2015-04-05 Thread Reynaldo H. Verdejo Pinochet
Hi everyone

OPW/Outreachy internships for this round are starting
in May and we are about to hit the deadline for applications
set for Tuesday next week.

If you are interested on applying, please take a look at the
main page for the program and the list of participating
organizations here:

https://www.gnome.org/outreachy/
https://wiki.gnome.org/Outreachy/2015/MayAugust#Participating_Organizations

We are also maintaining a list of projects you might want to
consider applying to as well as general information for the
applicants here:

https://trac.ffmpeg.org/wiki/SponsoringPrograms/Outreachy/2015-05

If you have any questions regarding the program please get
in touch with us at o...@ffmpeg.org

By all means, please consider forwarding this information among
your circles.

Bests,

-- 
Reynaldo H. Verdejo Pinochet
Open Source Group
Samsung Research America / Silicon Valley
___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-devel


Re: [FFmpeg-devel] [PATCH] ffserver: Use av_malloc_array()

2015-01-09 Thread Reynaldo H. Verdejo Pinochet
Loos good. Please push.

On 01/06/2015 02:13 PM, Michael Niedermayer wrote:
 Signed-off-by: Michael Niedermayer michae...@gmx.at
 ---
  ffserver.c |6 ++
  1 file changed, 2 insertions(+), 4 deletions(-)
 
 diff --git a/ffserver.c b/ffserver.c
 index c4cf390..19d0b25 100644
 --- a/ffserver.c
 +++ b/ffserver.c
 @@ -2810,11 +2810,9 @@ static int prepare_sdp_description(FFServerStream 
 *stream, uint8_t **pbuffer,
  snprintf(avc-filename, 1024, rtp://0.0.0.0);
  }
  
 -if (avc-nb_streams = INT_MAX/sizeof(*avc-streams) ||
 -!(avc-streams = av_malloc(avc-nb_streams * sizeof(*avc-streams
 +if (!(avc-streams = av_malloc_array(avc-nb_streams, 
 sizeof(*avc-streams
  goto sdp_done;
 -if (avc-nb_streams = INT_MAX/sizeof(*avs) ||
 -!(avs = av_malloc(avc-nb_streams * sizeof(*avs
 +if (!(avs = av_malloc_array(avc-nb_streams, sizeof(*avs
  goto sdp_done;
  
  for(i = 0; i  stream-nb_streams; i++) {
 

-- 
Reynaldo H. Verdejo Pinochet
Open Source Group
Samsung Research America / Silicon Valley
___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-devel


Re: [FFmpeg-devel] [PATCH] ffserver: use avcodec_copy_context to copy context

2014-12-02 Thread Reynaldo H. Verdejo Pinochet
Should be OK. Thanks.

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


Re: [FFmpeg-devel] [PATCH 1/3] ffserver_config: remove useless defaults

2014-12-02 Thread Reynaldo H. Verdejo Pinochet
Looks OK. Feel free to push.

Bests,

-- 
Reynaldo H. Verdejo Pinochet
Open Source Group
Samsung Research America / Silicon Valley
___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-devel


Re: [FFmpeg-devel] [PATCH 2/3] ffserver_config: set defaults basing on absence of set value

2014-12-02 Thread Reynaldo H. Verdejo Pinochet
Looks OK too.

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


Re: [FFmpeg-devel] [PATCH 3/3] ffserver_config: print warning when using default value

2014-12-02 Thread Reynaldo H. Verdejo Pinochet
OK to push too. Thanks a lot.

Bests,

-- 
Reynaldo H. Verdejo Pinochet
Open Source Group
Samsung Research America / Silicon Valley
___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-devel


Re: [FFmpeg-devel] [PATCH 2/2] ffserver: dont leak pb_buffer

2014-11-26 Thread Reynaldo H. Verdejo Pinochet
Feel free to push please.

Thanks a lot

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


Re: [FFmpeg-devel] [PATCH 1/2] ffserver: dont leak child arguments

2014-11-26 Thread Reynaldo H. Verdejo Pinochet
Hi

On 11/20/2014 08:51 PM, Lukasz Marek wrote:
 [..]
   }
 diff --git a/ffserver_config.c b/ffserver_config.c
 index 02c8431..a235142 100644
 --- a/ffserver_config.c
 +++ b/ffserver_config.c
 @@ -31,6 +31,8 @@
   #include cmdutils.h
   #include ffserver_config.h

 +#define MAX_CHILD_ARGS 64
 +
   static int ffserver_save_avoption(AVCodecContext *ctx, const char
 *opt, const char *arg,
 AVDictionary **dict, int type,
 FFServerConfig *config, int line_num);
   static void vreport_config_error(const char *filename, int line_num,
 int log_level,
 @@ -603,7 +605,7 @@ static int
 ffserver_parse_config_feed(FFServerConfig *config, const char *cmd, c
   if (!av_strcasecmp(cmd, Launch)) {
   int i;

 -feed-child_argv = av_mallocz(64 * sizeof(char *));
 +feed-child_argv = av_mallocz_array(MAX_CHILD_ARGS,
 sizeof(char *));
   if (!feed-child_argv)
   return AVERROR(ENOMEM);
   for (i = 0; i  62; i++) {
 
 Right after submit I notice this hardcoded 62 so I changed locally to
 MAX_CHILD_ARGS - 2 :]

Cool. Feel free to push please.

Thanks a lot

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


Re: [FFmpeg-devel] [PATCH 08/11] ffserver: export recommented encoder configuration

2014-11-26 Thread Reynaldo H. Verdejo Pinochet
Hi Lukasz. Sorry for the delay.

Patch looks good. Feel free to push.

Bests,

-- 
Reynaldo H. Verdejo Pinochet
Open Source Group
Samsung Research America / Silicon Valley
___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-devel


Re: [FFmpeg-devel] [PATCH 03/11] ffserver_config: map ffserver options to AVOptions

2014-11-26 Thread Reynaldo H. Verdejo Pinochet
Hi

On 11/21/2014 09:16 PM, Lukasz Marek wrote:
 [...]
 @@ -497,6 +500,14 @@ static int ffserver_save_avoption(const char *opt, const 
 char *arg, int type, FF
  return 0;
  }
  
 +static int ffserver_save_avoption_int(const char *opt, int64_t arg,
 +  int type, FFServerConfig *config)
 +{
 +char buf[30];

char buf[20] should be plenty considering INT64_MAX. Feel free to push
after this minor fix unless someone else holds you.

Bests,

-- 
Reynaldo H. Verdejo Pinochet
Open Source Group
Samsung Research America / Silicon Valley
___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-devel


Re: [FFmpeg-devel] [PATCH 04/11] ffserver_config: remove ffserver_apply_stream_config function

2014-11-26 Thread Reynaldo H. Verdejo Pinochet
Hi. LGTM, feel free to push please.

-- 
Reynaldo H. Verdejo Pinochet
Open Source Group
Samsung Research America / Silicon Valley
___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-devel


Re: [FFmpeg-devel] [PATCH 06/11] [WIP][RFC]tools: add ffserver_config_test

2014-11-26 Thread Reynaldo H. Verdejo Pinochet
Hi Lukasz. Are you sending an updated patch for this one
or I missed it somehow?

-- 
Reynaldo H. Verdejo Pinochet
Open Source Group
Samsung Research America / Silicon Valley
___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-devel


Re: [FFmpeg-devel] [PATCH 06/11] [WIP][RFC]tools: add ffserver_config_test

2014-11-26 Thread Reynaldo H. Verdejo Pinochet
Hi

On 11/26/2014 07:35 PM, Lukasz Marek wrote:
 [..]
 maybe I should avoid commenting patches in other threads, but I removed

Yeah ;)

 this for now. I will repost it when it is finished.
 [..]

All good then. Please CC me when you do to make sure I don't
miss it.

Thanks a lot!

Bests,


-- 
Reynaldo H. Verdejo Pinochet
Open Source Group
Samsung Research America / Silicon Valley
___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-devel


Re: [FFmpeg-devel] [PATCH 03/11] ffserver_config: map ffserver options to AVOptions

2014-11-26 Thread Reynaldo H. Verdejo Pinochet


On 11/26/2014 07:52 PM, Lukasz Marek wrote:
 [..]
 
 In fact 20 is too small. INT64_MIN has 19 digits, '-' sign and
 terminating 0. So 21 is a minimum. I put 22, the same as av_dict_set_int.

True, forgot about the sign. Go ahead after fixing please.

Thanks,


-- 
Reynaldo H. Verdejo Pinochet
Open Source Group
Samsung Research America / Silicon Valley
___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-devel


Re: [FFmpeg-devel] [PATCH 05/11] ffserver: allow skip setting defaults

2014-11-23 Thread Reynaldo H. Verdejo Pinochet
Hi

On 11/21/2014 09:13 PM, Lukasz Marek wrote:
 [...]
 @@ -1032,6 +1059,14 @@ static int ffserver_parse_config_stream(FFServerConfig 
 *config, const char *cmd,
  } else if (!av_strcasecmp(cmd, File) || !av_strcasecmp(cmd, 
 ReadOnlyFile)) {
  ffserver_get_arg(stream-feed_filename, 
 sizeof(stream-feed_filename),
  p);
 +} else if (!av_strcasecmp(cmd, UseDefaults)) {
 +if (config-stream_use_defaults  1)
 +ERROR(Multiple UseDefaults/NoDefaults entries.\n);
 +config-stream_use_defaults = 3;
 +} else if (!av_strcasecmp(cmd, NoDefaults)) {
 +if (config-stream_use_defaults  1)
 +ERROR(Multiple UseDefaults/NoDefaults entries.\n);
 +config-stream_use_defaults = 2;
  } else {
  ERROR(Invalid entry '%s' inside Stream/Stream\n, cmd);
  }

I think these should be WARNING()s. Patch looks good otherwise.

Bests,

-- 
Reynaldo H. Verdejo Pinochet
Open Source Group
Samsung Research America / Silicon Valley
___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-devel


Re: [FFmpeg-devel] [PATCH 03/11] ffserver_config: map ffserver options to AVOptions

2014-11-21 Thread Reynaldo H. Verdejo Pinochet
Hi

On 11/20/2014 10:14 PM, Lukasz Marek wrote:
 On 18.11.2014 21:35, Reynaldo H. Verdejo Pinochet wrote:
 [...]
 Also, please make an effort
 to break lines at 80 chars as long as it doesn't make the
 code harder to read. This seems particularly possible on the
 function declarations.
 
 regarding this part, I set my editor to notice 90 chars and I try to
 respect that, but with some reasonable margin. TBH, 80 chars is
 prehistoric, probably from the era of crt's with text mode.
 I don't remember official ffmpeg's rules about that, but common, its
 21th century...

https://www.ffmpeg.org/developer.html#toc-Code-formatting-conventions

Please try to when possible. It's not a requirement but a sane
suggestion many avid by.

Bests,

-- 
Reynaldo H. Verdejo Pinochet
Open Source Group
Samsung Research America / Silicon Valley
___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-devel


Re: [FFmpeg-devel] [PATCH 03/11] ffserver_config: map ffserver options to AVOptions

2014-11-21 Thread Reynaldo H. Verdejo Pinochet


On 11/21/2014 07:17 PM, Reynaldo H. Verdejo Pinochet wrote:
 [..]
 suggestion many avid by.

s/avid by/follow/g
___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-devel


Re: [FFmpeg-devel] [PATCH 03/11] ffserver_config: map ffserver options to AVOptions

2014-11-18 Thread Reynaldo H. Verdejo Pinochet
Hi

On 11/16/2014 10:46 PM, Lukasz Marek wrote:
 Signed-off-by: Lukasz Marek lukasz.m.lu...@gmail.com
 [..]
 @@ -965,43 +881,38 @@ static int ffserver_parse_config_stream(FFServerConfig 
 *config, const char *cmd,
  ret = av_parse_video_size(w, h, arg);
  if (ret  0)
  ERROR(Invalid video size '%s'\n, arg);
 -else if ((w % 2) || (h % 2))

See bellow

 -WARNING(Image size is not a multiple of 2\n);
 -if (av_dict_set_int(config-video_conf, VideoSizeWidth, w, 0)  0 
 ||
 -av_dict_set_int(config-video_conf, VideoSizeHeight, h, 0)  
 0)
 -goto nomem;
 -} else if (!av_strcasecmp(cmd, VideoFrameRate)) {
 -AVRational frame_rate;
 -ffserver_get_arg(arg, sizeof(arg), p);
 -if (av_parse_video_rate(frame_rate, arg)  0) {
 -ERROR(Incorrect frame rate: %s\n, arg);
 -} else {
 -if (av_dict_set_int(config-video_conf, VideoFrameRateNum, 
 frame_rate.num, 0)  0 ||
 -av_dict_set_int(config-video_conf, VideoFrameRateDen, 
 frame_rate.den, 0)  0)
 +else {
 +if ((w % 2) || (h % 2))

Drop the redundant () across %. Also, please make an effort
to break lines at 80 chars as long as it doesn't make the
code harder to read. This seems particularly possible on the
function declarations.

Other than these two minor nits, the patch seems OK
to push.

Thanks a lot.

-- 
Reynaldo H. Verdejo Pinochet
Open Source Group
Samsung Research America / Silicon Valley
___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-devel


Re: [FFmpeg-devel] [PATCH 04/11] ffserver_config: remove ffserver_apply_stream_config function

2014-11-18 Thread Reynaldo H. Verdejo Pinochet
Hi Lukasz

On 11/16/2014 10:46 PM, Lukasz Marek wrote:
 [..]
 @@ -174,13 +174,20 @@ void ffserver_parse_acl_row(FFServerStream *stream, 
 FFServerStream* feed,
  }
  
  /* add a codec and set the default parameters */
 -static void add_codec(FFServerStream *stream, AVCodecContext *av)
 +static void add_codec(FFServerStream *stream, AVCodecContext *av, 
 FFServerConfig *config)
  {
  AVStream *st;
 +AVDictionary **opts;
  
  if(stream-nb_streams = FF_ARRAY_ELEMS(stream-streams))
  return;
  
 +opts = av-codec_type == AVMEDIA_TYPE_AUDIO ? config-audio_opts : 
 config-video_opts;
 +av_opt_set_dict2(av-priv_data, opts, AV_OPT_SEARCH_CHILDREN);
 +av_opt_set_dict2(av, opts, AV_OPT_SEARCH_CHILDREN);
 +if (av_dict_count(*opts))
 +av_log(NULL, AV_LOG_ERROR, Something went wrong, %d options not 
 set!!!\n, av_dict_count(*opts));
 +

Is this really an error? OK to push if so. Otherwise demote to
warning and push the updated patch. Usual comments about your
line lengths apply too but are not blockers.

As a general comment, I would avoid the grammatical !!!s and
such to denote severity. We have the log categories for that.
This is also just a tip, not something you need to change.

Bests,

-- 
Reynaldo H. Verdejo Pinochet
Open Source Group
Samsung Research America / Silicon Valley
___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-devel


Re: [FFmpeg-devel] [PATCH 05/11] ffserver: allow skip setting defaults

2014-11-18 Thread Reynaldo H. Verdejo Pinochet
Hi

On 11/16/2014 10:46 PM, Lukasz Marek wrote:
[..]
 diff --git a/doc/ffserver.texi b/doc/ffserver.texi
 index b7c5b6a..d3ff13e 100644
 --- a/doc/ffserver.texi
 +++ b/doc/ffserver.texi
 @@ -408,6 +408,11 @@ ignored, and the log is written to standard output.
  Set no-daemon mode. This option is currently ignored since now
  @command{ffserver} will always work in no-daemon mode, and is
  deprecated.
 +
 +@item UseDefaults
 +@item NoDefaults
 +Control whether default codec options are used for the all streams or not.
 +Each stream may overwrite this setting for its own. Default is 
 @var{UseDefaults}.
 [...]

I think I commented about this before but having yesvar  novar
options seems redundant. Having var = yes or no if absent (or the
other way around depending on the intended default) seems less
cumbersome and should simplify the code a bit too, avoiding checking
for the two and imposing a precedence, which is not always
documented. What do you think? This happens twice on this patch
IIRC.

Otherwise seems OK to push.

Bests,

-- 
Reynaldo H. Verdejo Pinochet
Open Source Group
Samsung Research America / Silicon Valley
___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-devel


Re: [FFmpeg-devel] [PATCH 06/11] [WIP][RFC]tools: add ffserver_config_test

2014-11-18 Thread Reynaldo H. Verdejo Pinochet
Hi. Overall this looks good, thanks. I would move the test to
tests/ though and integrate it with the build/test system as,
say, the way tiny_ssim is:

grep -R tiny_ssim *
Makefile:TESTTOOLS   = audiogen videogen rotozoom tiny_psnr tiny_ssim base64
tests/Makefile:FATE_UTILS = base64 tiny_psnr tiny_ssim
tests/tiny_ssim.c: * tiny_ssim.c
tests/tiny_ssim.c:printf(tiny_ssim file1.yuv file2.yuv
widthxheight [seek]\n);

Small nit bellow while I'm at this:


On 11/16/2014 10:46 PM, Lukasz Marek wrote:
 [..]
 @@ -1205,3 +1205,43 @@ int ffserver_parse_ffconfig(const char *filename, 
 FFServerConfig *config)
  
  #undef ERROR
  #undef WARNING
 +
 +static void ffserver_free_server_stream(FFServerStream *stream)
 +{
 +int i;
 +
 +av_dict_free(stream-in_opts);
 +av_dict_free(stream-metadata);
 +while(stream-acl) {

You seem to use an space before ( for if/while/for. Add it here.

Bests,

-- 
Reynaldo H. Verdejo Pinochet
Open Source Group
Samsung Research America / Silicon Valley
___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-devel


Re: [FFmpeg-devel] [PATCH 06/11] [WIP][RFC]tools: add ffserver_config_test

2014-11-18 Thread Reynaldo H. Verdejo Pinochet


On 11/16/2014 11:00 PM, Lukasz Marek wrote:
 [..]
 Second thing, I don't know how to integrate this test into build system.
 I put it into tool, but it requires ffserver_config.o and cmdutils.o
 For now it have to be build with make  make tools/ffserver_config_test
 as these two *.o are not treated as  dependencies. I don't know where to
 place it in general, so I could use some help.
 

For build/test system integration, see my previous answer on
this same thread.

Bests,

-- 
Reynaldo H. Verdejo Pinochet
Open Source Group
Samsung Research America / Silicon Valley
___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-devel


Re: [FFmpeg-devel] [PATCH 08/11] ffserver: export recommented encoder configuration

2014-11-18 Thread Reynaldo H. Verdejo Pinochet
Hi

On 11/16/2014 10:46 PM, Lukasz Marek wrote:
 [..]
 @@ -3355,6 +3354,9 @@ static int add_av_stream(FFServerStream *feed, AVStream 
 *st)
  fst = add_av_stream1(feed, av, 0);
  if (!fst)
  return -1;
 +if (av_stream_get_recommended_encoder_configuration(st))
 +av_stream_set_recommended_encoder_configuration(fst,
 +av_strdup(av_stream_get_recommended_encoder_configuration(st)));

Is the return of av_strdup here been freed somewhere?. Also
adding braces to ifs when the body is multilined wouldn't
hurt. Not a blocker of course.

Looks OK otherwise. Feel free to push after confirming ^

Bests,

-- 
Reynaldo H. Verdejo Pinochet
Open Source Group
Samsung Research America / Silicon Valley
___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-devel


Re: [FFmpeg-devel] [PATCH 05/11] ffserver: allow skip setting defaults

2014-11-18 Thread Reynaldo H. Verdejo Pinochet
Hi

On 11/18/2014 06:54 PM, Nicolas George wrote:
 L'octidi 28 brumaire, an CCXXIII, Reynaldo H. Verdejo Pinochet a
 écrit :
 I think I commented about this before but having yesvar  novar 
 options seems redundant. Having var = yes or no if absent (or
 the other way around depending on the intended default) seems
 less cumbersome and should simplify the code a bit too, avoiding
 checking
 
 I think exactly the opposite. People who build reliable
 configurations want to avoid relying on default values as much as
 possible, because default values can change without notice.
 Therefore, they need to be able to specify explicitly any
 behaviour, even if it is currently the default.
 
 for the two and imposing a precedence, which is not always 
 documented.
 
 I think we can implicitly document that the behaviour for
 contradictory options is nasal demons.

Good point I guess. OK all the same as long as we keep
it consistent across config files. Phrased as a question
to the author for this very reason.

I do think undefined behavior should be avoided if possible
without too much hassle, so if we go with the former I would
appreciate doc entries specifying the options precedence. Brownie
points+ if an odd combination fires a warning().

Bests,

-- 
Reynaldo H. Verdejo Pinochet
Open Source Group
Samsung Research America / Silicon Valley
___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-devel


Re: [FFmpeg-devel] [PATCH 01/11] ffserver_config: cosmetic: simplify functions calls.

2014-11-17 Thread Reynaldo H. Verdejo Pinochet
Looks Good. Feel free to push.

Bests,

-- 
Reynaldo H. Verdejo Pinochet
Open Source Group
Samsung Research America / Silicon Valley
___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-devel


Re: [FFmpeg-devel] [PATCH 02/11] ffserver_config: cosmetic: move line_num into FFServerConfig

2014-11-17 Thread Reynaldo H. Verdejo Pinochet
OK to push too.

-- 
Reynaldo H. Verdejo Pinochet
Open Source Group
Samsung Research America / Silicon Valley
___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-devel


Re: [FFmpeg-devel] [PATCH 03/11] ffserver_config: map ffserver options to AVOptions

2014-11-17 Thread Reynaldo H. Verdejo Pinochet

Hi

On 11/16/2014 11:03 PM, Lukasz Marek wrote:
 On 17.11.2014 02:46, Lukasz Marek wrote:
 Signed-off-by: Lukasz Marek lukasz.m.lu...@gmail.com
 ---
   ffserver_config.c | 237
 --
   ffserver_config.h |   2 -
   2 files changed, 69 insertions(+), 170 deletions(-)
 
 @Reynaldo, you may check the test I submitted, and the comments, you may
 then have just high level review, not bother if mapping between options
 is ok

Will do. Thanks for the hint. I should be able to take a look
at this and the rest of the changes tomorrow.

Bests,

-- 
Reynaldo H. Verdejo Pinochet
Open Source Group
Samsung Research America / Silicon Valley
___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-devel


Re: [FFmpeg-devel] [PATCH 6/9] ffserver_config: handle codec private options

2014-11-16 Thread Reynaldo H. Verdejo Pinochet

Hi Lukasz. Sry for the delay at answering, been traveling
the whole week.

Patch looks OK, feel free to push.

Bests,

--
Reynaldo H. Verdejo Pinochet
Open Source Group
Samsung Research America / Silicon Valley
___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-devel


Re: [FFmpeg-devel] [PATCH] ffserver_config: do not store preset name

2014-11-16 Thread Reynaldo H. Verdejo Pinochet

Looks. OK. Feel free to push after some testing. Can't
try it out right now but seems harmless.

Bests,

--
Reynaldo H. Verdejo Pinochet
Open Source Group
Samsung Research America / Silicon Valley
___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-devel


Re: [FFmpeg-devel] [PATCH] ffserver_config: fix possible crash

2014-11-16 Thread Reynaldo H. Verdejo Pinochet

OK to push. Thanks.

--
Reynaldo H. Verdejo Pinochet
Open Source Group
Samsung Research America / Silicon Valley
___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-devel


Re: [FFmpeg-devel] OPW Qualification Task: Enable daemon mode for FFserver

2014-11-11 Thread Reynaldo H. Verdejo Pinochet

Hello

On 11/11/2014 04:16 PM, Binathi Bingi wrote:

[..]
Updated patch.
Please let me know if there are any other changes needed.
[..]


Hello Binathi. Thanks for your continuous attention to
this matter. Appreciated.

Your patch does no longer apply cleanly, you need to rebase
it on top of a recent checkout of master. For future reference,
you need to do this every time you send a patch over.

Bests,

--
Reynaldo H. Verdejo Pinochet
Open Source Group
Samsung Research America / Silicon Valley
___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-devel


Re: [FFmpeg-devel] [PATCH 6/9] ffserver_config: handle codec private options

2014-11-11 Thread Reynaldo H. Verdejo Pinochet

Hi Lukasz

On 11/11/2014 04:31 AM, Lukasz Marek wrote:

This commit allows to set codec's private option.
As side effect this commit also improves preset support.


s/this commit also/, it/


[..]
+static int ffserver_save_avoption(AVCodecContext *ctx, const char *opt, const 
char *arg,
+  AVDictionary **dict, int type, 
FFServerConfig *config, int line_num);
+static void vreport_config_error(const char *filename, int line_num, int 
log_level, int *errors, const char *fmt, va_list vl);
+static void report_config_error(const char *filename, int line_num, int 
log_level, int *errors, const char *fmt, ...);
+


These random length line breaks are getting a bit messy, I don't
mind if you don't wana break at 80 but please be consistent.


[..]
@@ -293,16 +295,31 @@ static int ffserver_opt_preset(const char *arg,
  ret = AVERROR(EINVAL);
  break;
  }
-if (audio_id  !strcmp(tmp, acodec)) {
-*audio_id = opt_codec(tmp2, AVMEDIA_TYPE_AUDIO);
-} else if (video_id  !strcmp(tmp, vcodec)){
-*video_id = opt_codec(tmp2, AVMEDIA_TYPE_VIDEO);
-} else if(!strcmp(tmp, scodec)) {
-/* opt_subtitle_codec(tmp2); */
-} else if (avctx  (ret = ffserver_opt_default(tmp, tmp2, avctx, type)) 
 0) {
-fprintf(stderr, %s: Invalid option or argument: '%s', parsed as 
-'%s' = '%s'\n, filename, line, tmp, tmp2);
-break;
+if ((!strcmp(tmp, acodec)  avctx-codec_type == 
AVMEDIA_TYPE_AUDIO) ||
+ !strcmp(tmp, vcodec)  avctx-codec_type == AVMEDIA_TYPE_VIDEO)
+{
+if (ffserver_set_codec(avctx, tmp2, config, line_num)  0)
+break;


Factor in previous if() condition?


+} else if (!strcmp(tmp, scodec)) {
+/* nothing to do */


Not sure why are we leaving this one there? Proly drop and add
an informative comment if needed.


+} else {
+int type;
+AVDictionary **opts;


Add blank line please (Can you do it for other similar occurrences?)


[..]
@@ -406,27 +424,67 @@ static int ffserver_set_float_param(float *dest, const 
char *value, float factor
  return AVERROR(EINVAL);
  }

-static int ffserver_save_avoption(const char *opt, const char *arg, 
AVDictionary **dict,
+static int ffserver_save_avoption(AVCodecContext *ctx, const char *opt, const 
char *arg, AVDictionary **dict,
int type, FFServerConfig *config, int 
line_num)
  {
+static int hinted = 0;
  int ret = 0;
  AVDictionaryEntry *e;
-const AVOption *o = av_opt_find(config-dummy_ctx, opt, NULL, type | 
AV_OPT_FLAG_ENCODING_PARAM, AV_OPT_SEARCH_CHILDREN);
+const AVOption *o = NULL;
+const char *option = NULL;
+const char *codec_name = NULL;
+
+if (strchr(opt, ':')) {
+//explicit private option
+char buff[1024];


See above (there are others though)


+snprintf(buff, sizeof(buff), %s, opt);


Pointless sizeof but it's OK.


+codec_name = buff;
+option = strchr(buff, ':');
+buff[option - buff] = '\0';


Can't strchr() return NULL and wreak havoc here?


+option++;
+if ((ret = ffserver_set_codec(ctx, codec_name, config, line_num))  0)
+return ret;
+if (!ctx-codec || !ctx-priv_data)
+return -1;
+} else {
+option = opt;
+}
+
+o = av_opt_find(ctx, option, NULL, type | AV_OPT_FLAG_ENCODING_PARAM, 
AV_OPT_SEARCH_CHILDREN);
  if (!o) {
  report_config_error(config-filename, line_num, AV_LOG_ERROR,
-config-errors, Option not found: %s\n, opt);
-} else if ((ret = av_opt_set(config-dummy_ctx, opt, arg, 
AV_OPT_SEARCH_CHILDREN))  0) {
+config-errors, Option not found: %s\n, opt);
+if (!hinted  ctx-codec_id == AV_CODEC_ID_NONE) {
+enum AVCodecID id;
+hinted = 1;
+switch(ctx-codec_type) {
+case AVMEDIA_TYPE_AUDIO:
+id = config-guessed_audio_codec_id != AV_CODEC_ID_NONE ? 
config-guessed_audio_codec_id : AV_CODEC_ID_AAC;
+break;
+case AVMEDIA_TYPE_VIDEO:
+id = config-guessed_video_codec_id != AV_CODEC_ID_NONE ? 
config-guessed_video_codec_id : AV_CODEC_ID_H264;
+break;
+default:
+break;
+}
+report_config_error(config-filename, line_num, AV_LOG_ERROR, NULL,
+If '%s' is codec private option, then prefix it 
with codec name, 


is a

Rest looks OK at a first glance. Thanks a lot

Bests,


--
Reynaldo H. Verdejo Pinochet
Open Source Group
Samsung Research America / Silicon Valley
___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-devel


Re: [FFmpeg-devel] [PATCH] ffserver_config: report not closed last tag

2014-11-08 Thread Reynaldo H. Verdejo Pinochet
Looks good. Thanks. Feel free to push.

-- 
Reynaldo H. Verdejo Pinochet
Open Source Group
Samsung Research America / Silicon Valley
___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-devel


Re: [FFmpeg-devel] OPW Qualification Task: Enable daemon mode for FFserver

2014-11-03 Thread Reynaldo H. Verdejo Pinochet
Hi

On 11/03/2014 04:09 PM, Binathi Bingi wrote:
 Hello,
 
 Inside the child process, I closed the file descriptor and then reopened
 and redirected them using dup2() and later closed the opened file. I am not
 sure if I understood and used the functionality of dup2() in the right
 sense.
 

Looks about right but see bellow.

 [..]
 @@ -3736,10 +3737,42 @@ int main(int argc, char **argv)
  build_feed_streams();
  
  compute_bandwidth();
 -
 +

Remove trailing withe space

 +if (config.ffserver_daemon) {

What follows needs to be indented

 +pid_t ffserver_id = 0; 
 +pid_t sid = 0;
 +
 +ffserver_id = fork(); 
 +
 +if (ffserver_id  0) {
 +ret = AVERROR(errno);
 +av_log(NULL, AV_LOG_ERROR, Impossible to start in daemon mode: 
 %s\n, av_err2str(ret)); 
 +exit(1);

Fix wrong indentation

 +}
 +
 +if (ffserver_id  0) { 
 +exit(0);
 +}

Drop the braces from single statement ifs blocks like this one.

 +
 +sid = setsid(); 
 +if (sid  0) {
 +exit(1); 
 +}

Same as above

 +
 +if (strcmp(config.logfilename, -) != 0) {
 +close(0);

Drop the != 0. Anything but 0 will evaluate to true anyway. You do this
elsewhere on your own code. Be consistent.

 +
 +fd = open(/dev/null, O_RDWR);
 +dup2(fd,0);
 +dup2(fd,1);
 +dup2(fd,2);

You sure you wana dup2() stdin, stdout and stderr on the above
condition? Please double check.

 +close(fd);

Above block needs to be re-indented. Also, check for failures in
open and dup2() and react accordingly. I think Nicolas mentioned
this already.

 +
 +}
 +}
  /* signal init */
  signal(SIGPIPE, SIG_IGN);
 -
 +

Again, drop the trailing white space you introduced here and on
multiple lines in this same patch.

It's getting there. Congrats ;)

Bests,

-- 
Reynaldo H. Verdejo Pinochet
Open Source Group
Samsung Research America / Silicon Valley
___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-devel


Re: [FFmpeg-devel] [PATCH] ffserver_config: improve AVOption handing

2014-11-02 Thread Reynaldo H. Verdejo Pinochet
Hi

On 11/01/2014 03:33 PM, Lukasz Marek wrote:
 [..] 
 @@ -517,7 +538,6 @@ static int ffserver_parse_config_feed(FFServerConfig 
 *config, const char *cmd, c
  static int ffserver_apply_stream_config(AVCodecContext *enc, const 
 AVDictionary *conf, AVDictionary **opts)
  {
  AVDictionaryEntry *e;
 -int ret = 0;
  
  /* Return values from ffserver_set_*_param are ignored.
 Values are initially parsed and checked before inserting to 
 AVDictionary. */
 @@ -589,13 +609,8 @@ static int ffserver_apply_stream_config(AVCodecContext 
 *enc, const AVDictionary
  ffserver_set_int_param(enc-bit_rate, e-value, 0, INT_MIN, 
 INT_MAX, NULL, 0, NULL);
  
  av_opt_set_dict2(enc, opts, AV_OPT_SEARCH_CHILDREN);
 -e = NULL;
 -while (e = av_dict_get(*opts, , e, AV_DICT_IGNORE_SUFFIX)) {
 -av_log(NULL, AV_LOG_ERROR, Provided AVOption '%s' doesn't match any 
 existing option.\n, e-key);
 -ret = AVERROR(EINVAL);
 -}
  
 -return ret;
 +return 0;
  }

If you are always returning 0 then this func should probably be
declared static void instead?

 [..]
 diff --git a/ffserver_config.h b/ffserver_config.h
 index f29f07f..c684fb5 100644
 --- a/ffserver_config.h
 +++ b/ffserver_config.h
 @@ -113,6 +113,7 @@ typedef struct FFServerConfig {
  AVDictionary *video_conf; /* Values stored in video 
 AVCodecContext.fields */
  AVDictionary *audio_opts; /* AVOptions for audio encoder */
  AVDictionary *audio_conf; /* Values stored in audio 
 AVCodecContext.fields */
 +AVCodecContext *dummy_ctx;/* Used internally to test AVOptions, not 
 to be used anywere else */

s/anywere/anywhere/g

nit: . Not to be 

Looks OK, feel free to push after fixing ^

Bests,

-- 
Reynaldo H. Verdejo Pinochet
Open Source Group
Samsung Research America / Silicon Valley
___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-devel


Re: [FFmpeg-devel] FFserver bug?

2014-11-02 Thread Reynaldo H. Verdejo Pinochet
Hi. I'm afraid I don't understand what the problem is. Can
someone elaborate?

Bests,

-- 
Reynaldo H. Verdejo Pinochet
Open Source Group
Samsung Research America / Silicon Valley
___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-devel


Re: [FFmpeg-devel] [PATCH 1/4] ffserver_config: drop requirement video size being multiple of 16

2014-11-01 Thread Reynaldo H. Verdejo Pinochet
Hi

On 10/31/2014 11:00 PM, Lukasz Marek wrote:
 [..]
 diff --git a/ffserver_config.c b/ffserver_config.c
 index d589ff2..f11db03 100644
 --- a/ffserver_config.c
 +++ b/ffserver_config.c
 @@ -819,8 +819,6 @@ static int ffserver_parse_config_stream(FFServerConfig 
 *config, const char *cmd,
  ret = av_parse_video_size(w, h, arg);
  if (ret  0)
  ERROR(Invalid video size '%s'\n, arg);
 -else if ((w % 16) || (h % 16))
 -ERROR(Image size must be a multiple of 16\n);
 [..]

OK if always safe. Otherwise demote to WARNING()

Feel free to push otherwise.

Bests,

-- 
Reynaldo H. Verdejo Pinochet
Open Source Group
Samsung Research America / Silicon Valley
___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-devel


Re: [FFmpeg-devel] [PATCH 3/4] ffserver_config: improve error handling

2014-11-01 Thread Reynaldo H. Verdejo Pinochet
Hi

On 10/31/2014 11:00 PM, Lukasz Marek wrote:
 [..]
 @@ -356,9 +356,7 @@ static int ffserver_parse_config_global(FFServerConfig 
 *config, const char *cmd,
  if (!av_strcasecmp(cmd, Port))
  WARNING(Port option is deprecated, use HTTPPort instead\n);
  ffserver_get_arg(arg, sizeof(arg), p);
 -val = atoi(arg);
 -if (val  1 || val  65536)
 -ERROR(Invalid port: %s\n, arg);
 +ffserver_set_int_param(val, arg, 0, 1, 65535, config, line_num, 
 Invalid port: %s\n, arg);
  if (val  1024)
  WARNING(Trying to use IETF assigned system port: %d\n, val);
  config-http_addr.sin_port = htons(val);
 @@ -367,37 +365,38 @@ static int ffserver_parse_config_global(FFServerConfig 
 *config, const char *cmd,
  WARNING(BindAddress option is deprecated, use HTTPBindAddress 
 instead\n);
  ffserver_get_arg(arg, sizeof(arg), p);
  if (resolve_host(config-http_addr.sin_addr, arg) != 0)
 -ERROR(%s:%d: Invalid host/IP address: %s\n, arg);
 +ERROR(Invalid host/IP address: %s\n, arg);
  } else if (!av_strcasecmp(cmd, NoDaemon)) {
  WARNING(NoDaemon option has no effect, you should remove it\n);
  } else if (!av_strcasecmp(cmd, RTSPPort)) {
  ffserver_get_arg(arg, sizeof(arg), p);
 -val = atoi(arg);
 -if (val  1 || val  65536)
 -ERROR(%s:%d: Invalid port: %s\n, arg);
 -config-rtsp_addr.sin_port = htons(atoi(arg));
 +ffserver_set_int_param(val, arg, 0, 1, 65535, config, line_num, 
 Invalid port: %s\n, arg);
 +config-rtsp_addr.sin_port = htons(val);
  } else if (!av_strcasecmp(cmd, RTSPBindAddress)) {
  ffserver_get_arg(arg, sizeof(arg), p);
  if (resolve_host(config-rtsp_addr.sin_addr, arg) != 0)
  ERROR(Invalid host/IP address: %s\n, arg);
  } else if (!av_strcasecmp(cmd, MaxHTTPConnections)) {
  ffserver_get_arg(arg, sizeof(arg), p);
 -val = atoi(arg);
 -if (val  1 || val  65536)
 -ERROR(Invalid MaxHTTPConnections: %s\n, arg);
 +ffserver_set_int_param(val, arg, 0, 1, 65535, config, line_num, 
 Invalid MaxHTTPConnections: %s\n, arg);

I don't think we should be capping MaxHTTPConnections at 65535.
If there's a reason then FFServerConfig.nb_max_http_connections
type needs to be revised too?

  config-nb_max_http_connections = val;
 +if (config-nb_max_connections  config-nb_max_http_connections)
 +ERROR(Inconsistent configuration: MaxClients(%d)  
 MaxHTTPConnections(%d)\n,
 +  config-nb_max_connections, 
 config-nb_max_http_connections);
  } else if (!av_strcasecmp(cmd, MaxClients)) {
  ffserver_get_arg(arg, sizeof(arg), p);
 -val = atoi(arg);
 -if (val  1 || val  config-nb_max_http_connections)
 -ERROR(Invalid MaxClients: %s\n, arg);
 -else
 -config-nb_max_connections = val;
 +ffserver_set_int_param(val, arg, 0, 1, 65535, config, line_num, 
 Invalid MaxClients: %s\n, arg);
 +config-nb_max_connections = val;
 +if (config-nb_max_connections  config-nb_max_http_connections)
 +ERROR(Inconsistent configuration: MaxClients(%d)  
 MaxHTTPConnections(%d)\n,
 +  config-nb_max_connections, 
 config-nb_max_http_connections);

Same as above

 [...]
 @@ -500,6 +499,9 @@ static int ffserver_parse_config_feed(FFServerConfig 
 *config, const char *cmd, c
  case 'G':
  fsize *= 1024 * 1024 * 1024;
  break;
 +default:
 +ERROR(Invalid file size: %s\n, arg);
 +break;
  }
  feed-feed_max_size = (int64_t)fsize;
  if (feed-feed_max_size  FFM_PACKET_SIZE*4)
 @@ -876,11 +878,15 @@ static int ffserver_parse_config_stream(FFServerConfig 
 *config, const char *cmd,
  stream-is_multicast = 1;
  stream-loop = 1; /* default is looping */
  } else if (!av_strcasecmp(cmd, MulticastPort)) {
 +int val;
  ffserver_get_arg(arg, sizeof(arg), p);
 -stream-multicast_port = atoi(arg);
 +ffserver_set_int_param(val, arg, 0, 1, 65535, config, line_num, 
 Invalid MulticastPort: %s\n, arg);
 +stream-multicast_port = val;
  } else if (!av_strcasecmp(cmd, MulticastTTL)) {
 +int val;

Maybe declare val once at the beginning
of ffserver_parse_config_stream()

Rest looks OK.
Bests,

-- 
Reynaldo H. Verdejo Pinochet
Open Source Group
Samsung Research America / Silicon Valley
___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-devel


Re: [FFmpeg-devel] [PATCH 4/4] ffserver_config: dont pass pointer to enum as pointer to int

2014-11-01 Thread Reynaldo H. Verdejo Pinochet
Looks OK. Feel free to push.

Bests,

-- 
Reynaldo H. Verdejo Pinochet
Open Source Group
Samsung Research America / Silicon Valley
___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-devel


Re: [FFmpeg-devel] [PATCH 3/4] ffserver_config: improve error handling

2014-11-01 Thread Reynaldo H. Verdejo Pinochet


On 11/01/2014 07:59 PM, Lukasz Marek wrote:
 [..]
 
 I decreased it by 1 automatically rather than for any reason. I didn't
 want to change logic where it was not needed, and it was not needed
 here. I guess you ask in general if there should be a limit (not just it
 is 65535 or 6). I don't know, but as I stated before, I don't want to
 change the limit, just int parsing routine. If you wish I can change
 back to 65536 or to INT_MAX, but I want it to be clear it is not my
 original intention. :)
 

Fair enough. We can work on those limits latter on.

 
 OK, will do that locally.
 

Thanks. Feel free to push afterward.

Bests,

-- 
Reynaldo H. Verdejo Pinochet
Open Source Group
Samsung Research America / Silicon Valley
___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-devel


Re: [FFmpeg-devel] [PATCH 2/4] ffserver_config: drop presets support

2014-11-01 Thread Reynaldo H. Verdejo Pinochet
Hi

On 11/01/2014 07:42 PM, Lukasz Marek wrote:
 [..]
 
 Patch 1 and 2 are just suggestion from previous reviews by Stefano.
 Regarding presents itself I have no pressure to remove it, but I agree
 with Stefano that it seems to be dead feature.
 

Got it. My take on these matters is usually that if the feature
works and does no harm, then keep it. Maybe there's someone relying
on this. I will try getting others to comment on and decide. For
the time been though I think there might be a missing and needed
change to the ffserver docs for this patch to be complete.

Bests,


-- 
Reynaldo H. Verdejo Pinochet
Open Source Group
Samsung Research America / Silicon Valley
___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-devel


Re: [FFmpeg-devel] OPW Qualification Task: Enable daemon mode for FFserver

2014-10-30 Thread Reynaldo H. Verdejo Pinochet
Hello

On 10/30/2014 10:50 AM, Nicolas George wrote:
 [..] Third, I do not think this exact version is correct. If you
 make the daemon mode the default, then NoDaemon must not be
 ignored, it must have its specified effect: turn daemon off; if you
 do not make the daemon mode the default, then there must be an
 option to turn it on.
 
 IMHO, the best is to have both Daemon and NoDaemon mode. [..]

I would prefer no-deamon mode been the default to not
break current behavior till deamon-mode has had a good
deal of production testing. I also think having a single
Daemonize yes/no toggle should be enough but I'm OK
either way in the context of this patch.

Binathi: As an added bonus, try adding an -s to your
commit command line so you get the  Signed-off-by:
line added, this is customary.

Bests,

-- 
Reynaldo H. Verdejo Pinochet
Open Source Group
Samsung Research America / Silicon Valley
___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-devel


Re: [FFmpeg-devel] [PATCH 4/4] ffserver_config: postpone codec context creation

2014-10-23 Thread Reynaldo H. Verdejo Pinochet
 = AVMEDIA_TYPE_VIDEO;
 -config-video_enc.codec_id = config-video_id;
 -add_codec(stream, config-video_enc);
 +AVCodecContext *video_enc = 
 avcodec_alloc_context3(avcodec_find_encoder(config-video_id));
 +if (config-video_preset 
 +ffserver_opt_preset(arg, video_enc, 
 AV_OPT_FLAG_VIDEO_PARAM|AV_OPT_FLAG_ENCODING_PARAM,
 +NULL, NULL)  0)
 +ERROR(Could not apply preset '%s'\n, arg);

I usually add braces for single statement ifs when the condition itself
has multiple lines. But I'm OK either way.

 [..]
 -
 +AVDictionary *video_opts; /* Contains AVOptions for video encoder */
 +AVDictionary *video_conf; /* Contains values stored in video 
 AVCodecContext.fields */
 +AVDictionary *audio_opts; /* Contains AVOptions for audio encoder */
 +AVDictionary *audio_conf; /* Contains values stored in audio 
 AVCodecContext.fields */

Would drop the repeated Contains.

Everything looks OK otherwise. Thanks a lot.

Bests,


-- 
Reynaldo H. Verdejo Pinochet
Open Source Group
Samsung Research America / Silicon Valley
___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-devel


Re: [FFmpeg-devel] [PATCH 1/4] ffserver: move configuration code to separate file

2014-10-22 Thread Reynaldo H. Verdejo Pinochet
Config parsing changeset LGTM. Feel free to push.

Bests,

-- 
Reynaldo H. Verdejo Pinochet
Open Source Group
Samsung Research America / Silicon Valley
___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-devel


Re: [FFmpeg-devel] [PATCH 2/4] ffserver_config: clean up variable initialization

2014-10-22 Thread Reynaldo H. Verdejo Pinochet


On 10/21/2014 07:10 AM, Stefano Sabatini wrote:
 [..]
 
 LGTM.

Agree.

Bests,

-- 
Reynaldo H. Verdejo Pinochet
Open Source Group
Samsung Research America / Silicon Valley
___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-devel


Re: [FFmpeg-devel] [PATCH 3/4] ffserver_conf: factorize parse function per config tag

2014-10-22 Thread Reynaldo H. Verdejo Pinochet
Feel free to push after removing the explicit/redundant
initialization of FFServerConfig config as Reimar suggested.

While you are at this though, can you remove braces on
single statement ifs? appreciated.

Thanks


-- 
Reynaldo H. Verdejo Pinochet
Open Source Group
Samsung Research America / Silicon Valley
___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-devel


Re: [FFmpeg-devel] [PATCH 4/4] ffserver_config: postpone codec context creation

2014-10-22 Thread Reynaldo H. Verdejo Pinochet
Hi

On 10/20/2014 06:57 PM, Lukasz Marek wrote:
 So far AVCodecContext was created without codec specified.
 This causes internal data to not be initialized to defaults.
 
 This commit postpone context creation until all information are gathered.

are/is

 
 Partially fixes #1275
 ---
  ffserver.c|   8 +-
  ffserver_config.c | 286 
 --
  ffserver_config.h |   9 +-
  3 files changed, 183 insertions(+), 120 deletions(-)
 
 diff --git a/ffserver.c b/ffserver.c
 index 22560ce..8c65d12 100644
 --- a/ffserver.c
 +++ b/ffserver.c
 @@ -212,8 +212,12 @@ static FFServerConfig config = {
  .warnings = 0,
  .audio_id = AV_CODEC_ID_NONE,
  .video_id = AV_CODEC_ID_NONE,
 -.audio_enc = {0},
 -.video_enc = {0},
 +.video_opts = NULL,
 +.video_conf = NULL,
 +.audio_opts = NULL,
 +.audio_conf = NULL,
 +.video_preset = NULL,
 +.audio_preset = NULL,
  };
  

Guess you are already considered dropping the explicit initialization
code as Reimaer suggested.

Looks good otherwise. Feel free to push.

Bests,

-- 
Reynaldo H. Verdejo Pinochet
Open Source Group
Samsung Research America / Silicon Valley
___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-devel


Re: [FFmpeg-devel] [PATCH] mpegts: add the judgement if a new program is ctreated successfully

2014-10-16 Thread Reynaldo H. Verdejo Pinochet

Hello Di Wu

On 10/15/2014 05:24 AM, di1028...@samsung.com wrote:

From: Di Wu di1028...@samsung.com

Add the judement after create a new program to avoid segment fault.
[..]


Thanks for your patch. Can you spell check your commit summary
though?, you have at least two typos there.

Thanks,

--
Reynaldo H. Verdejo Pinochet
Open Source Group
Samsung Research America / Silicon Valley
___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-devel


Re: [FFmpeg-devel] [PATCH] vp9:enable multi-thread decoding when refreshctx is equal to 0

2014-10-10 Thread Reynaldo H. Verdejo Pinochet

On 10/09/2014 11:16 PM, Di Wu wrote:

[..]
Thank  you for your suggestion.
I make the change in the else if branch and do some improvement follow
Reynaldo's suggestions, and create a new patch.
Because braces are used in if() branch, I also use braces in else if() branch. 
If
this doesn't meent the standards, I can change it again.
The new patch is attached, please check if there is any point needs to be 
modified.



Pushed. Thanks for your patch Di Wu

Bests,

--
Reynaldo H. Verdejo Pinochet
Open Source Group
Samsung Research America / Silicon Valley
___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-devel


[FFmpeg-devel] [OPW 201412] Please help track ongoing qualification tasks

2014-10-06 Thread Reynaldo H. Verdejo Pinochet
Hi everyone

Also linked from our landing page, you will find qualification tasks
been tracked here:

https://trac.ffmpeg.org/wiki/SponsoringPrograms/OPW/2014-12-Qualis

Please help updating that. If you already helped an applicant
selecting a suitable qualification tasks, then you are qualification
mentor for it.

[bikesheding alert] Complexity index

We will need a way to measure the applicant's performance against some
kind of common complexity index. Quite humorously and naive, I stabbed
there a mmh unit, meaning Median Michael Hours, or, how many days
would it take Michael to come up with a proper fix for the task at
hand. Pretty sure those who aren't laughing at this already will have a
better idea for a complexity index. If so, please discuss on a separate
thread and we can change it once something less LOLable has been
choosen.

Oh, almost forgot, it's the Qualification Mentor's task to suggest
that number, Guess Michael can have a run at them latter and correct
any wrongs.

Please do reserve some time to keep the table updated.

Thanks for all your help ppl!

Bests,


-- 
Reynaldo H. Verdejo Pinochet
Open Source Group
Samsung Research America / Silicon Valley
___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-devel


[FFmpeg-devel] Please help update tasks and mentor/backups for OPW

2014-09-27 Thread Reynaldo H. Verdejo Pinochet
Hello

As you might already know, Samsung has decided to back up our
initiative with the required 6K USD (Thanks!) and as result,
we have got at least one mentee covered for this round of the
Outreach Program for Women (http://gnome.org/opw/). We couldn't
be happier about this but there's quite some work to do to
ensure our prospective applicants get all the info they need.

What we need now is everyone's help updating and copyediting
our program landing page at
https://trac.ffmpeg.org/wiki/SponsoringPrograms/OPW/2014-12

Things that need urgent attention are ensuring listed projects
are still relevant as well as making sure their mentors are
still available and willing to take part on the program. I took
the liberty of CCing some of the currently listed mentors so
they can hopefully help with the latter.

If you were listed as a mentor please update your availability
and/or willingness status on the wiki. If you were listed as a
backup mentor for a mentorless project, please consider becoming
a full fledged mentor for it. Whatever the case, if you are updating
your availability or status on the wiki, please also let us
know on this same thread so we can easily keep tabs on who do we
still need to chase down ;)

Please do feel free to also add your own ideas (specially if you
are willing to mentor them ;). If you do so, please consider
sending a short note to the lists so we can do some back and
forth on them if needed. The more, the merrier!

Thanks in advance!

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


[FFmpeg-devel] [PATCH 2/2] libavfilter/af_channelmap: avoid derreferencing possible null

2014-09-26 Thread Reynaldo H. Verdejo Pinochet
ff_all_channel_layouts() might return null on alloc failure.

Fixes CID1241517

Signed-off-by: Reynaldo H. Verdejo Pinochet reyna...@osg.samsung.com
---
 libavfilter/af_channelmap.c | 8 +++-
 1 file changed, 7 insertions(+), 1 deletion(-)

diff --git a/libavfilter/af_channelmap.c b/libavfilter/af_channelmap.c
index 0bf2fe9..c3454c5 100644
--- a/libavfilter/af_channelmap.c
+++ b/libavfilter/af_channelmap.c
@@ -287,10 +287,16 @@ static av_cold int channelmap_init(AVFilterContext *ctx)
 static int channelmap_query_formats(AVFilterContext *ctx)
 {
 ChannelMapContext *s = ctx-priv;
+AVFilterChannelLayouts *layouts;
 
 ff_set_common_formats(ctx, ff_planar_sample_fmts());
 ff_set_common_samplerates(ctx, ff_all_samplerates());
-ff_channel_layouts_ref(ff_all_channel_layouts(), 
ctx-inputs[0]-out_channel_layouts);
+
+layouts = ff_all_channel_layouts();
+if (!layouts)
+return AVERROR(ENOMEM);
+
+ff_channel_layouts_ref(layouts, ctx-inputs[0]-out_channel_layouts);
 ff_channel_layouts_ref(s-channel_layouts,   
ctx-outputs[0]-in_channel_layouts);
 
 return 0;
-- 
2.1.0

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


[FFmpeg-devel] [PATCH 1/2] libavfilter/af_join: avoid derreferencing possible null

2014-09-26 Thread Reynaldo H. Verdejo Pinochet
ff_all_channel_layouts() might return null on alloc failure.

Fixes CID1241518

Signed-off-by: Reynaldo H. Verdejo Pinochet reyna...@osg.samsung.com
---
 libavfilter/af_join.c | 9 ++---
 1 file changed, 6 insertions(+), 3 deletions(-)

diff --git a/libavfilter/af_join.c b/libavfilter/af_join.c
index 560c5c8..a1717c6 100644
--- a/libavfilter/af_join.c
+++ b/libavfilter/af_join.c
@@ -248,9 +248,12 @@ static int join_query_formats(AVFilterContext *ctx)
 ff_add_channel_layout(layouts, s-channel_layout);
 ff_channel_layouts_ref(layouts, ctx-outputs[0]-in_channel_layouts);
 
-for (i = 0; i  ctx-nb_inputs; i++)
-ff_channel_layouts_ref(ff_all_channel_layouts(),
-   ctx-inputs[i]-out_channel_layouts);
+for (i = 0; i  ctx-nb_inputs; i++) {
+layouts = ff_all_channel_layouts();
+if (!layouts)
+return AVERROR(ENOMEM);
+ff_channel_layouts_ref(layouts, ctx-inputs[i]-out_channel_layouts);
+}
 
 ff_set_common_formats(ctx, ff_planar_sample_fmts());
 ff_set_common_samplerates(ctx, ff_all_samplerates());
-- 
2.1.0

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


[FFmpeg-devel] [PATCH] libavfilter/af_amix: avoid derreferencing possible null

2014-09-26 Thread Reynaldo H. Verdejo Pinochet
ff_all_channel_layouts() might return null on alloc failure.

Fixes CID1241516

Signed-off-by: Reynaldo H. Verdejo Pinochet reyna...@osg.samsung.com
---
 libavfilter/af_amix.c | 9 -
 1 file changed, 8 insertions(+), 1 deletion(-)

diff --git a/libavfilter/af_amix.c b/libavfilter/af_amix.c
index d8a6651..47cbb45 100644
--- a/libavfilter/af_amix.c
+++ b/libavfilter/af_amix.c
@@ -528,10 +528,17 @@ static av_cold void uninit(AVFilterContext *ctx)
 static int query_formats(AVFilterContext *ctx)
 {
 AVFilterFormats *formats = NULL;
+AVFilterChannelLayouts *layouts;
+
+layouts = ff_all_channel_layouts();
+
+if (!layouts)
+return AVERROR(ENOMEM);
+
 ff_add_format(formats, AV_SAMPLE_FMT_FLT);
 ff_add_format(formats, AV_SAMPLE_FMT_FLTP);
 ff_set_common_formats(ctx, formats);
-ff_set_common_channel_layouts(ctx, ff_all_channel_layouts());
+ff_set_common_channel_layouts(ctx, layouts);
 ff_set_common_samplerates(ctx, ff_all_samplerates());
 return 0;
 }
-- 
2.1.0

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


Re: [FFmpeg-devel] [PATCH 1/2] libavfilter/af_join: avoid derreferencing possible null

2014-09-26 Thread Reynaldo H. Verdejo Pinochet

Set pushed. Thanks for taking a look.

-- 
Reynaldo H. Verdejo Pinochet
Open Source Group
Samsung Research America / Silicon Valley
___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-devel


[FFmpeg-devel] Please help update tasks and mentor/backups for OPW

2014-09-25 Thread Reynaldo H. Verdejo Pinochet
Hello

As you might already know, Samsung has decided to back up our
initiative with the required 6K USD (Thanks!) and as result,
we have got at least one mentee covered for this round of the
Outreach Program for Women (http://gnome.org/opw/). We couldn't
be happier about this but there's quite some work to do to
ensure our prospective applicants get all the info they need.

What we need now is everyone's help updating and copyediting
our program landing page at
https://trac.ffmpeg.org/wiki/SponsoringPrograms/OPW/2014-12

Things that need urgent attention are ensuring listed projects
are still relevant as well as making sure their mentors are
still available and willing to take part on the program. I took
the liberty of CCing some of the currently listed mentors so
they can hopefully help with the latter.

If you were listed as a mentor please update your availability
and/or willingness status on the wiki. If you were listed as a
backup mentor for a mentorless project, please consider becoming
a full fledged mentor for it. Whatever the case, if you are updating
your availability or status on the wiki, please also let us
know on this same thread so we can easily keep tabs on who do we
still need to chase down ;)

Please do feel free to also add your own ideas (specially if you
are willing to mentor them ;). If you do so, please consider
sending a short note to the lists so we can do some back and
forth on them if needed. The more, the merrier!

Thanks in advance!

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


Re: [FFmpeg-devel] [PATCH] ffserver: deprecate Port and BindAddress options in favor of HTTPPort and HTTPBindAddress

2014-08-14 Thread Reynaldo H. Verdejo Pinochet

On 08/02/2014 10:40 AM, Stefano Sabatini wrote:

The new option names are more explicit.
---
 [..]


Looks OK

Bests,

--
Reynaldo H. Verdejo Pinochet
Sr. Multimedia Engineer, Open Source Group
Samsung Research America - Silicon Valley
___
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-devel