Muryan

psxdmh

Version 2.1.1

psxdmh (PlayStation Doom Music Hack) is a command line tool to extract music and sound effects from the PlayStation versions of the Doom and Final Doom games. While psxdmh strives for authenticity in the extraction process, it also allows for some enhancement to improve the quality of the audio.

Pre–built executables are available for macOS and Windows, along with the full source code under the GPL v3 license. There’s also a collection of music in MP3 format generated by psxdmh in case you’re more interested in listening to it than extracting your own.

The PlayStation versions of the Doom games had brilliant background music (composed by Aubrey Hodges), and I was sorely disappointed when I couldn’t find it on the game CDs. After some investigation, I figured out that the music was generated dynamically by a MIDI–style player from sound samples and song definitions in the game’s data files. The difficult part was that it used an undocumented custom format.

So I spent many happy lunch hours in the gardens near work analysing hex dumps of the data files. Gradually I figured out how the data was organized within the files, and began writing psxdmh to help with the analysis. The next stage in its evolution was to add the ability to play the music. This took a lot of work before it generated high–quality output, and along the way I learned far more about audio processing than I ever imagined I would.

Note: psxdmh requires data files from the original PlayStation Doom or Final Doom game CDs to work. The Final Doom CD is preferable as it contains the data for all 30 songs, whereas the Doom CD only has the data for the first 20 songs.

Requirements

  • macOS 10.8 or later.
  • Windows XP or later.
  • Original PlayStation Doom or Final Doom game CD.

Downloads

Sample Music

D01: Hangar
D08: Phobos Anomaly
D16: Hell Gate

Doom Final Doom

Release Notes

  • Version 2.1.1 — 4th October 2021
    • Changed how time is measured (only used to show extraction speed).
    • As this doesn’affect how the music is extracted, the music ZIPs are unchanged.
  • Version 2.1.0 — 25th September 2021
    • This release is a complete rewrite of psxdmh with a focus on improving both audio quality and performance.
    • The source code is now available on GitHub.
    • Audio quality improvements:
      • Changed how filtering is applied to patches during resampling to improve sound quality.
      • Fine tuning is now read from the WMD file and applied to the instruments.
      • Changed pan to be linear to match the how player in Doom works.
      • Changed the algorithm used by the reverb unit (Nocash). The old algorithm had at least one fault.
      • The input to reverb is filtered to remove excessive high-frequency sounds which were often emphasized unpleasantly.
      • The ADSR envelope now uses a better algorithm (Nocash), and has smoothing applied.
      • Widened the default high- and low-pass filter settings.
    • Command line option changes:
      • Added --stereo-expansion to widen the positioning of instruments.
      • The --sample-rate option now applies to patches.
      • The --magic-fix option has become --repair-patches, and its effect has been refined.
      • Removed the --boost option. It wasn’t particularly useful, and didn’t sound great.
    • Miscellaneous changes:
      • The code now makes better use of C++ features (no more manual memory management, for example).
      • Added default names for extracted sound effects.
      • Added the "half-echo" reverb setting.
      • The pack-data action no longer de-duplicates the patches in the LCD file, meaning the patch numbers will match the original data files.
      • Song extraction in verbose mode shows the number of SPU channels used.
      • Song dumps flag where the SPU frequency limit is being exceeded.
      • Verbose mode WMD and song dumps break out the ADSR values.
      • The Windows build now suppresses progress messages when output isn’t going to a terminal (macOS already did this).
      • Upgraded the Windows project to Visual Studio 2019.
      • Fixed a few small bugs.
      • …and many, many more changes!
  • Version 2.0.0 — 25th July 2016
    • Initial public release.