Commit Graph

5070 Commits

Author SHA1 Message Date
Chris Robinson
a55c93e1f5 Improve ASSUME for Clang
For some reason, the { if(!x)__builtin_unreachable(); } construct does not
provide the same optimization opportunity for Clang (even though the condition
being false would trigger undefined behavior by reaching unreachable code, it
still performs checks and such for the condition potentially being false).
Using __builtin_assume seems to work better.
2018-04-21 01:54:43 -07:00
Chris Robinson
400ab8766c Adjust the stereo panning front gain
This gives it a (more) precise -4.5dB gain drop for front-center panned sounds.
2018-04-19 21:55:20 -07:00
Chris Robinson
90b8d639f1 Remove unnecessary undefs 2018-04-19 18:24:27 -07:00
Chris Robinson
525b6fe168 Clear ALSA's PCM handle after closing it 2018-04-19 12:22:39 -07:00
Chris Robinson
f96a8fe369 Add some ASSUME statements that ensure mixing at least 1 sample 2018-04-18 20:39:52 -07:00
Chris Robinson
150586d7fe Add an ASSUME macro that requires a true condition 2018-04-17 22:50:50 -07:00
Chris Robinson
09194fd488 Accumulate the B-Format HRTF responses using doubles
The final result is still truncated to single-precision float, but this should
keep the responses more stable as it accumulates the various inputs.
2018-04-17 21:27:47 -07:00
Chris Robinson
e619b64175 Don't minimize the HRTF per-response delay
The reverts both fa9ab9af7c and
79604c3c0e. As helpful as it was for the high
frequencies, the overall response's gain suffered.
2018-04-16 18:54:41 -07:00
Chris Robinson
795ed65797 Preliminary ChangeLog update 2018-04-15 19:01:38 -07:00
Chris Robinson
5b82dd8733 Update .gitignore 2018-04-14 13:02:21 -07:00
Chris Robinson
9c5307a48a Rename BiquadState to BiquadFilter 2018-04-04 18:07:46 -07:00
Chris Robinson
b1fe405861 Improve ordering of channel processing in makehrtf 2018-04-03 11:21:15 -07:00
Chris Robinson
869637af2e Apply biquad and T60 filters using transposed direct form II 2018-04-03 10:15:35 -07:00
Chris Robinson
414b56edec Initialize COM using the multithreaded apartment
I honestly have no idea which is the correct (or better) mode to use given the
confusing mess COM is, but CoInitialize uses single-threaded apartments which
seems to be a problem for with at least a couple games in the STALKER series
(the call fails, which causes us to drop back to the DSound backend).
2018-04-01 16:39:20 -07:00
Chris Robinson
334bc4f551 Limit the near-field control distance to 10m. 2018-03-31 23:11:48 -07:00
Chris Robinson
e288c3b44a Fix HRTF HOA coefficients
ACN8 was accidentally put on ACN7. However, rather than adding the missing
channel of silence, set up the coefficient map to only use the ambisonic
channels that can contribute to output.
2018-03-31 20:44:14 -07:00
Chris Robinson
91900b0599 Fix misspellings of quadraphonic
AL_LOKI_quadriphonic is left alone since that is what the extension is called
and what code expects. All other instances have been fixed for consistency.
2018-03-30 09:18:17 -07:00
Chris Robinson
29ae74d4bb Fix lower elevation synthesis for stereo HRTFs 2018-03-29 20:44:44 -07:00
Chris Robinson
a2c24ff946 Specify Libs.private for the pkg-config file
Only used when building the static lib for its dependencies, since the shared
lib automatically handles its own dependencies.
2018-03-29 18:57:48 -07:00
Chris Robinson
61de399806 Don't cache SDL2_LIBRARY_TEMP with CMake
Otherwise it keeps prepending and appending the same extra libs and flags with
each invocation.
2018-03-29 18:10:58 -07:00
Chris Robinson
f48a1e3a31 Add simple descriptions to some extension formats in alext.h 2018-03-29 17:18:24 -07:00
Chris Robinson
4a8c3b50b6 Apply the initial decay and air absorption after gain clamping 2018-03-29 16:11:46 -07:00
Chris Robinson
852ad41176 Pass the azimuth and elevation to CalcPanningAndFilters 2018-03-29 16:11:46 -07:00
Chris Robinson
880d555060 Combine two loops 2018-03-29 16:11:46 -07:00
kcat
5523913a81
Merge pull request #184 from hhyyrylainen/master
Added missing string include to alffplay
2018-03-29 16:11:13 -07:00
Henri Hyyryläinen
a7da29804d Added missing string include to alffplay 2018-03-30 01:53:55 +03:00
Chris Robinson
cae4b1a062 Don't specify macros as arguments to CHECK_INCLUDE_FILE(S) 2018-03-28 14:34:58 -07:00
Chris Robinson
2b16ff3ca8 Check all buffers to update a source with 2018-03-28 06:28:46 -07:00
Chris Robinson
5aecce5a0d Store the ALbufferlistitem's composited/max sample length 2018-03-27 18:09:28 -07:00
Chris Robinson
d85ddf8aae Rename NfcFilterUpdate* to NfcFilterProcess* for consistency 2018-03-27 05:58:58 -07:00
Chris Robinson
788f5398b0 Slightly relax the memory order for ref counters 2018-03-26 10:14:27 -07:00
Chris Robinson
964723691a Condense an if check 2018-03-26 06:04:11 -07:00
Chris Robinson
2475d4652c Clear mixing target parameters before setting them 2018-03-25 18:02:07 -07:00
Chris Robinson
79eb2ea26e Reduce the gain of front-panned sounds with plain stereo
Now front-center sounds are attenuated by roughly -4.5dB instead of -3dB. This
will help keep rear-panned sounds from attenuating too much while not making
front-panned also attenuate too much.
2018-03-25 12:24:43 -07:00
Chris Robinson
f3672ab26b Annotate the B-Format rotation/conversion matrix 2018-03-25 08:24:53 -07:00
Chris Robinson
f757fbce4d Fix Hanning -> Hann window name 2018-03-24 14:18:29 -07:00
Chris Robinson
e5e3b05015 Fix capture device closing in the CoreAudio backend 2018-03-24 09:25:49 -07:00
kcat
eccf679ca9
Merge pull request #181 from jhasse/sdl2-include
Also add SDL2's include path
2018-03-24 09:25:13 -07:00
Jan Niklas Hasse
3fc9d3a1be Also add SDL2's include path 2018-03-24 16:45:13 +01:00
Chris Robinson
3f071a90a4 Use proc_pidpath to get the process path on macOS when available 2018-03-24 08:25:58 -07:00
Chris Robinson
413d55aaa5 Fix a couple comments about coordinate handedness 2018-03-24 07:02:27 -07:00
Raulshc
6d8062a2a7 EFX: Align some arrays used in intrinsics (#180) 2018-03-24 05:43:56 -07:00
Chris Robinson
6990478369 Rename ALfilterState/Type to BiquadState/Type 2018-03-23 14:52:59 -07:00
Chris Robinson
e37634e908 Remove an unused struct and move some functions to where they're used 2018-03-23 11:58:11 -07:00
Chris Robinson
63c9d95b84 Combine multiple allocations into one 2018-03-23 11:39:07 -07:00
Chris Robinson
63c35248be Some formatting cleanup 2018-03-22 11:32:23 -07:00
Chris Robinson
6685e0a078 Don't use an ALsizei for a potentially negative value 2018-03-22 11:11:45 -07:00
Chris Robinson
7789cc8e32 Define the Hanning window globally once for the pitch shifter 2018-03-22 09:55:15 -07:00
Chris Robinson
1d6622aa2b Fix a delta phase offset calculation in the pitch shifter
tmp can be negative, and &1 is not the same as %2 in that case.
2018-03-22 08:56:48 -07:00
Chris Robinson
eeff730034 Hold some immediate values on the stack 2018-03-22 08:49:35 -07:00