[SCM] yoshimi/master: New upstream version 1.5.4.1

mira-guest at users.alioth.debian.org mira-guest at users.alioth.debian.org
Tue Oct 17 07:30:04 UTC 2017


The following commit has been merged in the master branch:
commit 0d7b89bcec4f41db88f208ea909c9692ad19f3f8
Author: Jaromír Mikeš <mira.mikes at seznam.cz>
Date:   Mon Oct 16 23:45:29 2017 +0200

    New upstream version 1.5.4.1

diff --git a/.gitattributes b/.gitattributes
new file mode 100644
index 0000000..8068397
--- /dev/null
+++ b/.gitattributes
@@ -0,0 +1,2 @@
+/src/Splash/SplashPngHex -diff
+/src/Splash/splash_screen.h -diff
diff --git a/Changelog b/Changelog
index b68c22b..1baaba8 100644
--- a/Changelog
+++ b/Changelog
@@ -1,4 +1,19 @@
-yoshimi 1.5.4
+yoshimi 1.5.4.1
+
+2017-10-16 Will
+* Finalised and cleaned up bugfix code.
+* Rationalised GUI updates (only one Fl::check() call).
+* set as V 1.5.4.1 release.
+
+2017-10-14 Will
+* Bugfix: Main part controls were responding to all
+  remote input channels but upper panel rows weren't.
+* set as V 1.5.4.1 rc2
+
+2017-10-13 Will
+* BugFix: Instrument loading now synchronised.
+* CLI enable/disable now updates panel.
+* set as V 1.5.4.1 rc1
 
 2017-9-27 Will
 * Merged in noboost branch. So no dependency on boost.
diff --git a/dev_notes/ToDo.txt b/dev_notes/ToDo.txt
index 426fbc1..3a94ed6 100644
--- a/dev_notes/ToDo.txt
+++ b/dev_notes/ToDo.txt
@@ -1,10 +1,9 @@
 still not fully converted:
     vectors
+    root, bank, instrument loads & saves
 
 pasting effect doesn't update effect title.
 
-transfer instrument external load/save
-
 Requested: revise window states so engines etc can be made auto open.
 
 Do a dual scan for banks so that IDd ones are found first, then any new ones picked up on the second scan. This stops known ones being re-ordered.
diff --git a/dev_notes/Yoshimi Control Numbers.ods b/dev_notes/Yoshimi Control Numbers.ods
index c7a87c2..919a8d7 100644
Binary files a/dev_notes/Yoshimi Control Numbers.ods and b/dev_notes/Yoshimi Control Numbers.ods differ
diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt
index 7add5af..4de8148 100644
--- a/src/CMakeLists.txt
+++ b/src/CMakeLists.txt
@@ -17,7 +17,7 @@
 #   You should have received a copy of the GNU General Public License
 #   along with yoshimi.  If not, see <http://www.gnu.org/licenses/>.
 
-# Modifed September 2017
+# Modifed October 2017
 
 project (Yoshimi)
 cmake_minimum_required (VERSION 3.0)
@@ -34,7 +34,7 @@ add_definitions(-std=gnu++11) # various versions of cmake
 
 # ^^^ comment these two out on release pushes ^^^
 
-set (YOSHIMI_VERSION "1.5.4")
+set (YOSHIMI_VERSION "1.5.4.1")
 
 file (WRITE version.txt "${YOSHIMI_VERSION}")
 
diff --git a/src/Interface/CmdInterface.cpp b/src/Interface/CmdInterface.cpp
index 152afb4..9d3f340 100644
--- a/src/Interface/CmdInterface.cpp
+++ b/src/Interface/CmdInterface.cpp
@@ -1703,10 +1703,11 @@ int CmdInterface::commandPart(bool justSet)
             tmp = string2int(point) - 1;
             if (tmp < 0 || tmp > 159)
                 return range_msg;
-            if (tmp < 128)
-                synth->writeRBP(3, npart | 0x80, tmp); // lower set
-            else
-                synth->writeRBP(4, npart | 0x80, tmp - 128); // upper set
+            sendDirect(npart, 64, 74, 240, 255, 255, 255, 255, tmp);
+            //if (tmp < 128)
+                //synth->writeRBP(3, npart | 0x80, tmp); // lower set
+            //else
+                //synth->writeRBP(4, npart | 0x80, tmp - 128); // upper set
             reply = done_msg;
         }
         else
@@ -2602,7 +2603,8 @@ bool CmdInterface::cmdIfaceProcessCommand()
             if (point[0] == 0)
                 reply = name_msg;
             else
-                synth->writeRBP(5, npart, miscMsgPush((string) point));
+                sendDirect(npart, 64, 78, 240, 255, 255, 255, 255, miscMsgPush((string) point));
+                //synth->writeRBP(5, npart, miscMsgPush((string) point));
             reply = done_msg;
         }
         else
diff --git a/src/Interface/InterChange.cpp b/src/Interface/InterChange.cpp
index 0474a3b..dd25f1c 100644
--- a/src/Interface/InterChange.cpp
+++ b/src/Interface/InterChange.cpp
@@ -17,7 +17,7 @@
     yoshimi; if not, write to the Free Software Foundation, Inc., 51 Franklin
     Street, Fifth Floor, Boston, MA  02110-1301, USA.
 
-    Modified September 2017
+    Modified October 2017
 */
 
 #include <iostream>
@@ -4014,6 +4014,20 @@ void InterChange::commandMain(CommandBlock *getData)
                 value = synth->getRuntime().channelSwitchCC;
             break;
 
+        case 74: // load instrument from ID
+            synth->partonoffLock(value_int, -1);
+            if (par2 < 128)
+                synth->writeRBP(3, value_int | 0x80, par2);
+            else
+                synth->writeRBP(4, value_int | 0x80, par2 - 128);
+            getData->data.type = 0xff; // stop further action
+            break;
+        case 78: // load named instrument
+            synth->partonoffLock(value_int & 0x3f, -1);
+            synth->writeRBP(5, value_int & 0x3f, par2);
+            getData->data.type = 0xff; // stop further action
+            break;
+
         case 80: // load patchset
             if (write && (parameter == 0xc0))
             {
diff --git a/src/Interface/MidiDecode.cpp b/src/Interface/MidiDecode.cpp
index 5d7899a..3caa268 100644
--- a/src/Interface/MidiDecode.cpp
+++ b/src/Interface/MidiDecode.cpp
@@ -17,7 +17,7 @@
     yoshimi; if not, write to the Free Software Foundation, Inc., 51 Franklin
     Street, Fifth Floor, Boston, MA  02110-1301, USA.
 
-    Modified September 2017
+    Modified October 2017
 */
 
 #include <iostream>
@@ -617,26 +617,30 @@ void MidiDecode::setMidiBankOrRootDir(unsigned int bank_or_root_num, bool in_pla
 
 void MidiDecode::setMidiProgram(unsigned char ch, int prg, bool in_place)
 {
-    int partnum;
-    if (ch < NUM_MIDI_CHANNELS)
-        partnum = ch;
-    else
-        partnum = ch & 0x7f; // this is for direct part access instead of channel
-    if (partnum >= synth->getRuntime().NumAvailableParts)
+    if (!synth->getRuntime().EnableProgChange)
         return;
-    if (synth->getRuntime().EnableProgChange)
-    {
-        if (in_place)
-        {
-            //synth->getRuntime().Log("Freewheeling");
-            synth->SetProgram(ch, prg);
-        }
-        else
+    if (ch >= synth->getRuntime().NumAvailableParts)
+        return;
+    if (ch < NUM_MIDI_CHANNELS)
+    { // this is a bit of a hack - needs sorting
+        for (int npart = 0; npart < NUM_MIDI_CHANNELS; ++ npart)
         {
-            //synth->getRuntime().Log("Normal");
-            synth->writeRBP(3, ch ,prg);
+            if (ch == synth->part[npart]->Prcvchn)
+                synth->partonoffLock(npart, -1);
         }
     }
+    else
+        synth->partonoffLock(ch, -1);
+    if (in_place)
+    {
+        //synth->getRuntime().Log("Freewheeling");
+        synth->SetProgram(ch, prg);
+    }
+    else
+    {
+        //synth->getRuntime().Log("Normal");
+        synth->writeRBP(3, ch ,prg);
+    }
 }
 
 
diff --git a/src/Misc/Bank.cpp b/src/Misc/Bank.cpp
index 6fa7d54..4e1d06b 100644
--- a/src/Misc/Bank.cpp
+++ b/src/Misc/Bank.cpp
@@ -20,7 +20,9 @@
     yoshimi; if not, write to the Free Software Foundation, Inc., 51 Franklin
     Street, Fifth Floor, Boston, MA  02110-1301, USA.
 
-    This file is a derivative of a ZynAddSubFX original, last modified January 2015
+    This file is a derivative of a ZynAddSubFX original.
+
+    Modified October 2017
 */
 
 #include <set>
@@ -56,7 +58,6 @@ Bank::Bank(SynthEngine *_synth) :
     currentBankID(0)
 {
     roots.clear();
-    //addDefaultRootDirs();
 }
 
 
@@ -571,8 +572,6 @@ void Bank::scanrootdir(int root_idx)
             continue;
         }
         struct dirent *fname;
-        //int idx;
-        //char x;
         while ((fname = readdir(d)))
         {
             string possible = string(fname->d_name);
diff --git a/src/Misc/ConfBuild.cpp b/src/Misc/ConfBuild.cpp
index 8840d6e..2abb2a4 100644
--- a/src/Misc/ConfBuild.cpp
+++ b/src/Misc/ConfBuild.cpp
@@ -3,4 +3,4 @@
 
 */
 
-#define BUILD_NUMBER 1138
+#define BUILD_NUMBER 1142
diff --git a/src/Misc/Part.cpp b/src/Misc/Part.cpp
index e751fde..2eb0ee1 100644
--- a/src/Misc/Part.cpp
+++ b/src/Misc/Part.cpp
@@ -23,7 +23,7 @@
 
     This file is derivative of ZynAddSubFX original code.
 
-    Modified September 2017
+    Modified October 2017
 */
 
 #include <cstring>
@@ -564,7 +564,7 @@ void Part::NoteOn(int note, int velocity, int masterkeyshift)
                     continue;
 
 
-                // experimental cross fade on multi
+                // cross fade on multi
                 if (Pkitfade)
                 {
                     vel = truevel; // always start with correct value
@@ -1382,7 +1382,7 @@ void Part::getfromXMLinstrument(XMLwrapper *xml)
         Pkitmode = xml->getpar127("kit_mode", Pkitmode);
         Pkitfade = xml->getparbool("kit_crossfade", Pkitfade);
         Pdrummode = xml->getparbool("drum_mode", Pdrummode);
-        //setkititemstatus(0, 0); // does odd things :(
+
         for (int i = 0; i < NUM_KIT_ITEMS; ++i)
         {
             if (!xml->enterbranch("INSTRUMENT_KIT_ITEM", i))
diff --git a/src/Misc/SynthEngine.cpp b/src/Misc/SynthEngine.cpp
index e82b220..5bef57d 100644
--- a/src/Misc/SynthEngine.cpp
+++ b/src/Misc/SynthEngine.cpp
@@ -23,7 +23,7 @@
 
     This file is derivative of original ZynAddSubFX code.
 
-    Modified September 2017
+    Modified October 2017
 */
 
 #include<stdio.h>
@@ -182,7 +182,6 @@ SynthEngine::~SynthEngine()
     if (ctl)
         delete ctl;
     getRemoveSynthId(true, uniqueId);
-
 }
 
 
@@ -538,7 +537,7 @@ void SynthEngine::defaults(void)
         part[npart]->Prcvchn = npart % NUM_MIDI_CHANNELS;
     }
 
-    partonoffWrite(0, 1); // enable the first part
+    partonoffLock(0, 1); // enable the first part
     for (int nefx = 0; nefx < NUM_INS_EFX; ++nefx)
     {
         insefx[nefx]->defaults();
@@ -960,22 +959,12 @@ void SynthEngine::SetProgram(unsigned char chan, unsigned short pgm)
 bool SynthEngine::SetProgramToPart(int npart, int pgm, string fname)
 {
     bool loadOK = false;
-    unsigned char enablestate;
     string loaded;
-
     struct timeval tv1, tv2;
     gettimeofday(&tv1, NULL);
 
-    sem_wait (&partlock);
-
-    if (Runtime.enable_part_on_voice_load)
-        enablestate = 1; // always on
-    else
-        enablestate = 2; // on if it was before
-    partonoffWrite(npart, -1); // more off than before :)
     if (part[npart]->loadXMLinstrument(fname))
     {
-        partonoffWrite(npart, enablestate); // must be here to update gui
         loadOK = true;
         // show file instead of program if we got here from Instruments -> Load External...
         loaded = "Loaded " +
@@ -994,17 +983,18 @@ bool SynthEngine::SetProgramToPart(int npart, int pgm, string fname)
             loaded += ("  Time " + to_string(actual) + "mS");
         }
     }
-    else
-        partonoffWrite(npart, enablestate); // also here to restore failed load state.
-
-    sem_post (&partlock);
 
     if (!loadOK)
-        GuiThreadMsg::sendMessage(this, GuiThreadMsg::GuiAlert,miscMsgPush("Could not load " + fname));
+    {
+        partonoffLock(npart, 2);
+        //GuiThreadMsg::sendMessage(this, GuiThreadMsg::GuiAlert,miscMsgPush("Could not load " + fname));
+    }
     else
     {
-        if (part[npart]->Pname == "Simple Sound")
-            GuiThreadMsg::sendMessage(this, GuiThreadMsg::GuiAlert,miscMsgPush("Instrument is called 'Simple Sound', Yoshimi's basic sound name. You should change this if you wish to re-save."));
+        partonoffLock(npart, 2 - Runtime.enable_part_on_voice_load);
+        // on if enabled, otherwise as before
+        //if (part[npart]->Pname == "Simple Sound")
+            //GuiThreadMsg::sendMessage(this, GuiThreadMsg::GuiAlert,miscMsgPush("Instrument is called 'Simple Sound', Yoshimi's basic sound name. You should change this if you wish to re-save."));
         Runtime.Log(loaded);
         GuiThreadMsg::sendMessage(this, GuiThreadMsg::UpdatePartProgram, npart);
     }
@@ -1950,18 +1940,22 @@ void SynthEngine::vectorSet(int dHigh, unsigned char chan, int par)
             break;
 
         case 4:
+            partonoffLock(chan, -1);
             writeRBP(3, chan | 0x80, par);
             break;
 
         case 5:
+            partonoffLock(chan | 0x10, -1);
             writeRBP(3, chan | 0x90, par);
             break;
 
         case 6:
+            partonoffLock(chan | 0x20, -1);
             writeRBP(3, chan | 0xa0, par);
             break;
 
         case 7:
+            partonoffLock(chan | 0x30, -1);
             writeRBP(3, chan | 0xb0, par);
             break;
 
@@ -2036,9 +2030,9 @@ void SynthEngine::resetAll(void)
 // Enable/Disable a part
 void SynthEngine::partonoffLock(int npart, int what)
 {
-    sem_wait (&partlock);
+    sem_wait(&partlock);
     partonoffWrite(npart, what);
-    sem_post (&partlock);
+    sem_post(&partlock);
 }
 
 /*
@@ -2094,16 +2088,16 @@ char SynthEngine::partonoffRead(int npart)
 
 void SynthEngine::Unmute()
 {
-    sem_wait (&mutelock);
+    sem_wait(&mutelock);
     mutewrite(2);
-    sem_post (&mutelock);
+    sem_post(&mutelock);
 }
 
 void SynthEngine::Mute()
 {
-    sem_wait (&mutelock);
+    sem_wait(&mutelock);
     mutewrite(-1);
-    sem_post (&mutelock);
+    sem_post(&mutelock);
 }
 
 /*
@@ -2157,13 +2151,15 @@ int SynthEngine::MasterAudio(float *outl [NUM_MIDI_PARTS + 1], float *outr [NUM_
     memset(mainR, 0, p_bufferbytes);
 
     interchange.mediate();
+    char partLocal[NUM_MIDI_PARTS]; // isolates loop from possible change
+    for (int npart = 0; npart < Runtime.NumAvailableParts; ++npart)
+            partLocal[npart] = partonoffRead(npart);
 
-    int npart;
     if (isMuted())
     {
-        for (npart = 0; npart < (Runtime.NumAvailableParts); ++npart)
+        for (int npart = 0; npart < (Runtime.NumAvailableParts); ++npart)
         {
-            if (partonoffRead(npart))
+            if (partLocal[npart])
             {
                 memset(outl[npart], 0, p_bufferbytes);
                 memset(outr[npart], 0, p_bufferbytes);
@@ -2181,10 +2177,8 @@ int SynthEngine::MasterAudio(float *outl [NUM_MIDI_PARTS + 1], float *outr [NUM_
         actionLock(lock);
 #endif
         // Compute part samples and store them ->partoutl,partoutr
-        char partLocal[NUM_MIDI_PARTS]; // isolates loop from possible change
-        for (npart = 0; npart < Runtime.NumAvailableParts; ++npart)
+        for (int npart = 0; npart < Runtime.NumAvailableParts; ++npart)
         {
-            partLocal[npart] = partonoffRead(npart);
             if (partLocal[npart])
                 part[npart]->ComputePartSmps();
         }
@@ -2201,7 +2195,7 @@ int SynthEngine::MasterAudio(float *outl [NUM_MIDI_PARTS + 1], float *outr [NUM_
         }
 
         // Apply the part volumes and pannings (after insertion effects)
-        for (npart = 0; npart < Runtime.NumAvailableParts; ++npart)
+        for (int npart = 0; npart < Runtime.NumAvailableParts; ++npart)
         {
             if (!partLocal[npart])
                 continue;
@@ -2233,7 +2227,7 @@ int SynthEngine::MasterAudio(float *outl [NUM_MIDI_PARTS + 1], float *outr [NUM_
             memset(tmpmixr, 0, p_bufferbytes);
 
             // Mix the channels according to the part settings about System Effect
-            for (npart = 0; npart < Runtime.NumAvailableParts; ++npart)
+            for (int npart = 0; npart < Runtime.NumAvailableParts; ++npart)
             {
                 if (partLocal[npart]        // it's enabled
                  && Psysefxvol[nefx][npart]      // it's sending an output
@@ -2273,7 +2267,7 @@ int SynthEngine::MasterAudio(float *outl [NUM_MIDI_PARTS + 1], float *outr [NUM_
             }
         }
 
-        for (npart = 0; npart < Runtime.NumAvailableParts; ++npart)
+        for (int npart = 0; npart < Runtime.NumAvailableParts; ++npart)
         {
             if (part[npart]->Paudiodest & 2){    // Copy separate parts
 
@@ -2320,7 +2314,7 @@ int SynthEngine::MasterAudio(float *outl [NUM_MIDI_PARTS + 1], float *outr [NUM_
             mainR[idx] *= volume;
             if (fadeAll) // fadeLevel must also have been set
             {
-                for (npart = 0; npart < (Runtime.NumAvailableParts); ++npart)
+                for (int npart = 0; npart < (Runtime.NumAvailableParts); ++npart)
                 {
                     if (part[npart]->Paudiodest & 2)
                     {
@@ -2353,7 +2347,7 @@ int SynthEngine::MasterAudio(float *outl [NUM_MIDI_PARTS + 1], float *outr [NUM_
         }
 
         // Peak computation for part vu meters
-        for (npart = 0; npart < Runtime.NumAvailableParts; ++npart)
+        for (int npart = 0; npart < Runtime.NumAvailableParts; ++npart)
         {
             if (partLocal[npart])
             {
@@ -2374,7 +2368,7 @@ int SynthEngine::MasterAudio(float *outl [NUM_MIDI_PARTS + 1], float *outr [NUM_
             jack_ringbuffer_write(vuringbuf, ( char*)VUpeak.bytes, sizeof(VUtransfer));
             VUpeak.values.vuOutPeakL = 1e-12f;
             VUpeak.values.vuOutPeakR = 1e-12f;
-            for (npart = 0; npart < Runtime.NumAvailableParts; ++npart)
+            for (int npart = 0; npart < Runtime.NumAvailableParts; ++npart)
             {
                 if (partLocal[npart])
                     VUpeak.values.parts[npart] = 1.0e-9;
@@ -3257,7 +3251,6 @@ bool SynthEngine::getfromXML(XMLwrapper *xml)
     Runtime.channelSwitchCC = xml->getpar127("channel_switch_CC", Runtime.channelSwitchCC);
     Runtime.channelSwitchValue = 0;
 
-    partonoffWrite(0, 0); // why?;
     for (int npart = 0; npart < NUM_MIDI_PARTS; ++npart)
     {
         if (!xml->enterbranch("PART", npart))
@@ -3410,7 +3403,6 @@ void SynthEngine::closeGui()
     {
         delete guiMaster;
         guiMaster = NULL;
-        //Runtime.showGui = false;
     }
 }
 
diff --git a/src/UI/BankUI.fl b/src/UI/BankUI.fl
index 857f5e7..be2177c 100644
--- a/src/UI/BankUI.fl
+++ b/src/UI/BankUI.fl
@@ -30,7 +30,7 @@ Street, Fifth Floor, Boston, MA  02110-1301, USA.
 
 This file is derivative of original ZynAddSubFX code.
 
-Modified September 2017
+Modified October 2017
 } {in_source in_header
 }
 
@@ -43,6 +43,9 @@ decl {\#include <FL/Fl_File_Chooser.H>} {public local
 decl {\#include <FL/Fl_Spinner.H>} {public local
 }
 
+decl {\#include "UI/MiscGui.h"} {public local
+}
+
 decl {\#include "Misc/Bank.h"} {public local
 }
 
@@ -272,7 +275,7 @@ class RootSlot {: {public Fl_Button, RootProcess_}
   }
 }
 
-class BankUI {selected : {public BankProcess_, RootProcess_, MiscFuncs}
+class BankUI {open : {public BankProcess_, RootProcess_, MiscFuncs}
 } {
   Function {make_window()} {} {
     Fl_Window instrumentuiwindow {
@@ -746,6 +749,11 @@ class BankUI {selected : {public BankProcess_, RootProcess_, MiscFuncs}
       }
     }
   }
+  Function {send_data(int control, float value, int type, int part = 0xff, int kititem = 0xff, int engine = 0xff, int insert = 0xff, int parameter = 0xff, int par2 = 0xff)} {} {
+    code {//
+    collect_data(synth, value, (Fl::event_button() | type), control, part, kititem, engine, insert, parameter, par2);} {selected
+    }
+  }
   Function {BankUI(int *npart_, SynthEngine *_synth)} {} {
     code {//
     synth = _synth;
@@ -798,11 +806,8 @@ class BankUI {selected : {public BankProcess_, RootProcess_, MiscFuncs}
         string thisname =  bank->getname(slot);
         if ((what == 1 || what == 3) && mode == 1 && !bank->emptyslot(slot))
         {
+            send_data(74, *npart, 0xc8, 240, 255, 255, 255, 255, slot);
             // Reads from slot
-            if (slot < 128)
-                synth->writeRBP(3, (*npart) | 0x80, slot);
-            else
-                synth->writeRBP(4, (*npart) | 0x80, slot - 128);
             if (what == 3)
                 instrumentuiwindow->hide();
             cbwig->do_callback();
@@ -1093,7 +1098,7 @@ class BankUI {selected : {public BankProcess_, RootProcess_, MiscFuncs}
         if (!it->second.dirname.empty())
         {
             int n = banklist->add((asString(it->first) + ". " + it->second.dirname).c_str(), (const char *)0, (Fl_Callback*)0, reinterpret_cast<void *>(it->first));
-//            if(it->first == bank->getCurrentBankID())
+//            if(it->first == bank->getCurrentBankID()) // why?
             {
                 banklist->value(n);
             }
diff --git a/src/UI/EffUI.fl b/src/UI/EffUI.fl
index 8c50434..f2f8377 100644
--- a/src/UI/EffUI.fl
+++ b/src/UI/EffUI.fl
@@ -29,7 +29,7 @@ Street, Fifth Floor, Boston, MA  02110-1301, USA.
 
 This file is a derivative of the ZynAddSubFX original
 
-Modified September 2017
+Modified October 2017
 } {in_source in_header
 }
 
@@ -2198,8 +2198,7 @@ class EffUI {selected : {public Fl_Group,public PresetsUI_}
                     break;
             }
             break;
-    }
-    Fl::check();} {}
+    }} {}
   }
   Function {init(EffectMgr *eff_, int npart_, int neff_)} {} {
     code {//
diff --git a/src/UI/EnvelopeUI.fl b/src/UI/EnvelopeUI.fl
index 3954587..947149e 100644
--- a/src/UI/EnvelopeUI.fl
+++ b/src/UI/EnvelopeUI.fl
@@ -29,7 +29,7 @@ Street, Fifth Floor, Boston, MA  02110-1301, USA.
 
 This file is a derivative of the ZynAddSubFX original.
 
-Modified September 2017
+Modified October 2017
 } {in_source in_header
 }
 
@@ -883,7 +883,6 @@ send_data(group, curpoint, 0, 0xd0, 3);}
         envfree->redraw();
         sustaincounter->value(env->Penvsustain);
         sustaincounter->maximum(env->Penvpoints-2);
-        Fl::check();
         return;
     }
 
@@ -1053,7 +1052,7 @@ send_data(group, curpoint, 0, 0xd0, 3);}
     }
     if (change)
         freeedit->redraw();
-    Fl::check();} {}
+    } {}
   }
   Function {init(EnvelopeParams *env_, int npart_, int kititem_, int engine_, int group_)} {} {
     code {//
diff --git a/src/UI/FilterUI.fl b/src/UI/FilterUI.fl
index f21867f..2a4407c 100644
--- a/src/UI/FilterUI.fl
+++ b/src/UI/FilterUI.fl
@@ -29,7 +29,7 @@ Street, Fifth Floor, Boston, MA  02110-1301, USA.
 
 This file is derivative of ZynAddSubFX original code
 
-Modified September 2017} {in_source in_header
+Modified October 2017} {in_source in_header
 }
 
 decl {\#include "UI/MiscGui.h"} {public local
@@ -974,8 +974,7 @@ pars=NULL;
         case 38:
             neginput->value(value != 0);
             break;
-    }
-    Fl::check();} {}
+    }} {}
   }
   Function {init(FilterParams *filterpars_,unsigned char *velsnsamp_,unsigned char *velsns_, int npart_, int kititem_, int engine_)} {} {
     code {//
diff --git a/src/UI/LFOUI.fl b/src/UI/LFOUI.fl
index 912415f..1ce9b0b 100644
--- a/src/UI/LFOUI.fl
+++ b/src/UI/LFOUI.fl
@@ -28,7 +28,7 @@ yoshimi; if not, write to the Free Software Foundation, Inc., 51 Franklin
 Street, Fifth Floor, Boston, MA  02110-1301, USA.
 
 This file is a derivative of the ZynAddSubFX original
-Modified March 2017
+Modified October 2017
 } {in_source in_header
 }
 
@@ -73,8 +73,7 @@ pars=NULL;} {}
   }
   Function {~LFOUI()} {} {
     code {lfoui->hide();
-    hide();
-//delete (lfoui);} {}
+    hide();} {}
   }
   Function {make_window()} {} {
     Fl_Window lfoui {
@@ -278,8 +277,7 @@ pars=NULL;} {}
         case 8:
             stretch->value(value);
             break;
-    }
-    Fl::check();} {}
+    }} {}
   }
   Function {init(LFOParams *lfopars_, int npart_, int kititem_, int engine_, int group_)} {} {
     code {//
diff --git a/src/UI/MasterUI.fl b/src/UI/MasterUI.fl
index f0037cd..395bf9b 100644
--- a/src/UI/MasterUI.fl
+++ b/src/UI/MasterUI.fl
@@ -29,7 +29,7 @@ Street, Fifth Floor, Boston, MA  02110-1301, USA.
 
 This file is a derivative of the ZynAddSubFX original.
 
-Modified September 2017
+Modified October 2017
 
 } {in_source in_header
 }
@@ -363,7 +363,7 @@ class MasterUI {selected : {private GuiUpdates}
                 filename = fl_file_chooser("Load:", "({*.xiz})", NULL, 0);
                 if (filename == NULL)
                     return;
-                synth->writeRBP(5, npart,miscMsgPush(filename));}
+                send_data(78, npart, 0xc8, 240, 255, 255, 255, miscMsgPush(filename));}
             tooltip {Load an instrument (.xiz) file} xywh {30 30 100 20} labelsize 12
           }
           MenuItem {} {
@@ -1128,7 +1128,6 @@ ZynAddSubFX}
     unsigned char insert = getData->data.insert;
     unsigned char par2 = getData->data.par2;
     int nval = lrint(value);
-    bool check = true;
     if (npart == 0xf1)
     {
         if (insert == 16)
@@ -1154,7 +1153,6 @@ ZynAddSubFX}
                 showSysEfxUI();
             }
         }
-        Fl::check();
         return;
     }
     else if (npart == 0xf2)
@@ -1162,7 +1160,7 @@ ZynAddSubFX}
         if (control == 0)
         {
             ninseff = engine;
-            setInsEff(ninseff);;
+            setInsEff(ninseff);
         }
         else if (control == 1)
         {
@@ -1178,7 +1176,6 @@ ZynAddSubFX}
             else
                 insefftype->activate();
         }
-        Fl::check();
         return;
     }
     string name;
@@ -1190,7 +1187,6 @@ ZynAddSubFX}
             break;
 
         case 14:
-            check = false;
             partuigroup->remove(partui);
             delete partui;
             partui = new PartUI(0, 0, 765, 525);
@@ -1332,9 +1328,7 @@ ZynAddSubFX}
                 }
             }
             break;
-    }
-    if (check)
-        Fl::check();} {}
+    }} {}
   }
   Function {updatesendwindow()} {} {
     code {//
@@ -1814,8 +1808,7 @@ ZynAddSubFX}
     {
         Reports->deactivate();
         yoshiLog->Hide();
-    }
-    Fl::check();} {}
+    }} {}
   }
   Function {showInstrumentEditWindow(int _npart)} {} {
     code {//
diff --git a/src/UI/MiscGui.cpp b/src/UI/MiscGui.cpp
index c1900b5..fae0c57 100644
--- a/src/UI/MiscGui.cpp
+++ b/src/UI/MiscGui.cpp
@@ -17,7 +17,7 @@
     yoshimi; if not, write to the Free Software Foundation, Inc., 51 Franklin
     Street, Fifth Floor, Boston, MA  02110-1301, USA.
 
-    Modified August 2017
+    Modified October 2017
 */
 
 #include "Misc/SynthEngine.h"
@@ -93,14 +93,17 @@ void GuiUpdates::read_updates(SynthEngine *synth)
 {
     CommandBlock getData;
     size_t commandSize = sizeof(getData);
-
+    bool isChanged = false;
     while (jack_ringbuffer_read_space(synth->interchange.toGUI) >= commandSize)
     {
         int toread = commandSize;
         char *point = (char*) &getData.bytes;
         jack_ringbuffer_read(synth->interchange.toGUI, point, toread);
         decode_updates(synth, &getData);
+        isChanged = true;
     }
+    if (isChanged)
+        Fl::check();
 }
 
 
diff --git a/src/UI/OscilGenUI.fl b/src/UI/OscilGenUI.fl
index 85a1753..613294f 100644
--- a/src/UI/OscilGenUI.fl
+++ b/src/UI/OscilGenUI.fl
@@ -29,7 +29,7 @@ Street, Fifth Floor, Boston, MA  02110-1301, USA.
 
 This file is a derivative of the ZynAddSubFX original.
 
-Modified September 2017
+Modified October 2017
 } {in_source in_header
 }
 
@@ -1368,7 +1368,6 @@ class OscilEditor {selected : {public PresetsUI_}
             applybutton->color(FL_RED);
             applybutton->redraw();
         }
-        Fl::check();
     }} {}
   }
   Function {OscilEditor(OscilGen *oscil_, Fl_Widget *oldosc_, Fl_Widget *cbwidget_, Fl_Widget *cbapplywidget_, SynthEngine *_synth, int npart_, int kititem_, int engine_)} {} {
diff --git a/src/UI/PADnoteUI.fl b/src/UI/PADnoteUI.fl
index 3c45e8f..e95e59c 100644
--- a/src/UI/PADnoteUI.fl
+++ b/src/UI/PADnoteUI.fl
@@ -29,7 +29,7 @@ Street, Fifth Floor, Boston, MA  02110-1301, USA.
 
 This file is derivative of ZynAddSubFX original code
 
-Modified September 2017
+Modified October 2017
 } {in_source in_header
 }
 
@@ -1326,8 +1326,7 @@ class PADnoteUI {selected : {public PresetsUI_, private SynthHelper, MiscFuncs}
             pvel->value(value);
             break;
 
-    }
-    Fl::check();} {}
+    }} {}
   }
   Function {PADnoteUI(PADnoteParameters *parameters, int npart_, int kititem_)} {} {
     code {//
diff --git a/src/UI/ParametersUI.fl b/src/UI/ParametersUI.fl
index 29b42b0..2fd29be 100644
--- a/src/UI/ParametersUI.fl
+++ b/src/UI/ParametersUI.fl
@@ -18,7 +18,7 @@ GNU General Public License for more details.
 You should have received a copy of the GNU General Public License
 along with yoshimi.  If not, see <http://www.gnu.org/licenses/>.
 
-Modified September 2017
+Modified October 2017
 } {in_source in_header
 }
 
@@ -51,7 +51,6 @@ class ParametersUI {selected
             return;
         CloseRecent->hide();
         Loading->show();
-        Fl::check();
         vector<string> listType = *synth->getHistory(H_type);
         string fle = listType.at(listType.size() - o->value());
         switch(H_type)
diff --git a/src/UI/PartUI.fl b/src/UI/PartUI.fl
index fd363df..aa6ce57 100644
--- a/src/UI/PartUI.fl
+++ b/src/UI/PartUI.fl
@@ -29,7 +29,7 @@ Street, Fifth Floor, Boston, MA  02110-1301, USA.
 
 This file is derivative of ZynAddSubFX original code.
 
-Modified September 2017
+Modified October 2017
 } {in_source in_header
 }
 
@@ -1470,9 +1470,7 @@ Offset}
     bool valBool = (value > 0.5f);
     int valInt = lrint(value);
     int tmp = (valInt & 15) + 1;
-    bool check = true;
 
-    npart = newpart;
     // these are specific to the mixer panel
     if (newpart >= *plgroup && newpart < (*plgroup + NUM_MIDI_CHANNELS))
     {
@@ -1494,7 +1492,13 @@ Offset}
                 break;
             case 8:
                 if (engine == 255)
+                {
                     synth->getGuiMaster()->panellistitem[displaypart]->partenabled->value(valBool);
+                    if (valBool)
+                        synth->getGuiMaster()->panellistitem[displaypart]->panellistitemgroup->activate();
+                    else
+                        synth->getGuiMaster()->panellistitem[displaypart]->panellistitemgroup->deactivate();
+                }
                 break;
             case 120:
                 int send = valInt - 1;
@@ -1703,7 +1707,6 @@ Offset}
                         }
                         break;
                     case 255:
-                        check = false;
                         partGroupEnable->value(valBool);
                         if (valBool)
                         {
@@ -1939,11 +1942,8 @@ Offset}
             updatecontrollers();
             break;
         default:
-            check = false;
             break;
-    }
-    if (check)
-        Fl::check();} {}
+    }} {}
   }
   Function {PartUI(int x,int y, int w, int h, const char *label=0):Fl_Group(x,y,w,h,label)} {} {
     code {//
diff --git a/src/UI/ResonanceUI.fl b/src/UI/ResonanceUI.fl
index b5d0faf..eecae19 100644
--- a/src/UI/ResonanceUI.fl
+++ b/src/UI/ResonanceUI.fl
@@ -29,7 +29,7 @@ Street, Fifth Floor, Boston, MA  02110-1301, USA.
 
 This file is a derivative of the ZynAddSubFX original
 
-Modified September 2017
+Modified October 2017
 } {in_source in_header
 }
 
@@ -552,7 +552,6 @@ class ResonanceUI {selected : PresetsUI_
     {
         if (eng == 2)
             redrawPADnoteApply();
-        //Fl::check();
     }} {}
   }
   Function {ResonanceUI(Resonance *respar_, int npart_, int kititem_, int engine_)} {} {

-- 
yoshimi packaging



More information about the pkg-multimedia-commits mailing list