Commit Graph

28 Commits

Author SHA1 Message Date
David Reid 4ebfb458c9 Fix some dead store warnings. 2020-12-03 17:44:49 +10:00
David Reid dc0b3288be Remove some unnecessary volatile qualifiers. 2020-11-28 11:11:15 +10:00
David Reid e10c34bc62 Try fixing a warning when compiling with GCC as C++. 2020-11-28 11:03:08 +10:00
David Reid d4add63b43 Silence some unused function warnings. 2020-11-28 10:40:51 +10:00
David Reid f400ccec8e Update c89atomic and fix some warnings. 2020-11-28 10:39:53 +10:00
David Reid 0ef7381f75 Silence some unused function warnings. 2020-11-28 10:05:02 +10:00
David Reid d98e37984d Silence some warnings. 2020-11-28 09:54:51 +10:00
David Reid e7940394b2 Fix some bugs with trying to access uninitialized variables. 2020-11-28 08:00:31 +10:00
David Reid 42611ca64c Fix a bug in the high level API when no pre-defined context is used. 2020-11-23 17:56:04 +10:00
David Reid f8c748870f Remove the use of bitfields in the public section of miniaudio_engine. 2020-11-23 17:38:44 +10:00
David Reid 17769e88ba Experiment with adding support for multiple input streams to effects. 2020-11-14 18:43:33 +10:00
David Reid f80d1dd8f7 Fix a bug in ma_effect_process_pcm_frames_with_conversion(). 2020-11-14 16:41:48 +10:00
David Reid 75401a5487 Remove effect chaining from the main ma_effect API.
This is adding too much complexity, is less efficient than doing it
manually, and is not compatible with some future changes for supporting
effects that require multiple input streams.
2020-11-14 15:46:55 +10:00
David Reid ea545bc356 Rename ma_effect_process_pcm_frames_ex().
This is in preparation for some future work.
2020-11-14 15:33:09 +10:00
David Reid 3c5f1e1c76 Remove dual fader.
This has been replaced with a simpler fading system.
2020-11-14 13:13:41 +10:00
David Reid 3c68efb333 Fix a bug in the stereo panner effect. 2020-10-11 15:40:58 +10:00
David Reid d8aa619250 Add some experimental fading APIs to the engine API.
This is a simplified and somewhat more intuitive way of handling fades.
With these APIs, fades are applied immediately, whereas with the old
fading APIs the fades were scheduled. The old APIs still exist, but may
be removed.

The ma_sound_set_fade_in_frames/milliseconds() API sets the fade which
will be applied immediately. If the starting volume is negative, the
fade will start from the current fade volume. This will also overwrite
any existing fade that is already happening.

The ma_sound_get_current_fade_volume() API allows you to retrieve the
current volume of the fade.

The fade is layered on top of the normal volume parameter. I.e. they
are configured and applied to the signal interdependently.

Currently, all fades are applied linearly.
2020-10-11 14:41:08 +10:00
David Reid 4f63069984 Engine: Fix a bug where sounds groups are not initialized properly.
This is happening due to the hierarchy not being constructed properly.
2020-10-11 09:40:57 +10:00
David Reid 742bccff4d Remove an unnecessary member from ma_engine_config. 2020-10-01 20:24:52 +10:00
David Reid e951e7ee61 Fix compilation errors when compiling as C++. 2020-10-01 20:12:17 +10:00
David Reid 5effa71e94 Minor refactor. 2020-09-15 17:39:15 +10:00
David Reid 0a73233877 Try fixing a bug where a sound is never unmarked as mixing.
This should fix a deadlock when uninitializing a sound after it's
reached the end.
2020-09-14 19:51:21 +10:00
David Reid 5e1f653efb Engine: Fix some bugs with effects. 2020-09-12 19:14:36 +10:00
David Reid 8d64b597f8 Fix a typo. 2020-09-12 12:56:57 +10:00
David Reid b0736de6b1 Add support for initializing an engine using a pre-initialized device. 2020-09-09 19:15:40 +10:00
David Reid 0c4fc08759 Minor documentation updates. 2020-09-05 13:45:22 +10:00
David Reid acf4284aa9 Fix a crash when passing in NULL for the engine config. 2020-09-05 10:12:27 +10:00
David Reid d0bfcf0cc1 Rename ma_engine.h to miniaudio_engine.h. 2020-09-05 10:01:44 +10:00