mirror of
https://github.com/Ardour/ardour.git
synced 2025-12-06 23:05:04 +01:00
Unload VST3 modules when closing session
This is perhaps a better solution thanb8551eed7eand8d0a655608and7942897d93. It is certainly less fragile. It is more consistent with other plugin standards, where modules are closed with the last instance in a session. Then again keeping the VST3 factory around is beneficial when switching snapshots. Discuss, and let's watch for issues when re-loading a previously unloaded VST3 module.
This commit is contained in:
parent
b8551eed7e
commit
cd5369c7cd
1 changed files with 6 additions and 0 deletions
|
|
@ -134,6 +134,7 @@
|
|||
#include "ardour/utils.h"
|
||||
#include "ardour/vca_manager.h"
|
||||
#include "ardour/vca.h"
|
||||
#include "ardour/vst3_plugin.h"
|
||||
|
||||
#include "midi++/port.h"
|
||||
#include "midi++/mmc.h"
|
||||
|
|
@ -864,6 +865,11 @@ Session::destroy ()
|
|||
|
||||
_transport_fsm->stop ();
|
||||
|
||||
/* close VST3 Modules */
|
||||
for (auto const& nfo : PluginManager::instance().vst3_plugin_info()) {
|
||||
std::dynamic_pointer_cast<VST3PluginInfo> (nfo)->m.reset ();
|
||||
}
|
||||
|
||||
DEBUG_TRACE (DEBUG::Destruction, "Session::destroy() done\n");
|
||||
|
||||
#ifndef NDEBUG
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue