http://bisqwit.iki.fi/src/fceu-bisqwit-blargg-sound-improvement-patch.txt
http://bisqwit.iki.fi/src/fceu-bisqwit-blargg-sound-improvement-patch2.txt
This source code patch, applied to FCEU source code, adds support for Blargg's
Game Music Emu.
More precisely, it replaces the sound engine in FCEU with Blargg's sound engine, which in my opinion produces a lot better quality sound than the one in FCEU.
It does it using the same principle as the "fake mute workaround" patch in snes9x, i.e. it pretends different things to the game than what is actually happening. This ensures maximum sync compatibility with existing movies, while best sound is produced.
I am recommending this to all those who make AVIs of NES movies on this site.
Note: This patch is not (yet) savestate robust. Using savestates in conjunction with this patch will produce wrong sounds. This has no effect to movie sync or the end product, but it may annoy those who make the movies, so it should only be used by AVI encoders.
Comparisons:
Zelda II:
https://files.tasvideos.org/bisqwit/nes_sound_comp/f-zelda2.mp3 -- FCEU
https://files.tasvideos.org/bisqwit/nes_sound_comp/b-zelda2.mp3 -- Blargg
Gimmick!:
https://files.tasvideos.org/bisqwit/nes_sound_comp/f-gimmick.mp3 -- FCEU
https://files.tasvideos.org/bisqwit/nes_sound_comp/b-gimmick.mp3 -- Blargg
Blaster Master:
https://files.tasvideos.org/bisqwit/nes_sound_comp/f-blasmast.mp3 -- FCEU
https://files.tasvideos.org/bisqwit/nes_sound_comp/b-blasmast.mp3 -- Blargg
Super Mario Bros:
https://files.tasvideos.org/bisqwit/nes_sound_comp/f-smb1a.mp3 -- FCEU
https://files.tasvideos.org/bisqwit/nes_sound_comp/b-smb1a.mp3 -- Blargg
Akumajou Densetsu (Castlevania III):
https://files.tasvideos.org/bisqwit/nes_sound_comp/f-akuden.mp3 -- FCEU
https://files.tasvideos.org/bisqwit/nes_sound_comp/b-akuden.mp3 -- Blargg
Kirby's Adventure:
https://files.tasvideos.org/bisqwit/nes_sound_comp/f-kirbyu.mp3 -- FCEU
https://files.tasvideos.org/bisqwit/nes_sound_comp/b-kirbyu.mp3 -- Blargg
Besides the ~7 dB volume difference, one difference I can spot easily is that Blargg's patch efficiently removes coarse noise that comes from digital sampling of the input sound. Something to do with Nyquist frequencies. The vibratoes are also more accurate, and the relative volumes of different mixing units are more pleasant.
The MP3 files are encoded using "mode=3:preset=50:aq=1" lameopts in mencoder, with 48000 Hz input. This is the setup used for most of the AVI encodings of NES movies on this site by me.
EDIT: I updated the patch to use updated version of Blargg's lib. However, it is largely untested so far (whereas the previous version has been used in tens of publications already), so use at your own risk :)