3691 Commits

Author SHA1 Message Date
Chris Robinson
b54c4b02c7 Add a wrapper to manage PROPVARIANT objects 2018-11-02 13:32:42 -07:00
Chris Robinson
9e8e3c146f Workaround lack of roundf with early MSVC 2018-11-02 09:39:57 -07:00
Chris Robinson
e20d2cdbce Use HUGE_VALF instead of INFINITY
Older MSVC lacks INFINITY, and we define a HUGE_VALF fallback when needed.
2018-11-02 09:25:19 -07:00
Chris Robinson
4ec757c1de Specify the correct array size for casting 2018-11-02 09:22:12 -07:00
Chris Robinson
aaa31d987f Check the correct propvariant object 2018-11-02 00:42:50 -07:00
Chris Robinson
d66664122a Try another fix to declare GUIDs in C++ 2018-11-02 00:13:07 -07:00
Chris Robinson
66df771d96 Make the polymorphism macros less hacky in C++
In particular, it relies on derived structs using C++-style inheritence. Any
implementation's source that's converted to C++ will consequently need to make
that change.
2018-11-01 23:52:53 -07:00
Chris Robinson
7307c2d5aa Workaround some issue with DEFINE_GUID in C++ 2018-11-01 21:42:26 -07:00
Chris Robinson
a90b17113a Use more C++ types where possible 2018-11-01 21:39:34 -07:00
Chris Robinson
434582b8e3 Use an anonymous namespace instead of static for some things 2018-11-01 20:18:51 -07:00
Chris Robinson
1ca4e268f6 Preliminary conversion of the WASAPI backend to C++
A very sparse conversion. Will clean up more later after seeing what MSVC does.
2018-11-01 16:26:42 -07:00
Chris Robinson
c0ce71a175 Fix a macro check 2018-11-01 16:00:38 -07:00
Chris Robinson
11967dc2da Use a wrapper function to simplify a check 2018-11-01 16:00:16 -07:00
Chris Robinson
69162cf9c6 Use perfect forwarding to initialize DevMap entries 2018-11-01 13:12:42 -07:00
Chris Robinson
cd68530ab4 Simplify a couple loops 2018-11-01 11:44:11 -07:00
Chris Robinson
5d092a1c58 Use the appropriate enums for standard atomics 2018-11-01 08:43:31 -07:00
Chris Robinson
d28c0eb556 Avoid uniform initialization with references
Also doesn't work with GCC 4.x
2018-11-01 08:41:23 -07:00
Chris Robinson
48f877e859 Remove unused header 2018-11-01 08:19:51 -07:00
Chris Robinson
ccf356a03d Include a missing header for atomic 2018-11-01 08:17:23 -07:00
Chris Robinson
95966c4d92 Fix another use of auto uniform initialization 2018-11-01 08:15:47 -07:00
Chris Robinson
759c3a996c Avoid all uniform initialization with auto
Because of early C++11 (GCC 4.x) deficiencies, it's not interpreted correctly.
Either declare the type name explicitly with uniform initization, or use auto
with = initialization. It'll be fine when updating to GCC 5 or Clang 3.6.
2018-11-01 08:04:21 -07:00
Chris Robinson
353bb1ed17 Avoid uniform initialization on auto for integer types
To work around a deficiency with early C++11 compilers (GCC 4.x).
2018-10-31 22:10:26 -07:00
Chris Robinson
d41fbd5c2d Convert the PulseAudio backend to C++ 2018-10-31 20:09:14 -07:00
Chris Robinson
0e7986eaa8 Move some extern inline declarations to C 2018-10-31 13:21:05 -07:00
Chris Robinson
662e1c5cc2 Fix some uses of RESTRICT 2018-10-29 11:50:41 -07:00
Chris Robinson
903d878460 Replace restrict with RESTRICT 2018-10-29 11:32:50 -07:00
Chris Robinson
e876b50113 Remove unnecessary uses of IN_IDE_PARSER 2018-10-29 10:10:37 -07:00
Chris Robinson
7d5a288e83 Add a couple casts for compiling with C++
Also avoid using __builtin_types_compatible_p, which seems broken with C++?
2018-10-29 10:10:37 -07:00
Chris Robinson
1d7b0f54be Add another missing extern "C" 2018-10-29 10:10:37 -07:00
Chris Robinson
8a8ab68f1c Add a more C++-friendly VECTOR_RESIZE 2018-10-29 10:10:37 -07:00
Chris Robinson
fd1361c198 Add a RESTRICT macro to help with C++ compatibility 2018-10-29 10:10:37 -07:00
Chris Robinson
7f8ef092aa Fix a couple internal headers to compile with C++ 2018-10-29 10:10:37 -07:00
Filip Gawin
08226bc6b0 Simplify some statements 2018-10-29 13:38:58 +01:00
Chris Robinson
7a79f09a31 Add a comment about waiting to kill the event thread 2018-10-07 17:18:50 -07:00
Chris Robinson
db65113c5f Use a 24-bit dither depth limit 2018-10-03 13:51:21 -07:00
Chris Robinson
f3f94e478b Don't limit output for ALC_DONT_CARE_SOFT and float samples 2018-10-03 13:48:04 -07:00
Chris Robinson
c39eeb9638 Don't try to get the JNIEnv on Android
It's currently not used. More stuff is needed anyway which may need a different
approach.
2018-10-02 12:40:26 -07:00
Chris Robinson
493c8bbc83 Add back an inadvertently removed static 2018-10-02 12:25:26 -07:00
Chris Robinson
052fdd67cd Use < instead of != for some loop checks 2018-10-01 15:59:05 -07:00
Chris Robinson
ed8f44d102 Don't scale the reverb fade counter so much 2018-09-30 16:34:00 -07:00
Chris Robinson
1d1acc0c34 Ensure BUFFERSIZE is a power of 2 2018-09-30 12:12:27 -07:00
Chris Robinson
1860b2ec8a Make the Compressor struct opaque 2018-09-30 12:08:01 -07:00
Chris Robinson
7ad4f753a4 Fix some length ranges 2018-09-29 19:39:49 -07:00
Chris Robinson
d5a78f0843 Improve a couple loops
Avoid masking the index with each iteration, and instead do up to when the mask
would apply. This allows for better optimizations, in particular fewer
instructions and better chances for vectorization.
2018-09-29 18:48:28 -07:00
Chris Robinson
32494e72a5 Don't use a ringbuffer design for the limiter's side chain
Rather than continuously wrapping when used, each update uses it from the front
and copies the tail to the front at the end. This allows for more effficient
accesses in loops.
2018-09-29 11:54:45 -07:00
Chris Robinson
0396c0ecd2 Add some assumes for the limiter 2018-09-29 09:47:05 -07:00
Chris Robinson
51a447852f Simplify a lower-bound clamp 2018-09-28 18:34:21 -07:00
Chris Robinson
1684b2cc5f Constify a couple more variables 2018-09-28 16:42:22 -07:00
Chris Robinson
79314c4461 Include the limiter's lookAhead delay in the device latency 2018-09-25 23:05:27 -07:00
Chris Robinson
2d6309d6fc Don't hardcode the limiter threshold
It's now calculated from the output sample type and dither depth.
2018-09-25 10:33:20 -07:00