Questions (mainly) about SNES Audio

Discussion of hardware and software development for Super NES and Super Famicom. See the SNESdev wiki for more information.

Moderator: Moderators

Forum rules
  • For making cartridges of your Super NES games, see Reproduction.
User avatar
FinalZero
Posts: 152
Joined: Thu Dec 03, 2009 7:27 am
Contact:

Questions (mainly) about SNES Audio

Post by FinalZero »

These 2 videos describe the NES's audio:
(a) https://youtu.be/q_3d1x2VPxk
(b) https://youtu.be/la3coK5pq5w (This video also goes on to talk about the C64, which has a sawtooth waveform. If a pulse/square wave is for the melody, a triangle wave is for drums, and noise for snares, what is the sawtooth wave for?)
To summarize, there are 5 voices: 2 pulses/squares, 1 triangle, 1 noise, and one sample.

But, some games sound different (better!) on the famicom:
(a) https://youtu.be/dgoIJs1PbJw (Zelda)
(b) https://youtu.be/ptgaCJSF7j8 (Castlevania)
Apparently the Famicom has an extra 6th channel that sounds like bells? Why did this get removed from the NES ?

I read on Wikipedia ( https://www.wikiwand.com/en/Nintendo_S-SMP#/DSP ) that the SNES has 8 voices, instead of 5. But the page doesn't explain any deeper. What waveforms are allowed? Is each voice's waveform fixed like the NES, or customizeable like the C64 ?

During the NES era, some games would briefly pause the background music when a jingle for some action (jump, attack, etc) played. I assume this was because the NES had a limited amount of voices, most of which were already taken up by the background music, so the music had to be paused so the jingle could be played? This kind of thing didn't happen during the SNES era, because there was more voices available, and 1 or 2 could be reserved for jingles to play at any time, right?

And finally, what are the parameters for NES and SNES sounds if one wanted to define and use them in a MIDI file?
lidnariq
Posts: 11432
Joined: Sun Apr 13, 2008 11:12 am

Re: Questions (mainly) about SNES Audio

Post by lidnariq »

FinalZero wrote:Apparently the Famicom has an extra 6th channel that sounds like bells? Why did this get removed from the NES ?
It's not part of the Famicom.
It's part of the Famicom Disk System. There's extremely technical details on our wiki: https://wiki.nesdev.com/w/index.php/FDS_audio
What waveforms are allowed? Is each voice's waveform fixed like the NES, or customizeable like the C64 ?
"All of them". The SNES's sound unit is a kind of "wavetable synthesizer".
This kind of thing didn't happen during the SNES era, because there was more voices available, and 1 or 2 could be reserved for jingles to play at any time, right?
The soundtracks I've looked at usually seem to use 6 channels for music and 2 for sound effects, but there's no reason they couldn't have done voice stealing instead.
And finally, what are the parameters for NES and SNES sounds if one wanted to define and use them in a MIDI file?
You'll have to look into soundfonts for accurate playback of either of these.
User avatar
rainwarrior
Posts: 8735
Joined: Sun Jan 22, 2012 12:03 pm
Location: Canada
Contact:

Re: Questions (mainly) about SNES Audio

Post by rainwarrior »

Edit: some of my responses are redundant to lidnariq's above. Was typing at the same time.
FinalZero wrote:Apparently the Famicom has an extra 6th channel that sounds like bells? Why did this get removed from the NES ?
The extra sound was not part of the Famicom itself. It looped the audio output through the cartridge, so cartridges could put extra sound hardware inside. In Zelda's case, the FDS ram adapter has one wavetable sound channel. In Akumajou Densetsu's case, the cartridge contained the VRC6 chip which had 3 extra sound channels.

Some info here: https://wiki.nesdev.com/w/index.php/Cat ... sion_audio


The SNES could do "any" waveform, more or less; the main limitation there was RAM for storing the samples. Yes, with more channels you can reserve some to be dedicated to sound effects, though some SNES games may still interrupt music to play sound effects. (With 8 channels too, it's easier to have some less important quiet channels in the music that wouldn't be very noticeable to interrupt.) There are some NES games that dedicate channels to sound effects and do not interrupt music too (e.g. Donkey Kong).


The MIDI format doesn't directly specify sounds. I think trying to come up with a mapping of MIDI control parameters to NES sounds will ultimately require a lot of careful consideration and personal preference. There's been some attempts to control NES sound via MIDI devices, you might look into what those do.
tepples
Posts: 22708
Joined: Sun Sep 19, 2004 11:12 pm
Location: NE Indiana, USA (NTSC)
Contact:

Re: Questions (mainly) about SNES Audio

Post by tepples »

lidnariq wrote:The soundtracks I've looked at usually seem to use 6 channels for music and 2 for sound effects, but there's no reason they couldn't have done voice stealing instead.
Zoop uses lots of stealing.

Interplay's ARDI music player uses MIDI. But it's slow; turning off music in The Lord of the Rings speeds up loading. In addition, standard MIDI files are big. For a practical game, you'll want to repack your sequence data into something smaller than MIDI, usually with looping commands and less precise durations.
Oziphantom
Posts: 1565
Joined: Tue Feb 07, 2017 2:03 am

Re: Questions (mainly) about SNES Audio

Post by Oziphantom »

The SNES has no waveforms per se. It plays back BRR samples. You can use BRR samples to emulate any waveform you want, mostly. But there are no options to turn on square wave, or triangle. So basically its more like Amiga's Paula (well 2 Paulas) than the C64's SID.
User avatar
Bregalad
Posts: 8056
Joined: Fri Nov 12, 2004 2:49 pm
Location: Divonne-les-bains, France

Re: Questions (mainly) about SNES Audio

Post by Bregalad »

Oziphantom wrote:But there are no options to turn on square wave, or triangle. So basically its more like Amiga's Paula (well 2 Paulas) than the C64's SID.
There is however, an option to do white noise. It can be used on any channel, but if more than one channel uses white noise simultaneously it'll be the same white noise, so it'll only make the noise louder.
creaothceann
Posts: 611
Joined: Mon Jan 23, 2006 7:47 am
Location: Germany
Contact:

Re: Questions (mainly) about SNES Audio

Post by creaothceann »

Secret of Mana is another game with music that uses a high number of channels, possibly because it was originally designed for the SNES CD. During fights with enemies it's pretty much guaranteed to lose channels to the action.
My current setup:
Super Famicom ("2/1/3" SNS-CPU-GPM-02) → SCART → OSSC → StarTech USB3HDCAP → AmaRecTV 3.10
User avatar
Bregalad
Posts: 8056
Joined: Fri Nov 12, 2004 2:49 pm
Location: Divonne-les-bains, France

Re: Questions (mainly) about SNES Audio

Post by Bregalad »

creaothceann wrote:Secret of Mana is another game with music that uses a high number of channels, possibly because it was originally designed for the SNES CD.
Nope, all Squaresoft games that uses an engine written by Minoru Akao (that's almost all of them) uses all 8 channels for music, starting from FF4 the very first games they did for the system. Only Seiken Densetsu 3 does the standard 6/2 channel thing, but it doesn't use an engine by Akao.
During fights with enemies it's pretty much guaranteed to lose channels to the action.
It seems Secret of Mana is particuarly poor/glitchy with this, sometimes all 8 music channels are used for sound effects simultaneously and music disappears entierely for a short time.
Optiroc
Posts: 129
Joined: Thu Feb 07, 2013 1:15 am
Location: Sweden

Re: Questions (mainly) about SNES Audio

Post by Optiroc »

FinalZero wrote:I read on Wikipedia ( https://www.wikiwand.com/en/Nintendo_S-SMP#/DSP ) that the SNES has 8 voices, instead of 5. But the page doesn't explain any deeper. What waveforms are allowed? Is each voice's waveform fixed like the NES, or customizeable like the C64 ?
The Wikipedia article does a pretty good job at explaining the S-DSP functionality in a four sentence paragraph. But I guess the fact that it mixes ADPCM compressed samples could be shoehorned into the first sentence for greater clarity. Something like this:
The S-DSP is capable of producing and mixing 8 simultaneous voices at any relevant pitch and volume in 16-bit stereo at a sample rate of 32 kHz.
-> The S-DSP is capable of mixing 8 simultaneous voices of ADPCM compressed samples at any relevant pitch and volume in 16-bit stereo at an output sample rate of 32 kHz.
User avatar
FinalZero
Posts: 152
Joined: Thu Dec 03, 2009 7:27 am
Contact:

Re: Questions (mainly) about SNES Audio

Post by FinalZero »

Thanks for the answers everybody!
The MIDI format doesn't directly specify sounds.
Oh, it doesn't? Then what does define the sounds? And what does the MIDI file itself define?
possibly because it was originally designed for the SNES CD
I didn't know that! Interesting!

Btw, although I may know plenty about programming, I'm very much a newbie when it comes to music/audio in general. (I did study it in middle school long ago, so I know the basics, but not much more.) I'm interested in how composers compose songs, and how/why songs are structured the way they are. What can I do to learn such things? Is there a book on the subject that's worth reading? (Does this sounds silly? After all, if someone asking me about programming or designing a video game, I wouldn't suggest to them to read a book, but instead start programming and playing games!)
tepples
Posts: 22708
Joined: Sun Sep 19, 2004 11:12 pm
Location: NE Indiana, USA (NTSC)
Contact:

Re: Questions (mainly) about SNES Audio

Post by tepples »

The MIDI format specifies the pitch, timing, and velocity of note-on events, as well as what instruments to use (nominally from a 128-entry list), but not said instruments' exact sound.
Optiroc
Posts: 129
Joined: Thu Feb 07, 2013 1:15 am
Location: Sweden

Re: Questions (mainly) about SNES Audio

Post by Optiroc »

True, although several MIDI standards exist which also defines sounds. Many of these standards were commonly supported in games both on Japanese and western computers from the late 80s up to the mid-90s (and resulted in some pretty awesome soundtracks, too!).
Revenant
Posts: 462
Joined: Sat Apr 25, 2015 1:47 pm
Location: FL

Re: Questions (mainly) about SNES Audio

Post by Revenant »

I think the closest any MIDI standard comes to actually defining the exact sound of an instrument is GS naming one of its drum kits after a specific (very recognizable) drum machine. And even then, a lot of GS-compatible sound sets don't bother adhering to that either.
ccovell
Posts: 1045
Joined: Sun Mar 19, 2006 9:44 pm
Location: Japan
Contact:

Re: Questions (mainly) about SNES Audio

Post by ccovell »

Slightly on this topic, can somebody recommend some videos (podcasts?) that demonstrate each of the SPC/S-DSP's features in detail? I have read plenty of text documents with register maps & descriptions, but would like to hear somebody actually exercising the different ADSR, gain, DSP, filter settings individually.
Revenant
Posts: 462
Joined: Sat Apr 25, 2015 1:47 pm
Location: FL

Re: Questions (mainly) about SNES Audio

Post by Revenant »

I'm not actually aware of any that exist, but it'd be a pretty good subject to tackle for someone with the presenting skills for it.
Post Reply