VUEngine now has full sound support

In these past years, VUEngine has improved so much and become better and better in all areas imaginable... well, except a single one: music. As one of the oldest parts of the software, the engine's sound manager has been seriously lagging behind, supporting only single track music and lacking any tools to actually produce any music, or convert some into the engine's format.

But that's history from now on! We have finally filled in the missing puzzle piece and rewritten the entirety of the engine's sound code. From now on, it is possible to play either PCM, converted from WAV files, or MIDIs, converted to a special format readable by the music player. You can use all 6 channels, which are automatically allocated and released, and there are fading effects and spatial positioning of audio sources, allowing you to locate the source of a sound thanks to the Virtual Boy's stereo speakers. You can also modify sound while it is played, and for instance speed it up. See below for a full list of features that are already implemented, as well as possible future additions.

Of course we also added another tool to the existing range of debug tools to accompany the updated sound support. Build your project in tools or debug mode and press LR+RT+RDown in-game to bring up the Sound Test. 

You can find a standalone version of the Sound Test tool attached to this post, including a selection of sample songs and sound effects.


Features

Implemented

  • PCM or MIDI playback
  • Multi-track, stereo playback
  • Dynamic allocation and release of sound channels
  • Support for noise channel
  • Playback events to facilitate the synchronization of playback state with game events
  • Fade in and fade out effects 
  • Spatial positioning of audio sources
  • Real time speed control
  • Sound test accessible through the debugging tools

TODO

  • Playback priority
  • Pause and resume playback based on priorities
  • Support for sweep and modulation
  • Compressed PCM playback (not very likely due to the strain on the CPU)
  • Compressed MIDI playback (may happen but as of now it is not necessary and will hit the performance)


Thanks!

All of this wouldn't have been possible without the help of various individuals. Thank you! To name a few:

  • thunderstruck, for sharing his music converter and playback code; we are using a modified version of the converter for MIDI conversion
  • Frostgiant, whose WAV converter we are using to convert PCM music
  • DanB, for sharing his MIDI player
  • Guy Perfect, for all his valuable work documenting the VSU, among other things


Coming up

Now that a much sought-after feature, according to our December poll, can be crossed off the list, we'll go back to the highest priority task, according to that poll, and work towards another Formula V demo. This time, though, other than the first two demos, we plan to release a demo for all of our backers. Also including sound this time, of course. :-)

In parallel, we'll keep on working on the de-facto successor to VBDE, VUEngine Studio, a Visual Studio Code extension for Nintendo Virtual Boy game development using VUEngine. Next on the TODO list will be to extend the toolchain to fully support the new sound code and allow for on-the-fly music conversion.

To stay updated, keep an eye on our Twitter, where we plan to (or hope to find the time to) more regularly post some in-development updates about our various projects, or catch us on Discord

Tier Benefits
Recent Posts