diff options
author | Lennart Poettering <lennart@poettering.net> | 2008-09-08 17:25:16 +0300 |
---|---|---|
committer | Lennart Poettering <lennart@poettering.net> | 2008-09-08 17:25:16 +0300 |
commit | c7a77657ffe00b6d52a0c7e3d29f4fcf8537af5f (patch) | |
tree | 1ac05a5c37df435c164736b684903a926a733b8d /src/pulsecore/resampler.c | |
parent | 6b034f5bfd4a69d5795f2292014f902fd450a8a4 (diff) | |
parent | 821dc1797faa903618c7585d3c053fd7ae6e93db (diff) |
Merge branch 'master' into master-tx
Diffstat (limited to 'src/pulsecore/resampler.c')
-rw-r--r-- | src/pulsecore/resampler.c | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/src/pulsecore/resampler.c b/src/pulsecore/resampler.c index 45cd68c1..0ae029b3 100644 --- a/src/pulsecore/resampler.c +++ b/src/pulsecore/resampler.c @@ -716,7 +716,11 @@ static void calc_map_table(pa_resampler *r) { * channels for LFE. */ for (ic = 0; ic < r->i_ss.channels; ic++) { - r->map_table[oc][ic] = 1.0f / (float) r->i_ss.channels; + + if (!(r->flags & PA_RESAMPLER_NO_LFE)) + r->map_table[oc][ic] = 1.0f / (float) r->i_ss.channels; + else + r->map_table[oc][ic] = 0; /* Please note that a channel connected to LFE * doesn't really count as connected. */ @@ -851,7 +855,7 @@ static void calc_map_table(pa_resampler *r) { } } - if (ic_unconnected_lfe > 0) { + if (ic_unconnected_lfe > 0 && !(r->flags & PA_RESAMPLER_NO_LFE)) { /* OK, so there is an unconnected LFE channel. Let's mix * it into all channels, with factor 0.375 */ |