/*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* under the terms of the GNU General Public License version 2 only, as
* published by the Free Software Foundation. Oracle designates this
* particular file as subject to the "Classpath" exception as provided
* by Oracle in the LICENSE file that accompanied this code.
*
* This code is distributed in the hope that it will be useful, but WITHOUT
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
* version 2 for more details (a copy is included in the LICENSE file that
* accompanied this code).
*
* You should have received a copy of the GNU General Public License version
* 2 along with this work; if not, write to the Free Software Foundation,
* Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
*
* Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
* or visit www.oracle.com if you need additional information or have any
* questions.
*/
/**
* A tuning program container, for use with MIDI Tuning.
* See: http://www.midi.org
*
* @author Karl Helgason
*/
public final class SoftTuning {
public SoftTuning() {
name = "12-TET";
tuning[i] = i * 100;
}
tuning[i] = i * 100;
}
name = "12-TET";
tuning[i] = i * 100;
}
tuning[i] = i * 100;
}
x = x ^ (data[i] & 0xFF);
}
/*
private boolean checksumOK2(byte[] data) {
int x = data[1] & 0xFF; // 7E
x = x ^ (data[2] & 0xFF); // <device ID>
x = x ^ (data[4] & 0xFF); // nn
x = x ^ (data[5] & 0xFF); // tt
for (int i = 22; i < data.length - 2; i++)
x = x ^ (data[i] & 0xFF);
return (data[data.length - 2] & 0xFF) == (x & 127);
}
*/
// Universal Non-Real-Time / Real-Time SysEx
switch (subid1) {
case 0x08: // MIDI Tuning Standard
switch (subid2) {
case 0x01: // BULK TUNING DUMP (NON-REAL-TIME)
{
//if (!checksumOK2(data))
// break;
try {
} catch (UnsupportedEncodingException e) {
}
int r = 22;
for (int i = 0; i < 128; i++) {
tuning[i] = 100.0 *
}
break;
}
case 0x02: // SINGLE NOTE TUNING CHANGE (REAL-TIME)
{
int r = 7;
for (int i = 0; i < ll; i++) {
}
break;
}
case 0x04: // KEY-BASED TUNING DUMP (NON-REAL-TIME)
{
if (!checksumOK(data))
break;
try {
} catch (UnsupportedEncodingException e) {
}
int r = 23;
for (int i = 0; i < 128; i++) {
}
break;
}
// (NON-REAL-TIME)
{
if (!checksumOK(data))
break;
try {
} catch (UnsupportedEncodingException e) {
}
int[] octave_tuning = new int[12];
for (int i = 0; i < 12; i++)
break;
}
// (NON-REAL-TIME)
{
if (!checksumOK(data))
break;
try {
} catch (UnsupportedEncodingException e) {
}
double[] octave_tuning = new double[12];
for (int i = 0; i < 12; i++) {
}
break;
}
case 0x07: // SINGLE NOTE TUNING CHANGE (NON
int r = 8;
for (int i = 0; i < ll; i++) {
}
break;
{
int[] octave_tuning = new int[12];
for (int i = 0; i < 12; i++)
break;
}
{
double[] octave_tuning = new double[12];
for (int i = 0; i < 12; i++) {
}
break;
}
default:
break;
}
}
}
}
// am: getTuning(int) is more effective.
// currently getTuning() is used only by tests
public double[] getTuning() {
}
return tuning[noteNumber];
}
return patch;
}
return name;
}
}
}