As promissed, I'll be releasing some of my partly-done projects on this forum. This is the first (and probably most interresting) one: Skratz.
This is a DJ console complete with MP3 loading and some hidden treasures inside. It's also largely broken. Core functionality works, but a lot of things are either buggy or plain don't work.
Essentially, this code has been lying untouched on my harddisk for nearly two years and I've only patched up some minor things over the last couple of days.
First things first;
It's licensed with GPL 3.0. If you distribute (changed) copies, you MUST include your schematic file without limitations.
And here are the files:
Unzip the skratz.zip file in "E:/Skratz" (or change the path in the schematic accordingly; one level down inside the "Constants" module). It contains two .exe files;
- mpg123.exe - The latest binary distribution of this: http://www.mpg123.de/
- vanderlee.exe - Provides services such as directory information and MP3 ID3tag decoding. Don't change the filename or it won't work.
Using it
Go play with it. Loading an MP3 takes quite a bit of time (~20-30 seconds). This is purely the fault of lack of native MP3 support; the mpg123 decoder is fast, but it has to write some 10MB per minute of audio to the harddisk, and the schematic has to load it in afterwards. With builtin MP3 support, both these long delays would be eliminated. It still wouldn't be ideal, but it'd be a lot faster.
Interresting stuff
There are too many interresting bits to mention, so I'll just name a few:
- MP3 loading
- MP3 ID3 tag loading using external executable. Reads all current ID3 specs, but chops UTF-8 characters.
- The wave preview uses a custom method to hilight the average amplitude over time instead.
- There's a nice hi/mid/lo filter in there. It's not ideal (I'm no expert in filters) but it should be perfect when everything is set to 100%
- Leave the BassBoost at 0%; it's horrible

- Nice VU meters.
- A completely unused file-browser. It was supposed to enable browsing for files without a popup and it's modal issues. The file browser works fine but I never got around to linking it to the rest of the schematic.
- The spinning discs use a lot of view caching to achieve good performance. It also have a nice effect where it shows the tracks' "intensity" using dark/bright colors.
- The spinning discs can be manually controlled. Currently they are in a sort of hybrid-CD/Vinyl mode where some actions are immediate and some have a "motor"-delay. Manually controlling the discs is somewhat inaccurate, thanks to S|M's lack of accurate timing in green (millisecond accuracy is not good enough). I've tried to be as accurate as possible, but to no avail.
- A pretty pathetic BPM counter. If you use a monotonic house tracks, it's quite accurate. If you have something more varied, it breaks down.
- It should work fine with a MIDI DJ console, but you may have to dig in the schematic to set the right control numbers
Perhaps it'd make a nice community project. Though without builtin MP3 support, this project is pretty much doomed from the start.

















