diff options
author | Chris Robinson <[email protected]> | 2016-03-22 17:52:20 -0700 |
---|---|---|
committer | Chris Robinson <[email protected]> | 2016-03-22 17:52:20 -0700 |
commit | 713ac9e6790ac5bb9491a893c9b2ee0a693878b7 (patch) | |
tree | dfba2a437adab49ddea4125e936f5866511e4baa /Alc/bformatdec.c | |
parent | 0a03596af11570f5dba473c93c67c59d285d7bc2 (diff) |
Add a specific output for first-order sources
Diffstat (limited to 'Alc/bformatdec.c')
-rw-r--r-- | Alc/bformatdec.c | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/Alc/bformatdec.c b/Alc/bformatdec.c index f5a8e8c4..37be67e4 100644 --- a/Alc/bformatdec.c +++ b/Alc/bformatdec.c @@ -142,6 +142,14 @@ void bformatdec_free(BFormatDec *dec) } } +int bformatdec_getOrder(const struct BFormatDec *dec) +{ + if(dec->NumChannels > 9) return 3; + if(dec->NumChannels > 4) return 2; + if(dec->NumChannels > 1) return 1; + return 0; +} + void bformatdec_reset(BFormatDec *dec, const AmbDecConf *conf, ALuint chancount, ALuint srate, const ALuint chanmap[MAX_OUTPUT_CHANNELS]) { const ALfloat *coeff_scale = UnitScale; |