Music File format (.tmu)

From TriloTracker
Jump to: navigation, search
+1        Version ('6') (lower 4 bits format version, upper 4 bits TT chipsetup)
+32       Song name
+32       Song creator
+1        Speed
+1        Order restart position
+1        Order length
+<length> Order list
+496      Instrument names (31*16)
+<??>     Instrument macro's (31*<variable length>)
             +1          Macro length
             +1          Restart position
             +1          Macro waveform
             +<length*4> Macro data
+1024     Waveforms (32*32)   < ONLY FOR PSG+SCC >
+??       DrumMacros (x)      [ ONLY FOR PSG+FM and SN+FM ]
+??       Custom Voices (x)   [ ONLY FOR PSG+FM and SN+FM ]
+<??>     Patterns (compressed)
             +1        pattern number
             +2        length
             +<length> compressed data
+1        255 - end delimiter


Version chipsetup:
0000xxxx  PSG + SCC
0001xxxx  PSG + FM
0011xxxx  SN  + FM
1000xxxx  PSG/SN/EPSG


Compressed pattern example.

Below is an example of a compressed pattern.

TTCOMPRESSEDPATTERN.PNG

Blue = pattern number (FF means en of pattern data).
Red = length (number of bytes of compressed data folowing).
Green = compressed data. (00,06 represents 00,00,00,00,00,00 (6 times 00)).
Pink = end of compressed data for this pattern (00,00 is a delimiter).