Open tzachshabtay opened 8 years ago
One option is to use the OggStream class which has multiple versions in the web.
The original article: http://theinstructionlimit.com/ogg-streaming-using-opentk-and-nvorbis
MonoGame's version: https://github.com/mono/MonoGame/blob/ebfa6cfb743d6c9bfcab1e4425ea9110af45291e/MonoGame.Framework/Audio/OggStream.cs
NVorbis version: https://github.com/renaudbedard/nvorbis/blob/master/OpenTKSupport/OggStream.cs
There's a different implementation of the concept in Duality: https://github.com/AdamsLair/duality/blob/a911c46b6bc830c05d3bb1202f8e7060543eaefa/Duality/Audio/OggVorbis.cs
Another interesting option: https://blogs.msdn.microsoft.com/dotnet/2018/07/09/system-io-pipelines-high-performance-io-in-net/
With streaming, we'll be able to play a large file (song) before completely loading it, thus reducing the load time.