blob: 6e41a85d23796ee335423484617f6b1c3cebbdc7 [file] [log] [blame]
Stepan Moskovchenko215e4922005-04-15 06:08:55 +00001/***************************************************************************
2 * __________ __ ___.
3 * Open \______ \ ____ ____ | | _\_ |__ _______ ___
4 * Source | _// _ \_/ ___\| |/ /| __ \ / _ \ \/ /
5 * Jukebox | | ( <_> ) \___| < | \_\ ( <_> > < <
6 * Firmware |____|_ /\____/ \___ >__|_ \|___ /\____/__/\_ \
7 * \/ \/ \/ \/ \/
8 *
9 * Copyright (C) 2005 Stepan Moskovchenko
10 *
11 * All files in this archive are subject to the GNU General Public License.
12 * See the file COPYING in the source tree root for full license agreement.
13 *
14 * This software is distributed on an "AS IS" basis, WITHOUT WARRANTY OF ANY
15 * KIND, either express or implied.
16 *
17 ****************************************************************************/
18
19//This came from one of the Gravis documents
Stepan Moskovchenko58112142005-04-15 20:27:04 +000020static const unsigned int gustable[]=
Stepan Moskovchenko215e4922005-04-15 06:08:55 +000021{
22 8175, 8661, 9177, 9722, 10300, 10913, 11562, 12249, 12978, 13750, 14567, 15433,
23 16351, 17323, 18354, 19445, 20601, 21826, 23124, 24499, 25956, 27500, 29135, 30867,
24 32703, 34647, 36708, 38890, 41203, 43653, 46249, 48999, 51913, 54999, 58270, 61735,
25 65406, 69295, 73416, 77781, 82406, 87306, 92498, 97998, 103826, 109999, 116540, 123470,
26 130812, 138591, 146832, 155563, 164813, 174614, 184997, 195997, 207652, 219999, 233081, 246941,
27 261625, 277182, 293664, 311126, 329627, 349228, 369994, 391995, 415304, 440000, 466163, 493883,
28 523251, 554365, 587329, 622254, 659255, 698456, 739989, 783991, 830609, 880000, 932328, 987767,
29 1046503, 1108731, 1174660, 1244509, 1318511, 1396914, 1479979, 1567983, 1661220, 1760002, 1864657, 1975536,
30 2093007, 2217464, 2349321, 2489019, 2637024, 2793830, 2959960, 3135968, 3322443, 3520006, 3729316, 3951073,
31 4186073, 4434930, 4698645, 4978041, 5274051, 5587663, 5919922, 6271939, 6644889, 7040015, 7458636, 7902150
32};
33
34struct GWaveform
35{
36 unsigned char * name;
37 unsigned char fractions;
38 unsigned int wavSize;
Stepan Moskovchenko1f5fb992005-04-19 15:57:07 +000039 unsigned int numSamples;
Stepan Moskovchenko215e4922005-04-15 06:08:55 +000040 unsigned int startLoop;
41 unsigned int endLoop;
42 unsigned int sampRate;
43 unsigned int lowFreq;
44 unsigned int highFreq;
45 unsigned int rootFreq;
46 unsigned int tune;
47 unsigned int balance;
48 unsigned char * envRate;
49 unsigned char * envOffset;
50
51 unsigned char tremSweep;
52 unsigned char tremRate;
53 unsigned char tremDepth;
54 unsigned char vibSweep;
55 unsigned char vibRate;
56 unsigned char vibDepth;
57 unsigned char mode;
58
59 unsigned int scaleFreq;
60 unsigned int scaleFactor;
61
62 unsigned char * res;
63 signed char * data;
64};
65
66
67struct GPatch
68{
69 unsigned int patchNumber;
70 unsigned char * header;
71 unsigned char * gravisid;
72 unsigned char * desc;
73 unsigned char inst, voc, chan;
74 unsigned int numWaveforms;
75 unsigned int datSize;
76 unsigned int vol;
77 unsigned char * res;
78
79
80 unsigned int instrID;
81 unsigned char * instrName;
82 unsigned int instrSize;
83 unsigned int layers;
84 unsigned char * instrRes;
85
86 unsigned char layerDup;
87 unsigned char layerID;
88 unsigned int layerSize;
89 unsigned char numWaves;
90 unsigned char * layerRes;
91
92 unsigned char noteTable[128];
93 struct GWaveform * waveforms[255];
94};
95