Advertisement
feasel

my notes on testing Fceux Audio Visualiztion for LUA

Mar 19th, 2013
75
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 3.64 KB | None | 0 0
  1. here is a LUA script that prints the contents of the sound.get() function: http://pastebin.com/2PxA9hKM
  2.  
  3. pressing P switches to compact mode (if you want to play without text covering everything).
  4.  
  5. i tried out a whole bunch of games and it was amazing to see how they utilized the hardware differently. in most games the 2 square waves are for lead and harmony, the triangle wave is bass, and the noise is percussion. the PCM channel is typically auxillary percussion (e.g. bongos) but some games use it to get a deeper bass-drum sound than the noise channel is able to produce.
  6.  
  7. Batman is interesting because it uses the PCM channel for all of its percussion (bass drum, snare, toms) except for the hihats which are the only things being done on the noise channel. it is also unique in that during drum fills it uses just a single PCM sample for the tom hits and it simply changes the frequency to get toms of different pitches.
  8.  
  9. Bayou Billy (being one of the more technologically advanced NES games, despite its badness) makes great use of the PCM. it uses PCM to play a recorded voice saying "The adventures of bayou billy". definitely check out the sound-test mode of this.
  10.  
  11. in games (like Bayou Billy) where the music uses a variety of different PCM samples you can see the dmcaddress field changing as it switches among various percussion instruments. so i make the horizontal position of the cyan line reflect the address of the sample rather than the frequency like i do with the others. for what it's worth, on all the games i tested the addresses of the PCM samples were always between C000 and FFFF.
  12.  
  13. Journey To Silius actually uses PCM to play a melody, and it pitch-bends triangle to get that cool snare drum sound as well as using triangle to do all the tom fills. pretty unique stuff.
  14.  
  15. Solstice has really interesting instrumentation for the song that plays during gameplay. the high dinging bell is actually the noise channel and the bass hits are done with some kind of descending pitch-bend on the triangle wave. Also the title song for Solstice is interesting because the beginning of it uses FM synth on the two square-wave channels (you can see their freqs oscillating like crazy).
  16.  
  17. the documentation doesn't give much detail about what the values mean, but most of them are self-explanatory. the only values i don't understand are regs.frequency, which says "raw freq register value", and dpcm.dmcseed, which just says "InitialRawDALatch". i have no idea about regs.frequency, but for dpcm.dmcseed my best guess is that it may be an offset into the PCM data that indicates where to start playing. in most games dmcseed remains at 0 and dmcaddress changes, but there are a few games where dmcaddress remains at C000 and dmcseed does all the changing. For a great example, look at the famous pause-screen music in Battletoads.
  18.  
  19. lastly, it's interesting to see what happens in a japanese game. compare the american and japanese Castlevania III. the american version is quite typical (squares = melody, triangle = bass, percussion is shared between PCM and noise channel), but the japanese version is very different. you can tell the sound.get() function is not returning any of the information about what's going on in the on-cart sound processor. you can hear that there are additional voices in the mix that are not visible to the script. for example, when you pick up a heart the two square wave channels will stop playing their usual tunes in order to play the item-pickup sound (which is FM synth) however you barely notice the interruption since there's so many other voices.
  20.  
  21. really neat stuff. i had way too much fun trying out games and watching the viz.
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement