Offline
Chicago IL

I'm kind of interested in trying to make a chip tracker, but I have no idea where to start (googling creating/coding a music tracker mostly results in "how to create/code music using a tracker program"), I figured there were at least a couple people here that could point me in the right direction.

i don't want to give too much away incase i actually manage to make this thing, but: i'm not looking to make a console native tracker, or even a windows tracker that exports to a file format (at least not yet), so that might help with getting started.

thanks in advance

Offline
Nomad's Land

i have yet to find a good manual/tutorial for that - so i'd welcome some pointers, too.

got one for you: maybe you'd want to have a look at the source code for shiru's 1tracker - http://shiru.untergrund.net/files/src/1tracker_src.zip

it's for windows though, haven't got it to build on linux yet, though some people supposedly have http://shiru.untergrund.net/1bit/pivot/ … d=194#comm

good luck xD

Offline
Earth

Oooh, interesting topic.  Famitracker is open source too. Are you making a synthesizer or just a sampler?

Offline
Chicago IL

Both

Offline
Buenos Aires, Argentina

Personal opinion:

A tracker don't have any specials stuff to code, for that reason you will never find a "programming a tracker tutorial" as you find "programming a platform game".
You have to learn how to output sound, how to make a button, how to capture the keyboard and the sum of that could be a tracker if your knowledge was correctly acquired.

Personally I learned how to make all of that stuff in different things that I did in the past (dOb Engine, Brilek, NES programming, Amiga programming, blah, blah, etc, etc, etc), then programming DefleMask was only start to code it.

So, for short I recommend you to start coding simple apps: output a sine wave, create buttons, etc, etc. After that a tracker could pop up at anytime.

Offline
Milwaukee, WI

I'd be interested to hear more opinions on this too.  I've got an alright background in Java and I don't really see how to make the jump to programming for sound.

Offline
Russia, Moscow

A tracker is basically consist two very different parts: UI, which is normally a larger one, and sound code. They aren't overlap too much, so you may start to learn how to do them separately, then combine them into one fully functional thing.

Sound part takes data in some format, interprets it, then plays somehow, sort of through virtial low level commands. If it is a cross tracker, it produces register data for emulated chip, if it is a sample based one, it produced commands like start sample, stop, change channel pitch, change volume. In my opinion, easiest way to learn how to make sound part for a cross tracker is to write a simple VGM format player, the one that is for Sega Master System - the format is very simple, the chip is very simple, so you can easily write your own emulator, and get all kinds of ideas how the stuff work.

UI part of a tracker is kind of specialized text editor that implies certain limitations on the input. You may make one that will just produce a text file formated in certain way. You may start from a N-column editor that allows to enter numbers into each column, navigate, copy/paste, etc.

Offline
france

Ok guys, I had some of the same question last years and I have dig the Internet for you wink

For me the best way to start was reading some simple code and try to understand them.
One that was really helpfull was taken here : http://olofson.net/mixed.html
DT42 is a drum tracker which work with 3000 line of C using sdl.
It is not easy and well written but it contain :
- a nice sdl GUI ;
- a load save function ;
- a structure to store the song ;
- sample instrument : just trig ;
- a really basic synth  but well written and great to understand ;

There is also a minimal version without the GUI which take 1000 line of C, it's a strip down version of DT42. This guy has done a really good tutorial for anyone IMHO.

If you plan to write a tracker I think you should learn how to write  :
- a waveform generator ;
- a minimal sound mixer ;
- a pattern player with an audio engine ;

I'm not an expert in this area, I just begin to code a minimal player.
It play wave but the audio engine is not really perfect.

it's well written I think but I am a noob in waveform generation so i get broken c++ code.
It works I can generate sawtooth wave smile and I enjoy it.
I can't get a decent sine wave, i don't understand the full stuff...

Good to see there are people out there which write code, i enjoy this smile

And hope this will help you to begin.

Johann

Offline
Abandoned on Fire

What about using Pure Data or Max? Not lightweight enough or ...? I believe both of those have options to export as a standalone application. Might be a way to jumpstart your progress at least.

Offline
Earth
egr wrote:

What about using Pure Data or Max? Not lightweight enough or ...? I believe both of those have options to export as a standalone application. Might be a way to jumpstart your progress at least.

It would certainly work for the sound engine. I believe that libpd let's you embed PD patches in executable files. Its still a bit experimental. In the long run it may be better just to learn how to do it yourself.

Offline
Sweden

Not exactly a tracker, but I have some barely readable code for a sequencer/fm synth with a JACK backend and a Curses frontend here.

Offline
Holland

Milky is opensource. You could learn references and structure and try some of your own.

Offline
London

coding maxYMiser was a big struggle. all the GUI/editing feature coding etc was very dull. it took more a less a year of all my spare time to write the first version.

at the time i regretted spending so much effort, but now i don't see it that way and am very happy with the results. i would definitely encourage anyone to write a tracker! but it is more work than it may se.

Offline
uhajdafdfdfa

if you want to make one for an old system it is pretty much imperative that you learn assembly language for that system

if you want to make one for modern PCs then C or C++ is probably most appropriate. it takes quite a while to learn how to program if you have never done it before (and "making a tracker" isnt really a suitable beginners project sadly sad )


edit: if you want to do PC i think the best library to use should be SDL... milkytracker, schismtracker, piggy, etc all use it and it handles everything you really need for sound and graphics on windows/linux/mac/more, it is a C library (will work with C++): http://www.libsdl.org/

Last edited by ant1 (Jan 6, 2013 10:44 pm)

Offline

In my experience, if you've never written a sound driver before write that first.   Either way, writing the driver first is the best idea because everything you'll want the UI to read/write can be got working in source, before you even start on the front-end.   Coding a tracker is 95% ui and 5% driver (like the old "1% inspiration and 99% perspiration").  You might end up writing the driver, be happy enough editing music in the source and not even get to the UI part.  (that's how most of mine have turned out at least)

Failing that, adapting an existing driver with a friendlier interface could be a happy exercise.  There are plenty of those around on the c64, for example.

Last edited by 4mat (Jan 6, 2013 11:00 pm)