[pulseaudio-discuss] [PATCHv3 0/3] resampler: refactor calc_map_table()

Tanu Kaskinen tanuk at iki.fi
Thu Feb 7 06:48:22 PST 2013


On Thu, 2013-02-07 at 14:03 +0100, Stefan Huber wrote:
> Hi Tanu,
> 
> thanks for the fast replies!
> 
> 
> > I'd be happy with either of these two alternatives: only update
> > calc_map_table() without a separate patch, or update resampler.c in
> > its entirety with a separate patch.
> 
> The PATCHv3 1/3 contains the renaming of pa_bool_t to pa_bool and
> TRUE/true, FALSE/false, respectively.
> 
> PATCHv3 2/3 is basically the unaltered PATCHv2 1/2, but rebased onto
> PATCHv3 1/3.
> 
> PATCHv3 3/3 adds your comments:
> 
> > > + result of 1..6) factors should be multiplied by 0.7 (in the case
> > > + of S:Center) and 0.8 (in the case of S:LFE). If C-front is only
> > 
> > On that last quoted line, the "If" doesn't seem to belong there.
> 
> Fixed.
> 
> > > +  if (!ic_connected[ic] && on_left(r->i_cm.map[ic])) {
> > >        m->map_table_f[oc][ic] = .1f / (float) ic_unconnected_left;
> > > +  }
> > 
> > No braces for single-line ifs, please.
> 
> Fixed for multiple occasions in calc_map_table().
> 
> 
> PATCHv3 3B/3 is an alternative patch to PATCHv3 3/3. Instead of
> carefully trying to maintain the normalization-property of each row for
> each step, this patch simply normalizes the row in a post-processing
> step. As we do not require to perform normalizations after each step,
> we can add some further code simplifications.
> 
> After some time of thinking I tend to prefer PATCH 3B over PATCH 3 as it
> is a bit simpler and cleaner. What do you think?

I prefer 3B too. Thanks for the patches, I've now applied them all.

-- 
Tanu



More information about the pulseaudio-discuss mailing list