2154 Commits

Author SHA1 Message Date
Chris Robinson
36df67f546 Rename SetThreadName to althrd_setname 2014-04-17 20:41:32 -07:00
Chris Robinson
528c8c5e77 Check explicitly for pthread_mutexattr_setkind_np before use 2014-04-17 19:01:12 -07:00
Chris Robinson
8a00c24012 Fix SetThreadName for 64-bit MSVC builds 2014-04-17 09:22:57 -07:00
Chris Robinson
4b5e8b8c40 Don't inline al_nssleep 2014-04-17 09:14:03 -07:00
Chris Robinson
d1f1a1d056 Make and use a C11-like altimespec_get wrapper function 2014-04-17 09:03:57 -07:00
Chris Robinson
47f5c436c8 Fix a signed-unsigned comparison warning and clarify a comment 2014-04-17 01:24:03 -07:00
Chris Robinson
fbb4cbbe01 Keep TlsDestructors within threads.c
This basically makes the threads implementation self-contained in threads.c and
threads.h, except for the UIntMap/RWLock implementations.
2014-04-17 01:09:25 -07:00
Chris Robinson
e5d39a5f4c Don't use DllMain to call altss destructors 2014-04-17 00:56:02 -07:00
Chris Robinson
c3b1c31d9b Rename althread_key_ wrappers to altss_ and move it to threads.h/c 2014-04-17 00:11:12 -07:00
Chris Robinson
8cc3d05949 Fix some almtx_ return values 2014-04-16 08:21:45 -07:00
Chris Robinson
2149ccd985 Remove almtx_normal and almtx_errorcheck 2014-04-16 08:00:54 -07:00
Chris Robinson
c6dd479229 Make sure the duration given to althrd_sleep is valid 2014-04-16 07:52:43 -07:00
Chris Robinson
b020dd13fd Avoid using a Sleep() wrapper 2014-04-16 06:59:44 -07:00
Chris Robinson
184cf30cf7 Use althrd_yield instead of alsched_yield 2014-04-16 06:18:24 -07:00
Chris Robinson
d124aee4d7 Remove the old thread wrappers for the new ones 2014-04-16 06:11:40 -07:00
Chris Robinson
505ef82246 Move the threads and mutex wrappers to threads.c 2014-04-16 05:40:40 -07:00
Chris Robinson
e8517d8600 Fix Windows' almtx_timedlock 2014-04-16 05:32:55 -07:00
Chris Robinson
18ab9cbbdd Implement a C11-like thread wrapper and use it in mmdevapi and pulseaudio 2014-04-16 05:19:34 -07:00
Chris Robinson
29cb5058c0 Use a C11-like mutex wrapper instead of CRITICAL_SECTIONs 2014-04-16 01:39:11 -07:00
Chris Robinson
7bc08bb08c Ensure VECTOR_ITER_BEGIN gives a pointer-to-type instead of an array-of-type 2014-04-14 00:58:45 -07:00
Chris Robinson
e0d24f9da4 Use a helper to detect a path slash on Windows 2014-04-13 21:44:13 -07:00
Chris Robinson
e615ea3cf9 Use VECTOR_INSERT to copy and append strings 2014-04-13 20:54:12 -07:00
Chris Robinson
219a0e6352 Add a GCC-specific VECTOR_INSERT
This version is capable of doing a compile-time type checks, to ensure the
objects being inserted are compatible with the vector data type. It should
otherwise be functionally identical.
2014-04-13 20:26:04 -07:00
Chris Robinson
0ef87227c1 Pass in the vector insertion point as a pointer 2014-04-13 18:42:41 -07:00
Chris Robinson
cce9609b9e Avoid referencing the start iterator twice for vector insertion 2014-04-13 17:06:18 -07:00
Chris Robinson
90ae4b7c0f Add a VECTOR_INSERT method to insert a range of elements at once 2014-04-09 22:50:28 -07:00
Chris Robinson
023981acb9 Fix a NULL deref when cloning a 0-sized vector 2014-04-09 20:14:45 -07:00
Chris Robinson
1290f37750 Silence an MSVC warning about -1u 2014-04-07 13:55:22 -07:00
Chris Robinson
add3013234 Fix the default XDG_DATA_DIRS paths 2014-04-07 13:24:51 -07:00
Chris Robinson
4f1104125b Use an al_string vector for winmm device names
Also now gets wchar device names, to properly convert to UTF-8
2014-04-07 12:43:19 -07:00
Chris Robinson
c6821e5dd1 Use C11's static_assert when available 2014-04-07 11:48:28 -07:00
Chris Robinson
5e0fc84f49 Make HRTF stepping values per-channel 2014-04-05 10:24:13 -07:00
Chris Robinson
569374da2c Properly compare al_strings 2014-04-03 13:46:09 -07:00
Chris Robinson
482fb37b68 Recognize NULL as an empty vector/string 2014-04-03 11:13:12 -07:00
Chris Robinson
570eb4e1a7 Don't pass the vector's capacity as a parameter to vector_reserve 2014-03-31 06:13:56 -07:00
Chris Robinson
48b472abb7 Use vectors for the dsound device lists 2014-03-31 02:48:01 -07:00
Chris Robinson
7b93e10f7a Use an al_string for the device name 2014-03-28 22:11:34 -07:00
Chris Robinson
7570195b09 strlen returns size_t 2014-03-28 08:19:45 -07:00
Chris Robinson
d997be67fd Use al_string to handle mmdevapi and dsound device names 2014-03-28 07:59:47 -07:00
Chris Robinson
af8fda8a4a Add an al_string type and use it for the device lists 2014-03-28 05:44:19 -07:00
Chris Robinson
2ca673cca2 Properly handle special folder names with extended characters 2014-03-28 01:21:05 -07:00
Chris Robinson
20886059fd Wrap fopen calls under Windows
The idea is that all filenames we deal with are encoded as UTF-8, but the
Windows functions that take a char string interpret it using the ANSI codepage.
So instead, we convert the UTF-8 string to a wchar string, and then use the
wchar functions for proper extended character filename support.
2014-03-28 00:37:42 -07:00
Chris Robinson
d11d061b2c Don't have VECTOR_INIT "return" anything 2014-03-27 17:21:23 -07:00
Chris Robinson
4f3e71e5b7 Reactivate the mmdevapi audio client and set the event handle on reset 2014-03-27 17:17:35 -07:00
Chris Robinson
03fd2b8266 Remove setState from the MidiSynth vtable 2014-03-23 18:34:49 -07:00
Chris Robinson
cbb82647fb Remove an unnecessary conditional 2014-03-23 17:44:26 -07:00
Chris Robinson
e2cb41dc61 Remove the last bits of the predictive sample processing 2014-03-23 17:33:57 -07:00
Chris Robinson
72986882f5 Remove the click removal buffers for auxiliary effect slots 2014-03-23 16:28:55 -07:00
Chris Robinson
a25260ea8a Identity gain step is 1, not 0 2014-03-23 16:13:46 -07:00
Chris Robinson
f5e10b9945 Fix Neon gain step loops 2014-03-23 16:13:13 -07:00