home *** CD-ROM | disk | FTP | other *** search
/ Chip 2000 September / Chip_2000-09_cd1.bin / sharewar / Slunec / app / 16 / MOD.SWG / 0015_MTM.pas < prev    next >
Pascal/Delphi Source File  |  1996-09-04  |  4KB  |  85 lines

  1. --------M-MTM-------------------------------
  2.  
  3. The  MTM  format is generated by the  Multi  Track Module tracker by the
  4. demo  group  Renaissance. The tracker features  up to 32 channel digital
  5. music.  Instead  of  saving whole patterns,  the  tracker only saves the
  6. different  tracks and the data which tracks should be played together at
  7. which time, thus saving some pattern space.
  8.  
  9. OFFSET              Count TYPE   Description
  10. 0000h                   3 char   ID='MTM'
  11. 0003h                   1 byte   Version data
  12.                                    upper nibble is major version number
  13.                                    lower nibble is minor version number
  14. 0004h                  20 char   ASCIIZ song name
  15. 0018h                   1 word   Number of saved tracks.
  16.                                  ="NOT"
  17. 001Ah                   1 byte   Highest pattern number saved
  18.                                  ="NOP"
  19. 001Bh                   1 byte   Last order number to play(=Songlength-1)
  20. 001Ch                   1 word   Length of extra comment field in bytes
  21.                                  ="XSZ"
  22. 001Eh                   1 byte   Number of samples
  23.                                  ="NOS"
  24. 001Fh                   1 byte   Attribute byte (currently defined as 0)
  25. 0020h                   1 byte   Beats per track
  26. 0021h                   1 byte   Number of tracks
  27. 0022h                  32 byte   Pan positions of the voices
  28.                                  (0=left, 15=right??)
  29. 0042h               "NOS" rec    Instrument data
  30.                        22 char   Sample name
  31.                         1 dword  Sample length in bytes
  32.                         1 dword  Start of sample loop in bytes
  33.                         1 dword  End of sample loop in bytes
  34.                         1 byte   Fine tune value for sample
  35.                         1 byte   Default volume for sample
  36.                         1 byte   Attribute byte, bit mapped
  37.                                    0 0=8 bit sample,1=16 bit sample
  38.                                  1-7 undefined (set to zero)
  39. 0042h+                128 byte   Pattern order data
  40.  "NOS"*37
  41. 01C2h+
  42.  "NOS"*37           "NOT" rec    Track data
  43.                                  Each track is saved independently and has
  44.                                  the size of exactly 192 bytes. Each track
  45.                                  is arranged as 64 3-byte notes with the
  46.                                  following format :
  47.                      64*3 byte            BYTE 0   BYTE 1   BYTE 2
  48.                                          ppppppii iiiieeee aaaaaaaa
  49.                                  p = pitch value (0=no pitch stated)
  50.                                  i = instrument number (0=no instrument number)
  51.                                  e = effect number
  52.                                  a = effect argument
  53.                                  The effects are the standard Protracker
  54.                                  effects.
  55. 01C2h+       ("NOP"+1)*32 word   Track sequencing data
  56.  "NOS"*37+                       This is the list of which track is used
  57.  "NOT"*192                       as which voice in each pattern. One track
  58.                                  can be part of many patterns, the drums
  59.                                  for example.
  60.                                  Track 0 is never saved but is always
  61.                                  considered as an empty track. That means
  62.                                  that counting really starts at one.
  63.                                  The data is organized in sets of 32 voices.
  64.                                  The first word contains the information which
  65.                                  track is used in pattern 0, voice 0. The next
  66.                                  word is for pattern 0, voice 1, etc., this
  67.                                  is repeated for each pattern, 32 words for each
  68.                                  saved pattern.
  69. 01C2h+              "XSZ" char   Extra comment field. This contains some
  70.  "NOS"*37+                       message or something.
  71.  "NOT"*192+
  72.  ("NOP"+1)*32*2
  73. 01C2h+                  ? byte   Raw sample data(unsigned).
  74.  "NOS"*37+
  75.  "NOT"*192+
  76.  ("NOP"+1)*32*2+
  77.  "XSZ"
  78.  
  79. EXTENSION:MTM
  80. SEE ALSO:MOD
  81. OCCURENCES:PC
  82. PROGRAMS:MMEDIT,DMP
  83. VALIDATION:
  84.  
  85.