GUI: add SNES echo filter MML string
This commit is contained in:
parent
744248016e
commit
cb34b7e1a7
|
@ -1028,7 +1028,7 @@ class FurnaceGUI {
|
|||
String workingDirVGMExport, workingDirZSMExport, workingDirROMExport, workingDirFont, workingDirColors, workingDirKeybinds;
|
||||
String workingDirLayout, workingDirROM, workingDirTest;
|
||||
String mmlString[32];
|
||||
String mmlStringW;
|
||||
String mmlStringW, mmlStringSNES;
|
||||
|
||||
std::vector<DivSystem> sysSearchResults;
|
||||
std::vector<FurnaceGUISysDef> newSongSearchResults;
|
||||
|
|
|
@ -18,7 +18,7 @@
|
|||
*/
|
||||
|
||||
#include "gui.h"
|
||||
#include <imgui.h>
|
||||
#include "misc/cpp/imgui_stdlib.h"
|
||||
|
||||
bool FurnaceGUI::drawSysConf(int chan, DivSystem type, DivConfig& flags, bool modifyOnChange) {
|
||||
bool altered=false;
|
||||
|
@ -1273,6 +1273,19 @@ bool FurnaceGUI::drawSysConf(int chan, DivSystem type, DivConfig& flags, bool mo
|
|||
} rightClickable
|
||||
}
|
||||
|
||||
ImGui::SetNextItemWidth(ImGui::GetContentRegionAvail().x); // wavetable text input size found here
|
||||
if (ImGui::InputText("##MMLWave",&mmlStringSNES)) {
|
||||
int actualData[256];
|
||||
int discardIt=0;
|
||||
memset(actualData,0,256*sizeof(int));
|
||||
decodeMMLStrW(mmlStringSNES,actualData,discardIt,-128,127,false);
|
||||
memcpy(echoFilter,actualData,8*sizeof(int));
|
||||
altered=true;
|
||||
}
|
||||
if (!ImGui::IsItemActive()) {
|
||||
encodeMMLStr(mmlStringSNES,echoFilter,8,-1,-1,false);
|
||||
}
|
||||
|
||||
if (altered) {
|
||||
e->lockSave([&]() {
|
||||
flags.set("volScaleL",127-vsL);
|
||||
|
|
Loading…
Reference in New Issue