On Tue, Mar 29, 2016 at 11:30:28AM +0200, Benjamin St wrote: > > Not all of the comments on top of the filter file look > > very useful to me, what do you think? > > In any case, I'd say a link to these should be useful: > > http://www.audiomisc.co.uk/HFN/HDCD/Enigma.html > > http://www.audiomisc.co.uk/HFN/HDCD/Examined.html > > (Or only the second one.) > > > I removed the rather useless comment and added both links. > > Please also add a fate test, since this is using floats, > > I would suggest to only compare pcm_s16 (instead of 24). > > Floats are no longer needed. This version uses only integer.
> Makefile | 1 > af_hdcd.c | 1138 > +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ > allfilters.c | 1 > 3 files changed, 1140 insertions(+) > 4e25a0315a659eb9e71adfacb9f9b2e78c5e1f33 > 0001-Implement-high-definition-audio-cd-filtering.patch > From f3053beac96884123e1c9d50b46876e6f69ae0d1 Mon Sep 17 00:00:00 2001 > From: Benjamin Steffes <benjaminst...@gmail.com> > Date: Mon, 21 Mar 2016 23:52:48 +0100 > Subject: [PATCH] Implement high definition audio cd filtering. > > Signed-off-by: Benjamin Steffes <benjaminst...@gmail.com> > --- > libavfilter/Makefile | 1 + > libavfilter/af_hdcd.c | 1138 > ++++++++++++++++++++++++++++++++++++++++++++++ > libavfilter/allfilters.c | 1 + > 3 files changed, 1140 insertions(+) > create mode 100644 libavfilter/af_hdcd.c Changelog entry and docs update missing a fate test would still be interresting i think has this been tested against some reference / known to be correct output for some stream ? [...] > +static int integrate(hdcd_state_t *state, int *flag, int const *samples, int > count, int stride) > +{ > + uint32_t bits = 0; > + int result = FFMIN(state->readahead, count); > + int i; > + *flag = 0; > + > + for (i = result - 1; i >= 0; i--) { > + bits |= (*samples & 1) << i; /* might be better as a conditional? */ > + samples += stride; > + } > + > + state->window = (state->window << result) | bits; > + state->readahead -= result; > + if (state->readahead > 0) > + return result; > + > + bits = (state->window ^ state->window >> 5 ^ state->window >> 23) & > 0xffffffffu; the & 0xffffffffu; seems redundant [...] > +static int filter_frame(AVFilterLink *inlink, AVFrame *in) > +{ > + AVFilterContext *ctx = inlink->dst; > + HDCDContext *s = ctx->priv; > + AVFilterLink *outlink = ctx->outputs[0]; > + AVFrame *out; > + int16_t *in_data; const [...] -- Michael GnuPG fingerprint: 9FF2128B147EF6730BADF133611EC787040B0FAB No snowflake in an avalanche ever feels responsible. -- Voltaire
signature.asc
Description: Digital signature
_______________________________________________ ffmpeg-devel mailing list ffmpeg-devel@ffmpeg.org http://ffmpeg.org/mailman/listinfo/ffmpeg-devel