[PATCH 1/2] lavfi/avf_showspectrum: set output frame rate.
Signed-off-by: Nicolas George <george@nsup.org> --- libavfilter/avf_showspectrum.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/libavfilter/avf_showspectrum.c b/libavfilter/avf_showspectrum.c index 4a4b4f4..e3ae6ea 100644 --- a/libavfilter/avf_showspectrum.c +++ b/libavfilter/avf_showspectrum.c @@ -246,6 +246,8 @@ static int config_output(AVFilterLink *outlink) if (s->xpos >= outlink->w) s->xpos = 0; + outlink->frame_rate = av_make_q(inlink->sample_rate, win_size); + s->combine_buffer = av_realloc_f(s->combine_buffer, outlink->h * 3, sizeof(*s->combine_buffer)); -- 2.0.1
Signed-off-by: Nicolas George <george@nsup.org> --- libavfilter/avf_showspectrum.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) These two patches fix a bunch of "non-monotonically" warnings/errors. diff --git a/libavfilter/avf_showspectrum.c b/libavfilter/avf_showspectrum.c index e3ae6ea..28db8b1 100644 --- a/libavfilter/avf_showspectrum.c +++ b/libavfilter/avf_showspectrum.c @@ -468,7 +468,7 @@ static int plot_spectrum_column(AVFilterLink *inlink, AVFrame *insamples, int nb } outpicref->pts = insamples->pts + - av_rescale_q(s->consumed, + av_rescale_q(s->consumed + add_samples - win_size, (AVRational){ 1, inlink->sample_rate }, outlink->time_base); ret = push_frame(outlink); -- 2.0.1
On Sun, Aug 03, 2014 at 04:29:36PM +0200, Nicolas George wrote:
Signed-off-by: Nicolas George <george@nsup.org> --- libavfilter/avf_showspectrum.c | 2 ++ 1 file changed, 2 insertions(+)
diff --git a/libavfilter/avf_showspectrum.c b/libavfilter/avf_showspectrum.c index 4a4b4f4..e3ae6ea 100644 --- a/libavfilter/avf_showspectrum.c +++ b/libavfilter/avf_showspectrum.c @@ -246,6 +246,8 @@ static int config_output(AVFilterLink *outlink) if (s->xpos >= outlink->w) s->xpos = 0;
+ outlink->frame_rate = av_make_q(inlink->sample_rate, win_size); + s->combine_buffer = av_realloc_f(s->combine_buffer, outlink->h * 3, sizeof(*s->combine_buffer));
OK May I ask what use-case this is fixing? -- Clément B.
On Wed, Aug 06, 2014 at 11:37:23AM +0200, Clément Bœsch wrote:
On Sun, Aug 03, 2014 at 04:29:36PM +0200, Nicolas George wrote:
Signed-off-by: Nicolas George <george@nsup.org> --- libavfilter/avf_showspectrum.c | 2 ++ 1 file changed, 2 insertions(+)
diff --git a/libavfilter/avf_showspectrum.c b/libavfilter/avf_showspectrum.c index 4a4b4f4..e3ae6ea 100644 --- a/libavfilter/avf_showspectrum.c +++ b/libavfilter/avf_showspectrum.c @@ -246,6 +246,8 @@ static int config_output(AVFilterLink *outlink) if (s->xpos >= outlink->w) s->xpos = 0;
+ outlink->frame_rate = av_make_q(inlink->sample_rate, win_size); + s->combine_buffer = av_realloc_f(s->combine_buffer, outlink->h * 3, sizeof(*s->combine_buffer));
OK
May I ask what use-case this is fixing?
Missed the comment in your second patch, ignore this -- Clément B.
Le nonidi 19 thermidor, an CCXXII, Clément Bœsch a écrit :
OK
Thanks for the reviews on this series. I have pushed this to my tree for merging at any convenient time: a3aaaec lavfi/avf_showspectrum: set output frame rate. 65b284a lavfi/avf_showspectrum: fix output pts computation. d4de6d4 lavfi/avf_showspectrum: do not push the frame at EOF. ec33df6 lavfi/avf_showspectrum: use automatic framing. 7c10e32 lavfi/avf_showspectrum: add full frame sliding mode. c2c3e32 lavfi/avf_showspectrum: check RDFT contet init. Regards, -- Nicolas George
On Thu, Aug 14, 2014 at 03:06:14PM +0200, Nicolas George wrote:
Le nonidi 19 thermidor, an CCXXII, Clément Bœsch a écrit :
OK
Thanks for the reviews on this series. I have pushed this to my tree for merging at any convenient time:
a3aaaec lavfi/avf_showspectrum: set output frame rate. 65b284a lavfi/avf_showspectrum: fix output pts computation. d4de6d4 lavfi/avf_showspectrum: do not push the frame at EOF. ec33df6 lavfi/avf_showspectrum: use automatic framing. 7c10e32 lavfi/avf_showspectrum: add full frame sliding mode.
c2c3e32 lavfi/avf_showspectrum: check RDFT contet init.
contet? [...] -- Clément B.
Le septidi 27 thermidor, an CCXXII, Clément Bœsch a écrit :
contet?
Thanks for spotting it. The series to merge is now: a3aaaec lavfi/avf_showspectrum: set output frame rate. 65b284a lavfi/avf_showspectrum: fix output pts computation. d4de6d4 lavfi/avf_showspectrum: do not push the frame at EOF. ec33df6 lavfi/avf_showspectrum: use automatic framing. 7c10e32 lavfi/avf_showspectrum: add full frame sliding mode. 638eec2 lavfi/avf_showspectrum: check RDFT context init. (only the last changed). Regards, -- Nicolas George
On Thu, Aug 14, 2014 at 03:13:03PM +0200, Nicolas George wrote:
Le septidi 27 thermidor, an CCXXII, Clément Bœsch a écrit :
contet?
Thanks for spotting it. The series to merge is now:
a3aaaec lavfi/avf_showspectrum: set output frame rate. 65b284a lavfi/avf_showspectrum: fix output pts computation. d4de6d4 lavfi/avf_showspectrum: do not push the frame at EOF. ec33df6 lavfi/avf_showspectrum: use automatic framing. 7c10e32 lavfi/avf_showspectrum: add full frame sliding mode. 638eec2 lavfi/avf_showspectrum: check RDFT context init.
(only the last changed).
merged thanks [...] -- Michael GnuPG fingerprint: 9FF2128B147EF6730BADF133611EC787040B0FAB Dictatorship naturally arises out of democracy, and the most aggravated form of tyranny and slavery out of the most extreme liberty. -- Plato
participants (3)
-
Clément Bœsch -
Michael Niedermayer -
Nicolas George