* auto-save:
don't change the current project when auto-saving
auto-saves every minute and recovers upon crash
don't show WelcomeScreen when importing/loading
Conflicts:
src/gui/MainWindow.cpp
This reverts commit c517f1fa5a.
The commit was not very helpful and introduced new xrun problems.
Instead I'll be rewriting the part of LMMS where Mixer, Mixer's
quality settings, Buffer FIFO and AudioDevice are sticked together.
There's really no need to allocate a buffer each period, push it to the
FifoBuffer and free it when fetching the buffer in
AudioDevice::getNextBuffer(). Instead keep the pointer in FifoBuffer's
pool and reuse it.
There have been some problems with the threading logic in the
AudioPulseAudio backend resulting in an endless loop when quitting LMMS.
Furthermore allocated PulseAudio resources were not freed properly.
Thanks to Armin Kazmi <armin.kazmi@tu-dortmund.de> for pointing out
this issue.
every time auto-save ran, it would change the current project to
"recover.mmp". Now it doesn't do this because Song has
guiSaveProject(), guiSaveProjectAs(), and saveProjectFile().
(the latter is used for auto-save)
auto-save time is not configurable yet. saves "recover.mmp" to
WORKING_DIR every 60 seconds. Deletes recover.mmp on successful
close of LMMS. If recover.mmp is found upon start, it loads that
project.
Rewrote implementation of class SideBar to use QToolBar instead of
KMultiTabBar. We can style the SideBar now easily via CSS and do not
have to ship 3rd party KDE code with LMMS. Also the QToolBar based
SideBar integrates much better into the according widget style.
Furthermore renamed SideBar related classes and files to match new
coding style.
Functionality from QuickLoadDialog which can be used in similiar dialogs
for selecting resources has been moved into generic and highly flexible
base class ResourceSelectDialog.
Again there's no need for duplicated functionality. Adding a
ResourceAction::defaultTrigger() method allows to separate all
functionality from ResourceBrowser and possibly use it in other places
as well.
There's absolutely no need for duplicating the Action enumeration
in ResourceBrowser as there's already one in ResourceAction class.
Replacing the enumeration with ResourceAction's one makes code clearer
and reduces redundancy.
Added another buffer operation BufMixCoeff allowing to mix a certain
buffer to another at a given amount (coeff). CpuX86 has been extended
by an according SSE implementation.
This should resolve the remaining issues. OSS has auto-complete with
the filesystem. Alsa has an editable combobox for PCM and MIDI-raw.
The DEVICE box for Alsa MIDI-seq should be obsoleted
JobQueues can now operate in JobQueue::Static and JobQueue::Dynamic mode.
In static mode it operates the way it always used to while in dynamic
mode a changing job queue is supported. This is particularly important
for FX mixer sends.
There were also heavy improvements regarding the overall structure
and functionality of MixerWorkerThread and MixerWorkerThread::JobQueue.
There's now a clean distinction between multi-threaded processing
and actual (thread-safe) job queue processing. MixerWorkerThread does
not need to be a friend class of Mixer anymore.
Declarations and implementations of MixerWorkerThread and ThreadableJob
have been moved into separate source files.
Furthermore there were some improvements to MixerWorkerThreads.
MixerWorkerThread::processJobQueue() does not return until the job
queue completely has been processed. This way each thread can "help"
to finish processing the queue and does not get back to sleep until
all of the work is done.
Management of the queue is now done via an array of QAtomicPointers.
Items that are non-NULL still need to be processed while NULL-items
were taken from the queue (i.e. in progress or done). Thus we do not
need to deal with ThreadableJob-states within MixerWorkerThread anymore.
The FxMixer now uses job threads to accomplish its mixing. It's
theoretically efficient, but there is a horrible thread bug
preventing the code from working. I've spent 5 hours debugging and
need some external help!
In Mixer, the old C-macro based code has been replaced by an OOP-like
design. Management of job queue now happens via some static member
methods of MixerWorkerThread. All the moved code still needs to be
splitted into some new files but here's a first dirty version.
All objects that are intended to be processed by MixerWorkerThreads
have to inherit ThreadableJob (name of class is subject of change).
One can add jobs to the job queue even if the queue is already being
processed. This is merely important for multithreading with upcoming
FX sends support.
In the Fx Mixer View, you can select a channel and press Alt+Left
and Alt+Right respectively to re-order Fx Channels. This should be
made more easily available in the GUI eventually.
* lock fx mixer height
Done. channelArea->setFixedHeight and proper sizeConstraints
* width: pick a good min. size. keep max. size off.
Done. Set to 6 fx-lines.
* effects chain should align to the right
Done.
* get rid of padding in mixer
Done. setSpacing and setMargin on chLayout
* scroll area so that vert scrollbar is never seen.
Done. setVerticalScrollBarPolicy and proper height calculation
* Get rid of scroll bar area border
Done. FrameStyle.
The biggest change, however, was removing the multiple EffectRackViews
that were being used. Now just a single EffectRackView exists and it is
shared by all models.
Created a user interface so you can add and remove FX sends as
well as tweak how much you are sending. The gui does not
yet prevent the user from creating endless render loops.
Additionally, there seems to be some issues to work out regarding
rendering with multiple sends.
While regular instruments were excluded from processing when muted
this did not happen for InstrumentPlayHandle-based instruments. Muting
for exampling tracks with VSTi's inside did not decrease CPU usage.
Checking whether related InstrumentTrack is muted before calling
Instrument::play() fixes this issue.
Closes#2857426.
QHttp is quite low-level while QNetworkAccessManager offers a well
designed API for accessing network resources. Therefore switched backend
of WebResourceProvider from QHttp to QNetworkAccessManager.
If DEBUG_REMOTE_PLUGIN was set, RemotePlugin::process() always returned
as RemotePlugin::isRunning() returned false. Fix this by always
returning true when debugging.
Instead of writing QVector<Plugin::Descriptor> everywhere, mit up
iterators etc. centrally define Plugin::DescriptorList and use it
everywhere.
Additionally made pointers to Plugin::Descriptor and
Plugin::Descriptor::SubPluginFeatures::Key const in various places
so we can use ConstIterator everywhere when iterating through
Plugin::DescriptorList.
We can safely make fillDescriptionWidget() and listSubPluginKeys()
const methods. Furthermore descriptor pointer to listSubPluginKeys()
can be const as well. Might allow more optimizations by the compiler.