MIDI output improvements

This commit is contained in:
tildearrow 2022-09-26 01:27:36 -05:00
parent c27c650c11
commit 122694d7c9
5 changed files with 117 additions and 47 deletions

View file

@ -1195,6 +1195,8 @@ class FurnaceGUI {
int channelFeedbackStyle;
int channelFont;
int channelTextCenter;
int midiOutClock;
int midiOutMode;
int maxRecentFile;
unsigned int maxUndoSteps;
String mainFontPath;
@ -1318,6 +1320,8 @@ class FurnaceGUI {
channelFeedbackStyle(1),
channelFont(1),
channelTextCenter(1),
midiOutClock(0),
midiOutMode(1),
maxRecentFile(10),
maxUndoSteps(100),
mainFontPath(""),

View file

@ -955,6 +955,26 @@ void FurnaceGUI::drawSettings() {
ImGui::EndTable();
}
ImGui::TreePop();
}
if (ImGui::TreeNode("MIDI output settings")) {
ImGui::Text("Output mode:");
if (ImGui::RadioButton("Off (use for TX81Z)",settings.midiOutMode==0)) {
settings.midiOutMode=0;
}
if (ImGui::RadioButton("Melodic",settings.midiOutMode==1)) {
settings.midiOutMode=1;
}
/*
if (ImGui::RadioButton("Light Show (use for Launchpad)",settings.midiOutMode==2)) {
settings.midiOutMode=2;
}*/
bool midiOutClockB=settings.midiOutClock;
if (ImGui::Checkbox("Send MIDI clock",&midiOutClockB)) {
settings.midiOutClock=midiOutClockB;
}
ImGui::TreePop();
}
}
@ -2314,6 +2334,8 @@ void FurnaceGUI::syncSettings() {
settings.channelFont=e->getConfInt("channelFont",1);
settings.channelTextCenter=e->getConfInt("channelTextCenter",1);
settings.maxRecentFile=e->getConfInt("maxRecentFile",10);
settings.midiOutClock=e->getConfInt("midiOutClock",0);
settings.midiOutMode=e->getConfInt("midiOutMode",1);
clampSetting(settings.mainFontSize,2,96);
clampSetting(settings.patFontSize,2,96);
@ -2415,6 +2437,8 @@ void FurnaceGUI::syncSettings() {
clampSetting(settings.channelFont,0,1);
clampSetting(settings.channelTextCenter,0,1);
clampSetting(settings.maxRecentFile,0,30);
clampSetting(settings.midiOutClock,0,1);
clampSetting(settings.midiOutMode,0,2);
settings.initialSys=e->decodeSysDesc(e->getConfString("initialSys",""));
if (settings.initialSys.size()<4) {
@ -2572,6 +2596,8 @@ void FurnaceGUI::commitSettings() {
e->setConf("channelFont",settings.channelFont);
e->setConf("channelTextCenter",settings.channelTextCenter);
e->setConf("maxRecentFile",settings.maxRecentFile);
e->setConf("midiOutClock",settings.midiOutClock);
e->setConf("midiOutMode",settings.midiOutMode);
// colors
for (int i=0; i<GUI_COLOR_MAX; i++) {