1 /****************************************************************************
3 * ____ ___ ____ __ ______ ___ ____ ____/ / *
4 * / __ `__ \/ __ `/ |/ / __ `__ \/ __ \/ __ / *
5 * / / / / / / /_/ /> </ / / / / / /_/ / /_/ / *
6 * /_/ /_/ /_/\__,_/_/|_/_/ /_/ /_/\____/\__,_/ *
8 * Copyright (c) 2008, Mukunda Johnson (mukunda@maxmod.org) *
10 * Permission to use, copy, modify, and/or distribute this software for any *
11 * purpose with or without fee is hereby granted, provided that the above *
12 * copyright notice and this permission notice appear in all copies. *
14 * THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES *
15 * WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF *
16 * MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR *
17 * ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES *
18 * WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN *
19 * ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF *
20 * OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. *
21 ****************************************************************************/
23 .ifndef MP_FORMAT_MAS_INC
24 .equ MP_FORMAT_MAS_INC, 1
26 @ MAS header structure..................................
37 .equ C_MAS_CHANVOL ,12
38 .equ C_MAS_CHANPAN ,44
40 .equ C_MAS_TABLES ,276
47 ///////.equ C_FLAGS_LS ,5 HUH???
50 .equ C_FLAGS_X, (1<<3)
52 @ instrument struct.....................................
55 .equ C_MASI_RANDVOL ,2
58 .equ C_MASI_ENVFLAGS ,5
62 .equ C_MASI_ENVELOPES,12
63 //.equ C_MASI_ENVELOPES,248
66 .equ C_MASIE_LSTART ,1
68 .equ C_MASIE_SSTART ,3
71 .equ C_MASIE_FILTER ,6
74 .EQU ENVFLAG_A, 0b1000
76 @ sample structure......................................
88 @ pattern structure.....................................
92 @ sample structure......................................
95 .equ C_SAMPLE_POINT ,12
96 .equ C_SAMPLE_DATA ,16
98 .equ C_SAMPLEN_LSTART,0
100 .equ C_SAMPLEN_FORMAT,8
101 .equ C_SAMPLEN_REP ,9
102 .equ C_SAMPLEN_POINT ,12
103 .equ C_SAMPLEN_DATA ,16
105 .equ C_SAMPLEC_DFREQ ,10