Chris Robinson
200c164d78
Improve HRTF delay handling
...
Ensures source-level HRTF, the dry mix, and direct output all align properly,
and simplifies adding the delay in the direct mix output.
2020-05-20 11:13:06 -07:00
Chris Robinson
f38b813ba8
Fix some comments
2020-05-19 18:22:38 -07:00
Chris Robinson
19baf646d2
Rename applyHfScale to processHfScale
2020-05-19 13:58:55 -07:00
Chris Robinson
c5e90ed6c7
Use an enum for FamCount
2020-05-19 12:15:57 -07:00
Chris Robinson
825206bfa2
Apply the ambisonic HF scaling in real-time with HRTF
...
Rather than applying the HF scale to the IRs necessitating them to be truncated
along with increasing the IR size, it can be applied to the input signal for
the same results. Consequently, the IR size can be notably shortened while
avoiding the extra truncation. In its place, the delayed reversed all-pass
technique can still be used on the input for maintaining phase when applying
the bandsplit/hfscalar filter to the input signal.
2020-05-19 10:27:52 -07:00
Chris Robinson
a512eae7bb
Move BUFFERSIZE and FloatBufferLine to a separate header
2020-05-19 10:21:19 -07:00
Chris Robinson
400a108ead
Also search for asimd for Neon
2020-05-17 16:23:24 -07:00
Chris Robinson
c75c96ce2d
Assume Neon support if cpu_caps.cpp is compiled with it
2020-05-17 14:14:29 -07:00
Chris Robinson
36aebbb6ae
Include the existing direct signal in the UHJ delay
...
So any direct_channels sources and normal panned sources remain aligned, and
the reported latency is accurate.
2020-05-16 11:35:55 -07:00
Chris Robinson
d086e78a38
Fix the all-pass's shuffle order
2020-05-14 21:16:21 -07:00
Chris Robinson
91b8387c0a
Give names to parameter value constants
2020-05-13 00:57:03 -07:00
Chris Robinson
f5bf7dc76e
Do two samples at once with the SSE UHJ all-pass
2020-05-12 05:51:48 -07:00
Chris Robinson
ad95cb6312
Clear the whole buffer
2020-05-12 04:46:15 -07:00
Chris Robinson
2f8f829772
Properly count the last number of samples to mix
2020-05-12 04:45:25 -07:00
Chris Robinson
3ce8a9914c
Fix applying the UHJ phase-shift filter
2020-05-11 23:49:39 -07:00
Chris Robinson
2574b98f8a
Move the bsinc tables out of common
2020-05-11 02:24:08 -07:00
Chris Robinson
0406e3bef7
Change a couple functions into member functions
2020-05-10 20:16:43 -07:00
Chris Robinson
2fb4ac1621
Revert "Fix the FFT half point for the shifter effects"
...
This reverts commit 12bb5a47cda0ef6ec1ced73ccf5d267a71f9e710.
2020-05-09 16:44:29 -07:00
Chris Robinson
52a5dc23a3
Fix the UHJ filter generator
...
The half point needs to be included in the frequency response.
2020-05-09 16:42:43 -07:00
Chris Robinson
73569dfeca
Avoid a reference on a constexpr variable
2020-05-08 20:11:30 -07:00
Chris Robinson
1c320c3532
Use a FIR filter for the UHJ all-pass
2020-05-08 15:38:14 -07:00
Chris Robinson
12bb5a47cd
Fix the FFT half point for the shifter effects
2020-05-08 01:39:48 -07:00
Chris Robinson
48fbad9836
Slightly improve the Hann windows
...
There's no need to include the 0 terms on the ends since they'll never
contribute a sample. So extend the width to have the 0 terms just outside the
window where it wouldn't contribute anyway.
2020-05-08 01:25:32 -07:00
Chris Robinson
301f8f5db5
Use std::arrays for the UHJ filters
2020-05-08 01:24:14 -07:00
Chris Robinson
0cfb8fee44
Combine multiple UHJ encoder all-pass loops
2020-05-07 21:01:37 -07:00
Chris Robinson
7ed37a8282
Use dual-band for the internal quad and 7.1 decoders
2020-05-07 03:15:46 -07:00
Chris Robinson
faec0c78eb
Allow declaring internal dual-band decoders
2020-05-07 02:13:11 -07:00
Chris Robinson
ca851298ad
Update the quad and 7.1 decoders
2020-05-06 22:36:29 -07:00
Chris Robinson
bef25361f1
Make the built-in decoders more flexible
2020-05-06 19:31:31 -07:00
Chris Robinson
f82fca2c6a
Fix the dual-band decoder
2020-05-05 16:56:25 -07:00
Chris Robinson
ee82db3966
Use a flexible array for the front stablizer delay buffers
2020-05-05 01:34:14 -07:00
Chris Robinson
deac36a1eb
Improve the front stablizer
...
Apply the all-pass+band-split only once, after generating the mid and side
signals separately.
2020-05-05 01:05:38 -07:00
Chris Robinson
fcec76663f
Move some sin/cos constants out of a loop
2020-05-04 16:16:55 -07:00
Chris Robinson
58d953f6aa
Clear buffers right before use
2020-05-03 19:13:20 -07:00
Chris Robinson
15fd3da870
Don't put the LFO on the stack
2020-05-03 19:04:43 -07:00
Chris Robinson
fe7a74b09a
Use a helper to set an identity ambisonic pan
2020-05-03 18:47:49 -07:00
Chris Robinson
b52fde7c0e
Simplify SIMD linear resampler loop count
2020-05-02 20:27:05 -07:00
Chris Robinson
b051f2e33d
Use a matching type given the initializer
2020-05-02 19:24:21 -07:00
Chris Robinson
6823fa2de2
Improve the leftover and realignment mixing loops
...
Using a mask helps the compiler recognize that the leftover (any remaining non-
multiple-of-4) and realignment loops will only have 3 iterations at most, which
it can unroll or otherwise make more meaningful optimizations for. Previously
it would try to vectorize and partially unroll the loops, which is wasteful
when there would never be enough to vectorize.
2020-05-02 16:42:24 -07:00
Chris Robinson
3898b77dd6
Avoid iterators for the main mixer
2020-05-01 21:14:41 -07:00
Chris Robinson
8acf16fc82
Make BuildBFormatHrtf a member of DirectHrtfState
2020-05-01 10:28:16 -07:00
Chris Robinson
ae09e1f60c
Don't truncate odd IR sizes with SSE
2020-04-30 20:33:35 -07:00
Chris Robinson
6bc3ae178e
Use a more efficient type for holding the IrSize
2020-04-30 17:03:56 -07:00
Chris Robinson
054071998c
Correctly handle unicode paths on Windows for ALSOFT_LOGFILE
2020-04-29 15:41:11 -07:00
Chris Robinson
a25dea6cd9
Rename effect_chain to effect_target
2020-04-29 14:39:28 -07:00
Chris Robinson
4094135ed7
Don't return a bool from the backend start method
2020-04-28 19:25:58 -07:00
Chris Robinson
065775d814
Limit the maximum settable sample rate
2020-04-28 16:30:11 -07:00
Chris Robinson
45cb3e4956
Remove a couple redundant comments
2020-04-28 14:59:45 -07:00
Chris Robinson
cf64dc1103
Fix up some more uses of [AL[C]]void
2020-04-28 14:48:12 -07:00
Chris Robinson
c47f4822dc
Move standard ALC function's annotations to the header
2020-04-28 13:36:43 -07:00