goombas.org
menu
main
links
all items
rss feed

Topics:
coding
games
goombas.org
horror
judgement
life
minutiae
music
rants
software
fool.
 _-
 oO
 |/
/|
/ \
Ugh, stop twitching
sample ripping
software Posted 2003-12-05 22:07:40 by Jim Crawford
Today, I had the occasion to write a program, in Python, to rip samples out of .mod files and store them in the .wav format. Here is it, the real mod sample ripping program from real mod sample rippers.

The needs this program fills that the competition doesn't are two: it runs as a batch process, and it tries to guess the intended playback rate of the samples by analyzing the note information in the patterns. Every other program I tried required two or three keystrokes per sample and set the sample rate in the output to 8363hz.

Despite these killer features, I realize that the cross-section of people who need to rip samples out of a directoryful of mods and people who have Python installed is very small. Consider this code a gift to the archaeologists of future civilizations.

And since I can't leave out my contemporaries, here's a summary of the information I gleaned from the experience:

  • .wav file format: horrendous.
  • .mod file format: utterly horrendous.
  • binary file I/O in Python: surprisingly pleasant.
[link to this] [See more on “software”]

comments
python is great
Posted by Jim Crawford on 2004-08-17 17:35:21
I love this. I look at rip.py again, almost a year after writing it, and it's perfectly understandable and, quite frankly, looks like poetry. I know this is not my doing, because none of my C or Perl code has ever looked this good a year later. Hooray for Python!

... I do seem to have forgotten what that star on line 80 does, though.
add a comment
Only anonymous comments are available for now until I get the user system up and running again. Not many people were logging in anyway, so enh.
Permitted HTML tags: <b>, <i>, <u>, <tt>. Also permitted is the <q> pseudo-tag which is meant to delimit quotes from other messages.
name:
email:
subject:
body:
Preview
To prove you are sentient, please type "sentient" into this box

what's this?
This is Jim Crawford's blog. Details and contact information.

On Twitter: @mogwai_poet

recent comments
ISO 9001 Certification in Bangalore (Anonymous on eye-tracking)
3d printing services (Anonymous on troboclops - hate edge)
packers and movers vadodara (Anonymous on troboclops - hate edge)
Hoters (Anonymous on may 2014 microblog digest)
Office Installation and Setup Guide - Octa One Networks (Anonymous on may 2014 microblog digest)
QuickBooks Customer Service (Anonymous on may 2013 microblog digest)
HBR Case Study Solution (Anonymous on may 2014 microblog digest)
packers and movers (Anonymous on may 2014 microblog digest)
packers and movers (Anonymous on may 2014 microblog digest)
packers and movers (Anonymous on may 2014 microblog digest)
packers and movers (Anonymous on may 2014 microblog digest)
packers and movers (Anonymous on may 2014 microblog digest)
packers and movers (Anonymous on new smush album)
packers and movers (Anonymous on new smush album: a smush before smush began)
packers and movers (Anonymous on ds-10)
Comments RSS