Fixes the following two errors I spotted using valgrind:
When deleting a channel;
==936== Invalid read of size 8
==936== at 0x56FA1D: FxMixerView::deleteChannel(int) (FxMixerView.cpp:374)
==936== by 0x60E9A79: QMetaObject::activate(QObject*, QMetaObject const*, int, void**) (in /usr/lib/x86_64-linux-gnu/libQtCore.so.4.8.6)
==936== by 0x5216BF1: QAction::triggered(bool) (in /usr/lib/x86_64-linux-gnu/libQtGui.so.4.8.6)
==936== by 0x52185C2: QAction::activate(QAction::ActionEvent) (in /usr/lib/x86_64-linux-gnu/libQtGui.so.4.8.6)
==936== Address 0x14d51b90 is 32 bytes inside a block of size 40 free'd
==936== at 0x4C2C2E0: operator delete(void*) (in /usr/lib/valgrind/vgpreload_memcheck-amd64-linux.so)
==936== by 0x56F9ED: FxMixerView::deleteChannel(int) (FxMixerView.cpp:370)
==936== by 0x60E9A79: QMetaObject::activate(QObject*, QMetaObject const*, int, void**) (in /usr/lib/x86_64-linux-gnu/libQtCore.so.4.8.6)
==936== by 0x5216BF1: QAction::triggered(bool) (in /usr/lib/x86_64-linux-gnu/libQtGui.so.4.8.6)
When loading a new project after adding some channels:
==936== Invalid read of size 8
==936== at 0x570785: FxMixerView::refreshDisplay() (FxMixerView.cpp:202)
==936== by 0x4B590E: Song::clearProject() (Song.cpp:740)
==936== by 0x4B7885: Song::createNewProject() (Song.cpp:817)
==936== by 0x60E9A79: QMetaObject::activate(QObject*, QMetaObject const*, int, void**) (in /usr/lib/x86_64-linux-gnu/libQtCore.so.4.8.6)
==936== Address 0x56a12ab0 is 32 bytes inside a block of size 40 free'd
==936== at 0x4C2C2E0: operator delete(void*) (in /usr/lib/valgrind/vgpreload_memcheck-amd64-linux.so)
==936== by 0x57075B: FxMixerView::refreshDisplay() (FxMixerView.cpp:201)
==936== by 0x4B590E: Song::clearProject() (Song.cpp:740)
==936== by 0x4B7885: Song::createNewProject() (Song.cpp:817)
* Ctrl + Left/Right moves selected notes by one bar
(Old behaviour was to move the playnote)
Closes#811
* Shift + Up/Down moves selected nodes by one semitone
(Old behaviour was to ignore the Shift key and move the viewport)
Closes#810
Fixes 20 warnings similar to the following ones when generating a translation file with e.g. "make de.ts":
/home/daniel/Lmms/src/tracks/AutomationTrack.cpp:40: Class 'AutomationTrack' lacks Q_OBJECT macro
/home/daniel/Lmms/src/core/FxMixer.cpp:41: Class 'FxRoute' lacks Q_OBJECT macro
/home/daniel/Lmms/src/core/FxMixer.cpp:554: Class 'FxMixer' lacks Q_OBJECT macro
/home/daniel/Lmms/src/gui/widgets/MeterDialog.cpp:52: Class 'MeterDialog' lacks Q_OBJECT macro
...
Fixes 20 warnings similar to the following ones when generating a translation file with e.g. "make de.ts":
/home/daniel/Lmms/src/tracks/AutomationTrack.cpp:40: Class 'AutomationTrack' lacks Q_OBJECT macro
/home/daniel/Lmms/src/core/FxMixer.cpp:41: Class 'FxRoute' lacks Q_OBJECT macro
/home/daniel/Lmms/src/core/FxMixer.cpp:554: Class 'FxMixer' lacks Q_OBJECT macro
/home/daniel/Lmms/src/gui/widgets/MeterDialog.cpp:52: Class 'MeterDialog' lacks Q_OBJECT macro
...
The constructor was probably the wrong place to put it, run() is definitely executed in the new thread so that's where the setting should be applied I think?
Use dynamic building of jobqueues with dependency counting:
- At the start, each channel that has no dependencies is added automatically to the queue
- Then, after each channel is processed, it increments the dep.counter of all its recipients
- When a channel's dep.counter hits the amount of its dependencies (senders), it gets automatically added to the queue
- The queue is finished when the master channel has been processed
- Muted channels are automatically processed at the start regardless dependencies, because they don't have to care about senders, being muted
Hopefully this will improve Fx Mixer performance.