95 Commits

Author SHA1 Message Date
Chris Robinson
0a532729ba Reorganize how some device fields are set and reset 2019-06-15 23:10:11 -07:00
Chris Robinson
91b7e8142c Simplify DistanceComp somewhat 2019-06-08 01:39:28 -07:00
Chris Robinson
24df52c042 Remove the per-voice ChannelsPerOrder field 2019-06-05 23:00:28 -07:00
Chris Robinson
1ce310c6d1 Make some more channel counts unsigned 2019-06-05 19:26:54 -07:00
Chris Robinson
9d861406c0 Avoid a separate struct for the bandsplitter all-pass 2019-06-04 17:50:36 -07:00
Chris Robinson
53e1415a67 Allow selecting the ambisonic order for basic HRTF rendering 2019-06-02 20:38:43 -07:00
Chris Robinson
c80ee5b701 Use std::array for most mixing buffer arrays 2019-05-28 16:22:36 -07:00
Chris Robinson
3a9caec72f Use a span for referencing the channel map to initialize 2019-05-23 13:30:16 -07:00
Chris Robinson
5ac19673db Fix a couple type truncation warnings with MSVC 2019-05-12 19:41:34 -07:00
Chris Robinson
cef7eebed6 Disable NFC by default 2019-04-29 19:47:14 -07:00
Chris Robinson
b42694ea31 Allow NFC filters without HQ decoding
It still requires a proper custom decoder configuration for speakers, so that
proper distances can be specified. Ambisonic output still relies on the
nfc-ref-delay option, and HRTF uses the dataset's distance.
2019-04-29 19:47:14 -07:00
Chris Robinson
ace7481b8e Only enable NFC with HRTF when hq-mode is enabled 2019-04-28 21:49:10 -07:00
Chris Robinson
629cfa04a3 Fix some integer truncation warnings in MSVC 2019-04-12 19:19:24 -07:00
Chris Robinson
4b95d310ae Remove the SZFMT macro
C++11 mandates the %zu/d formatter
2019-04-11 16:01:11 -07:00
Chris Robinson
d04f9326c9 Change RealMixParams::ChannelName to better reflect its use 2019-04-02 16:06:45 -07:00
Chris Robinson
da8494dd8a Use the existing function to get the ambisonic channel count 2019-03-31 22:50:30 -07:00
Chris Robinson
0e0e85af72 Don't bother with a separate reset method for BFormatDec 2019-03-31 22:27:56 -07:00
Chris Robinson
c88b09170c Use phase correction for the front stablizer 2019-03-31 18:54:43 -07:00
Chris Robinson
4c32e55ac2 Don't mention which rendering methods aren't used 2019-03-25 23:17:34 -07:00
Chris Robinson
3a6e741e90 Use MixParams for the wet buffers 2019-03-22 19:25:55 -07:00
Chris Robinson
339a37b034 Include std::placeholders once in an anonymouse namespace 2019-03-16 15:15:59 -07:00
Chris Robinson
e4b76d2627 Reverse the HRTF field array
Most often a sound's distance will be beyond the farthest field measurement, so
It's more efficient to have the farthest field first and avoid looping through
the whole field array for them.
2019-02-27 23:13:40 -08:00
Chris Robinson
d2664e2192 Remove a duplicate index array 2019-02-24 18:00:49 -08:00
Chris Robinson
317206e8f3 Remove the FOAOut mixing buffer and associated post-processes 2019-02-22 22:35:37 -08:00
Chris Robinson
8ac2d34706 Allow processing some effects in higher order ambisonics
Reverb notably is still only first-order (any higher order channels are
dropped, and it writes to FOAOut). But others, like the equalizer, work on all
available channels.
2019-02-21 04:23:01 -08:00
Chris Robinson
a964890537 Add helpers to get the channel count from an ambisonic order 2019-02-21 04:05:49 -08:00
Chris Robinson
615446d6d5 Ensure the device's mAmbiOrder is always set appropriately
The Dry target is always ambisonic, so set its order correctly.
2019-02-21 01:23:11 -08:00
Chris Robinson
c43381d811 Allocate the effect slot wet buffer dynamically 2019-02-20 21:01:08 -08:00
Chris Robinson
194fcb6bb7 Rename MAX_AMBI_COEFFS and MAX_AMBI2D_COEFFS 2019-02-19 15:39:33 -08:00
Chris Robinson
d713f5f828 Clean up some AmbiUpsampler initialization 2019-02-19 01:59:30 -08:00
Chris Robinson
2d93a9cdb1 Collect HRTF field info into a struct 2019-01-28 20:43:34 -08:00
Chris Robinson
98be1d1bf5 Make IncRef and DecRef member functions 2019-01-24 10:05:37 -08:00
Filip Gawin
4169c6f37d Use c++ headers 2019-01-09 19:42:40 +01:00
Chris Robinson
673983dc5d Make Create methods for structs with flexible array members ...
... that are used with unique_ptr.
2019-01-08 23:44:08 -08:00
Chris Robinson
bc1eeb5df0 Avoid calling unique_ptr::reset with a raw pointer 2019-01-08 23:15:58 -08:00
Filip Gawin
0d3a0635d9 Avoid using old style casts
To think about:
examples/alffplay.cpp:600
OpenAL32/Include/alMain.h:295
2019-01-08 19:42:44 +01:00
Chris Robinson
fababe76c4 Don't use the dual-band upsampler for basic ambisonic decoding 2019-01-06 17:45:44 -08:00
Chris Robinson
da3a916042 Replace macros with constexpr inline functions 2019-01-06 04:16:51 -08:00
Chris Robinson
3b91010e21 Pass the normalized crossover frequency to the reset method 2019-01-05 22:31:13 -08:00
Chris Robinson
3f35fcc4b5 Simplify MixParams and AmbiUpsampler
Since the dry buffer is always an ambisonic target now
2019-01-05 21:59:04 -08:00
Chris Robinson
cff20c2fe8 Use BFormatDec for custom and built-in ambisonic decoding 2019-01-05 19:21:25 -08:00
Chris Robinson
2f1566e0b4 Add and use a make_unique function 2019-01-01 14:33:01 -08:00
Chris Robinson
fbae41020d Remove extraneous typedef, struct, and enum keywords 2018-12-24 19:29:01 -08:00
Chris Robinson
3fe38fed7c Mix effect slot output to the effect target if it's set 2018-12-23 08:51:28 -08:00
Chris Robinson
87724db6e3 Rename a couple HRTF structs 2018-12-22 09:20:50 -08:00
Chris Robinson
3553ce1f67 Don't convert the HRTF decoder virtual speaker positions to radians 2018-12-21 08:55:22 -08:00
Chris Robinson
b785d80526 Use a dodecahedron for the ambisonic HRTF decode
Also uses full second-order for "basic" HRTF rendering. Note that the supplied
matrix is full third-order, but only the first- and second-order coefficients
are used. The base matrices are the identical, only differing by the high-
frequency scalars.
2018-12-21 06:32:18 -08:00
Chris Robinson
7744e4ff72 Pass RealMixParams by reference instead of pointer 2018-12-20 13:26:39 -08:00
Chris Robinson
49ac268334 Add index maps from 2D and 3D 2018-12-20 04:19:35 -08:00
Chris Robinson
8d3f7651c9 Use std::array in place of some C-style arrays 2018-12-20 03:26:46 -08:00