You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
|
|
|
|
|
|
|
void setSample(int sample, int step) {
|
|
|
|
if(setErease) {
|
|
|
|
for(int i=0; i<matrix[1]; i++) {
|
|
|
|
pattern[sample-1][i] = 0;
|
|
|
|
}
|
|
|
|
setErease = false;
|
|
|
|
|
|
|
|
} else if(selectPattern) {
|
|
|
|
|
|
|
|
loadPattern(sample);
|
|
|
|
selectPattern = false;
|
|
|
|
|
|
|
|
} else if(selectBank) {
|
|
|
|
|
|
|
|
loadBank(sample);
|
|
|
|
selectBank = false;
|
|
|
|
|
|
|
|
} else {
|
|
|
|
|
|
|
|
pattern[sample-1][step-1] = 1;
|
|
|
|
for(int i=0; i<matrix[0]; i++) {
|
|
|
|
for(int y=0; y<matrix[1]; y++) {
|
|
|
|
printf("%d ", pattern[i][y]);
|
|
|
|
}
|
|
|
|
printf("\n");
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|