Commit Graph

28 Commits

Author SHA1 Message Date
David Reid 503670532d Properly namespace some tokens. 2021-07-17 12:38:38 +10:00
David Reid 3fad6cad86 API CHANGE: Add channel maps to ma_data_source_get_data_format().
This commit also removes the onGetChannelMap callback from the decoding
backend vtable.
2021-07-04 18:21:36 +10:00
David Reid 366aa4346e Relax restrictions on the maximum input and output buses for nodes.
Previously this was restricted to 2 input buses and 2 output buses, but
this has been lifted to 254. When the number exceeds 2, internal data
structures will be allocated on the heap, otherwise they'll use a local
array contained within the ma_node structure.

This commit changes the node configuration. Previously there was a
fixed sized array for specifying the channel counts for each bus. This
array must now be defined outside of the config by the caller. The
following config variables have been renamed:

  * inputChannels > pInputChannels
  * outputChannels > pOutputChannels

This commit also adds the ability to configure input and output bus
counts on a per-instance basis rather than via the node vtable. To do
this, set the bus count in the vtable to MA_NODE_BUS_COUNT_UNKNOWN.
This will tell miniaudio to look at the node config to determine the
bus count rather than the vtable. It's an error to specify this in the
node config if the vtable specifies anything other than
MA_NODE_BUS_COUNT_UNKNOWN.
2021-07-03 12:40:13 +10:00
David Reid c54bb96964 Rename some config variables. 2021-07-01 14:58:05 +10:00
David Reid 9f4460797f Fix memory leaks. 2021-07-01 14:36:22 +10:00
David Reid d80c41f414 Update wording in comments. 2021-07-01 06:45:55 +10:00
David Reid a70515a96d Add example for using custom decoders with the resource manager. 2021-06-30 20:59:16 +10:00
David Reid ccd72f5714 Update example. 2021-05-16 16:10:52 +10:00
David Reid 722089d928 Fix the duplex_effect example.
This had the naming of source and excite the wrong way around.
2021-01-24 09:00:43 +10:00
David Reid 9ab7866237 Minor changes to resource_manager_advanced example. 2021-01-22 09:32:54 +10:00
David Reid f194a8bb59 Fix a bug in the resource_manager_advanced example. 2021-01-22 09:29:28 +10:00
David Reid 1b185878a1 Update the resource_manager_advanced example. 2021-01-22 07:19:01 +10:00
David Reid 361983f770 Update the resource manager example to work with Emscripten. 2021-01-17 18:51:44 +10:00
David Reid c85993ccf4 Scale the volume up a bit for the vocoder example. 2021-01-16 21:54:08 +10:00
David Reid c4a07387f6 Get the bus order correct on the vocoder example. 2021-01-16 21:41:02 +10:00
David Reid 306922e024 Clarification to the duplex_effect example. 2021-01-16 20:40:53 +10:00
David Reid 2e22affe38 Update ma_audio_buffer_ref_init() to take a buffer.
This saves a mandatory call to ma_audio_buffer_ref_set_data(). With
this change, an ma_audio_buffer_ref_init() call is all that is required
to initialize a usable data source.
2021-01-16 20:36:19 +10:00
David Reid 6c4bdaf7e0 Add vocoder node and duplex example. 2021-01-16 19:48:12 +10:00
David Reid 9535551f3c Add a new resource manager example and simplify the old one. 2020-09-05 10:49:57 +10:00
David Reid e6392c0ba7 Add hello world example for engine. 2020-09-05 10:24:31 +10:00
David Reid d0bfcf0cc1 Rename ma_engine.h to miniaudio_engine.h. 2020-09-05 10:01:44 +10:00
David Reid 65e547c5a6 Add output parameter for number of frames mixed to ma_mixer_mix_*(). 2020-08-09 09:02:25 +10:00
David Reid 0d8bf45dba Start some documentation for resource management. 2020-07-26 15:41:33 +10:00
David Reid 2a15044ff9 Update resource_manager example. 2020-07-25 18:27:59 +10:00
David Reid 24a1108834 Minor updates to the resource_manager example. 2020-07-23 17:01:04 +10:00
David Reid 5dda38d417 Add a clarifying comment to the resource_manager example. 2020-07-23 08:02:19 +10:00
David Reid 9972488bde Add some comments to the resource manager example for clarity. 2020-07-22 20:50:57 +10:00
David Reid 3bcdf3942d Add a resource manager example. 2020-07-22 20:35:34 +10:00