int period = 64;
int cycles = 100 * 440;
short[] data = new short[cycles * period];
int a;
int period4 = period / 4;
for (a = 0; a < period4; a++){
data[a] = 32767 * a / period4;
data[period4 + a] = 32767 - data[a];
data[2 * period4 + a] = -data[a];
data[3 * period4 + a] = -32767 + data[a];
}
for (a = 1; a < cycles; a++){
// ここでつまずいています
}
short[] data = new short[cycles * period];
int a;
int period4 = period / 4;
for (a = 0; a < period4; a++){
data[a] = 32767 * a / period4;
data[period4 + a] = 32767 - data[a];
data[2 * period4 + a] = -data[a];
data[3 * period4 + a] = -32767 + data[a];
}
for (a = 1; a < cycles; a++){
// ここでつまずいています
}