mirror of https://github.com/PrimeDecomp/prime.git
Minor cleanup and fixes
Former-commit-id: 2d4311121544fbd21f45b051375d299f162a9482
This commit is contained in:
parent
092ae46a4c
commit
1fbb29656c
|
@ -292,7 +292,7 @@ u16 inpGetMidiCtrl(u8 ctrl, u8 channel, u8 set) {
|
||||||
return midi_ctrl[set][channel][ctrl & 0xfe] << 7 |
|
return midi_ctrl[set][channel][ctrl & 0xfe] << 7 |
|
||||||
midi_ctrl[set][channel][(ctrl & 0xfe) + 1];
|
midi_ctrl[set][channel][(ctrl & 0xfe) + 1];
|
||||||
} else {
|
} else {
|
||||||
return (u16)midi_ctrl[set][channel][ctrl] << 7;
|
return midi_ctrl[set][channel][ctrl] << 7;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
|
@ -308,7 +308,7 @@ u16 inpGetMidiCtrl(u8 ctrl, u8 channel, u8 set) {
|
||||||
} else if ((ctrl == 0x84) || (ctrl == 0x85)) {
|
} else if ((ctrl == 0x84) || (ctrl == 0x85)) {
|
||||||
return fx_ctrl[channel][ctrl & 0xfe] << 7 | fx_ctrl[channel][(ctrl & 0xfe) + 1];
|
return fx_ctrl[channel][ctrl & 0xfe] << 7 | fx_ctrl[channel][(ctrl & 0xfe) + 1];
|
||||||
} else {
|
} else {
|
||||||
return (u16)fx_ctrl[channel][ctrl] << 7;
|
return fx_ctrl[channel][ctrl] << 7;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -331,15 +331,14 @@ void inpResetChannelDefaults(u8 midi, u8 midiSet) {
|
||||||
channelDefaults->pbRange = 2;
|
channelDefaults->pbRange = 2;
|
||||||
}
|
}
|
||||||
|
|
||||||
void inpAddCtrl(CTRL_DEST* dest, u8 ctrl, long scale, u8 comb, u32 isVar) {
|
void inpAddCtrl(CTRL_DEST* dest, u8 ctrl, s32 scale, u8 comb, u32 isVar) {
|
||||||
u8 n; // r30
|
u8 n; // r30
|
||||||
if (comb == 0) {
|
if (comb == 0) {
|
||||||
dest->numSource = 0;
|
dest->numSource = 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (dest->numSource < 4) {
|
if (dest->numSource < 4) {
|
||||||
n = dest->numSource;
|
n = dest->numSource++;
|
||||||
dest->numSource = n + 1;
|
|
||||||
if (isVar == 0) {
|
if (isVar == 0) {
|
||||||
ctrl = inpTranslateExCtrl(ctrl);
|
ctrl = inpTranslateExCtrl(ctrl);
|
||||||
} else {
|
} else {
|
||||||
|
|
Loading…
Reference in New Issue