From fe0dc38f37b8f5b6d57f8e1ef3930fc106798716 Mon Sep 17 00:00:00 2001 From: tildearrow Date: Sun, 30 Jan 2022 17:18:10 -0500 Subject: [PATCH] add VGM export warnings --- src/engine/engine.cpp | 5 +++++ src/gui/gui.cpp | 3 +++ 2 files changed, 8 insertions(+) diff --git a/src/engine/engine.cpp b/src/engine/engine.cpp index 9621e6cbb..37d8e0de4 100644 --- a/src/engine/engine.cpp +++ b/src/engine/engine.cpp @@ -2515,6 +2515,7 @@ SafeWriter* DivEngine::saveVGM(bool* sysToExport, bool loop) { int loopEnd=0; walkSong(loopOrder,loopRow,loopEnd); logI("loop point: %d %d\n",loopOrder,loopRow); + warnings=""; curOrder=0; freelance=false; @@ -2627,6 +2628,7 @@ SafeWriter* DivEngine::saveVGM(bool* sysToExport, bool loop) { willExport[i]=true; hasOPN2|=0x40000000; howManyChips++; + addWarning("adding a compound system two times is experimental!"); } if (!hasSN) { hasSN=3579545; @@ -2636,6 +2638,7 @@ SafeWriter* DivEngine::saveVGM(bool* sysToExport, bool loop) { willExport[i]=true; hasSN|=0x40000000; howManyChips++; + addWarning("adding a compound system two times is experimental!"); } break; case DIV_SYSTEM_SMS: @@ -2693,6 +2696,7 @@ SafeWriter* DivEngine::saveVGM(bool* sysToExport, bool loop) { willExport[i]=true; hasOPM|=0x40000000; howManyChips++; + addWarning("adding a compound system two times is experimental!"); } if (!hasSegaPCM) { hasSegaPCM=4000000; @@ -2703,6 +2707,7 @@ SafeWriter* DivEngine::saveVGM(bool* sysToExport, bool loop) { willExport[i]=true; hasSegaPCM|=0x40000000; howManyChips++; + addWarning("adding a compound system two times is experimental!"); } break; case DIV_SYSTEM_YM2610: diff --git a/src/gui/gui.cpp b/src/gui/gui.cpp index 30c098c2a..f7ad18820 100644 --- a/src/gui/gui.cpp +++ b/src/gui/gui.cpp @@ -5043,6 +5043,9 @@ bool FurnaceGUI::loop() { } w->finish(); delete w; + if (!e->getWarnings().empty()) { + showWarning(e->getWarnings(),GUI_WARN_GENERIC); + } } else { showError("could not write VGM. dang it."); }