Commit Graph

6084 Commits

Author SHA1 Message Date
Chris Robinson f39d4598b7 Add exception protection to some AL functions 2019-04-10 13:05:21 -07:00
Chris Robinson d6f72b777a Fix usage of the voice's HRTF accumulation buffer when blending 2019-04-09 22:42:45 -07:00
Chris Robinson 55a3f38405 Don't use a fixed size buffer for printed messages 2019-04-09 22:13:21 -07:00
Chris Robinson 460a01443c Add macros to stop exceptions from leaving API functions
Effectively makes the functions act as noexcept, since there's no meaningful
reason to propogate exceptions from "C" functions. Currently only applied to
ALC functions, but can incrementally be applied to AL functions too. In the
future, this could also handle ALC and AL errors with unique exception types
(functions that utilize this behavior would need to ensure proper cleanup).
2019-04-09 20:48:01 -07:00
Chris Robinson e6daab51e8 Make sure the all-pass filter is cleared before use 2019-04-04 22:57:29 -07:00
Chris Robinson dc5759f80c Fix MSVC error about parenthesized explicit type conversion 2019-04-03 10:32:48 -07:00
Chris Robinson e66632b301 Avoid directly using CalcAmbiCoeffs 2019-04-02 20:23:19 -07:00
Chris Robinson d04f9326c9 Change RealMixParams::ChannelName to better reflect its use 2019-04-02 16:06:45 -07:00
Chris Robinson 9ac3524521 Spread out the ALC extensions like the AL extensions 2019-04-01 21:41:11 -07:00
Chris Robinson 86683264c9 Avoid multiple using statements for the same things 2019-04-01 21:35:52 -07:00
Chris Robinson 8781a32df5 Copy the voice's ambisonic upsampler state when reallocating 2019-04-01 17:27:31 -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 423333c594 Fix use of reverse_copy 2019-03-31 19:09:21 -07:00
Chris Robinson c88b09170c Use phase correction for the front stablizer 2019-03-31 18:54:43 -07:00
Chris Robinson d8c76ba0c0 Remove a couple unused member variables 2019-03-30 23:41:47 -07:00
Chris Robinson 89210cddb7 Don't stop the backend if it's not running 2019-03-30 23:30:15 -07:00
Chris Robinson cc91490b61 Use a temporary buffer for HRTF filter accumulation
Similar to the history buffer, to avoid using the state buffer as a ring
buffer.
2019-03-29 11:33:04 -07:00
Chris Robinson fe7918465e Use a function reference for a template parameter 2019-03-28 10:00:35 -07:00
Chris Robinson dfb81ff42d Avoid using the HRTF history buffer as a ring buffer
The HRTF mixers now get a full input buffer with the history prepended, so the
delay offsets just need to account for the start point and read forward for
each sample.
2019-03-28 09:34:31 -07:00
Chris Robinson e7bfe1ebd0 Simplify applying the field magnitude factor 2019-03-27 11:52:35 -07:00
Chris Robinson 095a0b9beb Set the EARLY_REQUESTS flag for PulseAudio when possible 2019-03-26 17:03:31 -07:00
Chris Robinson 608e4e916e Avoid recreating temporary buffers all the time 2019-03-26 17:01:45 -07:00
Chris Robinson 2960d729ef Fix a return type for accumulation 2019-03-26 13:47:24 -07:00
Chris Robinson 8b0c9fcf30 Require IR dimensions from a SOFA file 2019-03-26 13:45:25 -07:00
Chris Robinson 2446ee0cca Avoid some explicit loops 2019-03-26 12:37:52 -07:00
Chris Robinson a5b442b1a4 Add a missing include for varargs 2019-03-26 11:37:28 -07:00
Chris Robinson bcbe7c493c Remove another unnecessary distance check 2019-03-26 11:04:52 -07:00
Chris Robinson 525b5e65b2 Remove a couple unnecessary duration_casts 2019-03-26 10:20:32 -07:00
Chris Robinson 2c37d4fae1 Move an enum to a more appropriate header 2019-03-26 10:08:26 -07:00
Chris Robinson 4c32e55ac2 Don't mention which rendering methods aren't used 2019-03-25 23:17:34 -07:00
Chris Robinson a57116f788 Scale floats directly to 32-bit integer values
Rather than scaling to a 25-bit integer and shifting for the extra 7 bits. This
should improve precision for values closer to 0.
2019-03-25 22:52:15 -07:00
Chris Robinson 0a4d1c858e Support loading SOFA files directly with makemhr
This extracts the definition info it can from the SOFA, and uses the same logic
as sofa-info to automatically detect an appropriate layout. There is a bit of
code duplication from loaddef.cpp and sofa-info.cpp, though there are slight
modifications.
2019-03-25 20:16:02 -07:00
Chris Robinson cb02bb00be Detect SOFA files for makemhr input 2019-03-25 13:01:44 -07:00
Chris Robinson a3687db015 Use only a single function to load the HrirDataT 2019-03-25 00:21:45 -07:00
Chris Robinson 78aeca10c9 Add a command-line option to force mono input with makemhr 2019-03-24 22:43:43 -07:00
Chris Robinson 6edfa6e6e0 Cleanup some unnecessary parameters 2019-03-24 22:06:01 -07:00
Chris Robinson f392d9c138 Move makemhr's .def loading code to a separate source 2019-03-24 19:00:58 -07:00
Chris Robinson 5e6e738681 Change references of makehrtf to makemhr 2019-03-24 17:35:32 -07:00
Chris Robinson 7c16b1e02f Rename makehrtf to makemhr and move it to a subdirectory 2019-03-24 17:31:10 -07:00
Chris Robinson c8e8ac42ab Use false instead of 0 for a boolean 2019-03-24 14:02:06 -07:00
Chris Robinson f7ab7b45f7 Mark the device and context deletes as unlikely 2019-03-24 13:54:49 -07:00
Chris Robinson 12d4953a5f Remove a couple redundant distance checks 2019-03-23 13:55:07 -07:00
Chris Robinson 6df673e01c Don't redundantly set the voice's direct output buffer 2019-03-23 13:30:15 -07:00
Chris Robinson 819ec8a653 Rename and move ALeffectProps 2019-03-22 22:48:12 -07:00
Chris Robinson 3a6e741e90 Use MixParams for the wet buffers 2019-03-22 19:25:55 -07:00
Chris Robinson 92adfaebce Fix a comment typo 2019-03-22 18:37:47 -07:00
Chris Robinson edc32b40a5 Slightly improve casting in the modulator effect 2019-03-22 17:47:19 -07:00
Chris Robinson ea8b02dead Pass ALeffectProps directly to the get/setParam* methods 2019-03-22 16:04:13 -07:00
Chris Robinson e7e585f65c Use the effect state factory to set the default effect props 2019-03-22 15:00:37 -07:00