Search code examples
c#monogamenaudioemulationgameboy

Using NAudio for my GameBoy emulator


I have started to implement audio in my GB emulator and for this I am using NAudio. The emulator calculates the output into a byte array and after every frame loads it into a BufferedWaveProvider. For the output I use WaveOut which I start after the first byte array is loaded into the BufferedWaveProvider.

It seems to work pretty well but because this is my first time doing stuff with audio I would like to know if this is the right thing to do.

Also if you know how to make quadrangular waves sound better or something like this let me know.


Solution

  • Yes using BufferedWaveProvider is a good way to go. Looks like you are new to stack overflow. It is best to ask one question at a time. So I suggest asking your quadrangular wave question in a separate question.