Commit Graph

16 Commits (fc0937b2ffe141f0b5da4d93a3cbc3f76f5d17b8)

Author SHA1 Message Date
cosmonaut 5df08727c1 Sound instancing rework 2023-05-11 17:56:40 -07:00
cosmonaut bd405dfbf0 QOA Support (#48)
Reviewed-on: MoonsideGames/MoonWorks#48
2023-05-05 22:26:32 +00:00
cosmonaut 1cf04a7279 assets stream data directly into unmanaged memory 2023-04-05 00:47:02 -07:00
cosmonaut 1f0e3b5040 Audio Improvements (#47)
- Audio is now processed on a background thread instead of the main thread
- Audio tick rate is now ~200Hz
- MoonWorks.Math.Easings class completely rewritten to be easier to understand and use
- SoundInstance properties no longer call into FAudio unless the value actually changed
- SoundInstance property values can now be interpolated over time (tweens)
- SoundInstance tweens can be delayed
- SoundInstance sets a sane filter frequency default when switching filter type
- StreamingSound classes can be designated to update automatically on the audio thread or manually
- StreamingSound buffer consumption should now set Stopped state in a more sane way
- Added ReverbEffect, which creates a submix voice for a reverb effect
- SoundInstance can apply a ReverbEffect, which enables the Reverb property
- Audio resource tracking improvements
- Some tweaks to VideoPlayer to make its behavior more consistent

Reviewed-on: MoonsideGames/MoonWorks#47
2023-03-07 23:28:57 +00:00
cosmonaut 1e6455d070 fix StreamingSoundOgg seek 2022-08-02 14:15:16 -07:00
cosmonaut efb9893aef Theora video support + audio improvements (#20)
- `SoundInstance.Play` no longer takes a loop parameter
- `SoundInstance.Stop` is split into `Stop` and `StopImmediate` instead of taking an immediate parameter
- Added `StreamingSoundSeekable` to better support streaming audio that does not support seek
- `StreamingSound` no longer has a Loop property, but `StreamingSoundSeekable` does
- abstract `StreamingSound.AddBuffer` renamed to `FillBuffer`
- `FillBuffer` is now provided with a native buffer to avoid an extra data copy
- `StreamingSound` buffer implementation optimized to avoid repeated alloc/frees

- added `Video` class which can load and play Theora (.ogv) streaming video/audio

Reviewed-on: MoonsideGames/MoonWorks#20
2022-08-02 21:04:12 +00:00
cosmonaut 83eb268a4a add audio Seek functionality 2022-04-20 14:29:46 -07:00
cosmonaut 72c9dd4bda close vorbis stream before freeing data 2022-04-08 00:17:58 -07:00
cosmonaut b252d0eb92 forgot that C# arrays are not just memory 2022-04-07 15:11:14 -07:00
cosmonaut ba66ed4225 stream ogg from memory instead of disk 2022-04-07 14:19:43 -07:00
cosmonaut 6a1fa004d6 set loop on play instead of construct 2022-04-05 16:05:42 -07:00
cosmonaut b1b6b84809 WAV static sounds + static sound instance pool 2022-04-04 23:33:36 -07:00
cosmonaut 8973b3e658 Formatting pass 2022-02-22 21:14:32 -08:00
cosmonaut 5eb5027bf1 initial 3D audio implementation 2021-02-26 16:17:26 -08:00
cosmonaut 55d8e5a1df remove FileInfo references 2021-01-28 18:07:48 -08:00
cosmonaut 58427b8c90 refactor sound API to support generic decoding 2021-01-20 12:39:31 -08:00