281 Commits

Author SHA1 Message Date
Chris Robinson
528c8c5e77 Check explicitly for pthread_mutexattr_setkind_np before use 2014-04-17 19:01:12 -07:00
Chris Robinson
8a51995cfa Bump _WIN32_WINNT to 0x0502 (XP SP2) for GetThreadId 2014-04-16 07:30:18 -07:00
Chris Robinson
c6821e5dd1 Use C11's static_assert when available 2014-04-07 11:48:28 -07:00
Chris Robinson
f1a4b95b8c Use FIND_LIBRARY to look for the CoreAudio framework 2014-04-05 17:43:35 -07:00
Chris Robinson
18620ab5e0 Check for ftw and _wfindfirst 2014-03-27 22:21:37 -07:00
Chris Robinson
045959e9c0 Use C99 VLA instead of alloca when available 2014-03-25 18:16:03 -07:00
Chris Robinson
cc599333a8 Don't try to use __restrict as a replacement for restrict
The compiler it's intended for, MSVC, can't use it anyway because of problems
it causes with __declspec(restrict).
2014-03-23 01:35:15 -07:00
Chris Robinson
9959972c7e Add a stub 'soft' MIDI synth handler
Eventually this one will be used to handle MIDI internally, using our own
mixers and resamplers.
2014-03-22 21:53:00 -07:00
Chris Robinson
143f786d1a Move the sample conversion routines to a separate file 2014-03-05 16:38:02 -08:00
Chris Robinson
a6eb38ea7f Use alloca for temp space decoding/encoding IMA4 blocks 2014-03-03 20:02:15 -08:00
Chris Robinson
5731534e8d Move the default hrtf table to an external file 2014-02-23 21:02:11 -08:00
Chris Robinson
748be9a97d Include sys/sysconf.h if available for sysconf() 2014-01-18 19:16:46 -08:00
Chris Robinson
fe55cd6de8 Add alLoadSoundfontSOFT to load a soundfont via callback
Some hefty caveats:
This function is not thread-safe. In particular, the current context affecting
the thread must not be changed, and the provided soundfont must not be
altered while the function is executing. Ideally, this will be fixed.

Error handling is poor. Some RIFF structure errors may not be caught (e.g. sub-
chunks with sizes greater than the parent chunk allows for), and generated AL
errors are ignored, possibly leading to resource leaks in certain situations.
These should be fixed in time.

There is minimal error checking on the provided soundfont ID. It does not
ensure a valid ID has been provided, nor does it ensure the provided soundfont
can be modified. These short-comings should be fixed eventually.

Proper cleanup is the responsibility of the caller. The caller must get the
preset objects from the soundfont before deleting it, and the fontsound objects
from each preset before deleting them, to make sure all resources are properly
deleted.
2013-12-28 09:58:55 -08:00
Chris Robinson
677b864565 Remove the zone, sample, and instrument object types 2013-12-25 19:35:43 -08:00
Chris Robinson
94ddc5cb18 Add a new fontsound object type
This is basically a combined preset and intrument zone with sample header.
2013-12-25 19:13:59 -08:00
Chris Robinson
99933fac49 Allow creating instrument objects 2013-12-19 00:57:07 -08:00
Chris Robinson
4288d3cd01 Move the soundfont and preset extension functions to separate sources 2013-12-19 00:27:11 -08:00
Chris Robinson
0653680690 Move the base MidiSynth to a separate file 2013-12-17 23:03:34 -08:00
Chris Robinson
0095a59fc9 Move the dummy MIDI handler to a separate file 2013-12-17 22:43:10 -08:00
Chris Robinson
ee92b3142d Move FluidSynth to its own file 2013-12-17 22:36:25 -08:00
Chris Robinson
a3c76c3274 Add an option for FLuidSynth to handle MIDI 2013-11-28 03:08:28 -08:00
Chris Robinson
d315feae40 Add a MIDI event queue
In preparation for a MIDI extension.
2013-11-27 03:49:26 -08:00
Chris Robinson
4830b1afe7 Try to make sure GCC is providing C99 inline semantics 2013-11-24 17:37:48 -08:00
Chris Robinson
414a9edc6e Explicitly define _POSIX_C_SOURCE and _XOPEN_SOURCE
Set them to 200809L and 700 respectively, instead of assuming _GNU_SOURCE will
do it.
2013-11-06 01:41:12 -08:00
Chris Robinson
b84f6d100f Set -D_GNU_SOURCE=1 earlier 2013-11-05 22:49:16 -08:00
Chris Robinson
801b7cb059 Include strings.h when available 2013-11-05 13:07:46 -08:00
Chris Robinson
6e43757fed Remove the cmake option to use wine headers 2013-10-29 11:38:37 -07:00
Chris Robinson
a507d0aa75 Disable MSVC warning 4098
a.k.a. "'void' function returning a value", caused by returning a void in a
function that returns void. Such as:

void foo() { }
void bar()
{
    return foo();
}

Which can happen due to some generalized macros that generate wrappers.
2013-10-29 11:27:06 -07:00
Chris Robinson
20bcb68ad6 Move ALCbackend base stuff to a separate file 2013-10-28 12:30:57 -07:00
Chris Robinson
f065700ef9 Move the lock/unlock methods to the backend 2013-10-28 05:10:28 -07:00
Chris Robinson
8ceb800def Rework threading functions 2013-10-27 08:14:13 -07:00
Chris Robinson
b9e30f7604 Add a cmake option to disable building only alsoft-config 2013-10-27 07:03:58 -07:00
Chris Robinson
ff5277f4d7 Add a method to set the running thread's name 2013-10-26 12:39:19 -07:00
Chris Robinson
6617985a4e Link to the correct sdl library for the loopback example 2013-10-26 08:52:07 -07:00
Chris Robinson
b5fece0381 Add a CMake option to not define the IDs used on Windows
This includes the GUIDs, IIDs, CLSID, and PropertyKeys. It is up to the user
to ensure the appropriate IDs are defined when linked.
2013-10-07 06:36:58 -07:00
Chris Robinson
41175ec84c Implement the Compressor effect 2013-10-03 07:55:12 -07:00
Chris Robinson
01a5946a2e Compile using -std=c99 when available 2013-10-03 05:45:12 -07:00
Chris Robinson
99fa5911bc Implement the Autowah effect. 2013-10-03 03:37:03 -07:00
Chris Robinson
7ebc1bb69e Use OpenAL_SOURCE_DIR for the CMake module path and declare the project earlier
The minimum CMake version required is also bumped to 2.6. Patch by Andrew West,
allows OpenAL Soft to be properly built as a sub-project.
2013-07-10 10:46:07 -07:00
Chris Robinson
61c6a38f04 Don't have ../../ as part of the target name 2013-07-02 02:02:57 -07:00
Chris Robinson
a375104826 Make sure SDL_sound was found before setting the includes 2013-06-25 03:53:48 -07:00
Chris Robinson
62dd5f33b2 Better handle the INCLUDE_DIRECTORIES property
Older cmake verions (prior to 2.8.8) don't have a per-target
INCLUDE_DIRECTORIES property, so the directories have to be
added using the INCLUDE_DIRECTORIES command.
2013-06-25 03:14:04 -07:00
Chris Robinson
77a2c8bcf0 Check for Qt4 earlier 2013-06-24 18:38:26 -07:00
Chris Robinson
5c7680ec84 Use the COMPILE_DEFINITIONS property instead of DEFINE_SYMBOL 2013-06-24 17:40:03 -07:00
Chris Robinson
18157bc331 Better specify include directories and defines needed for various targets 2013-06-24 16:30:04 -07:00
Chris Robinson
eebc6c0419 Move alsoft-config to a separate project file
This to help avoid FindQt4.cmake from polluting the current project with
defines and include directories, applying them to targets that don't use Qt.
2013-06-24 04:27:35 -07:00
Chris Robinson
144059b062 Add a configuration UI application
Not complete, but it's a decent start. Some problems:

* Only some otions are handled (backend-specific options in particular aren't
  handled).

* Does not warn when quitting with unsaved changes.

* Some options are missing tooltips.
2013-06-23 22:47:51 -07:00
Chris Robinson
4017e4a96a Check for MinGW in CMakeLists.txt instead of config.h 2013-06-20 17:17:17 -07:00
Chris Robinson
ff44ebfd5b Add a loopback extension example 2013-06-16 16:10:21 -07:00
Chris Robinson
dcefeac6e6 Use a static lib for the common example code 2013-06-05 23:07:33 -07:00