Hi all,

I'm trying to make LS respond to a predetermined program change event and
unload all instruments across all instances as a result. So far I've figured
out I should modify EngineChannel::ExecuteProgramChange to catch the special
event and call InstrumentManager::SetModeInBackground to have all the
instruments set to a mode where they will be immediately unloaded (I forget
which mode that is). How would I make sure this happens in all instances
since the program change event is only sent to one instance of LS? My
apologies if I'm using 'instance' incorrectly but I hope you understand what
I mean.

Background for the curious:
I have nicely organized large instrument maps for my giga instruments, but
of course memory is small in comparison to the amount needed for these
(though I wish I could load all 200 GB!). Many DAWs provide a mechanism to
deal with this, by allowing you to render the track and temporarily unload
all VST plugins for that track (I think the popular Cubase calls this
'freezing', for example). Unfortunately, my DAW doesn't know how to achieve
this while respecting LinuxSampler's unique design, resulting in a crash.
However, I've discovered if I change the mode of all instruments to the
correct mode, then LinuxSampler may be successfully temporarily unloaded and
later loaded again regardless of how many instruments were loaded. I'm
trying to automate this task, as it is rather cumbersome to manually change
the Instrument Mode for all instruments before and after every unload/load
cycle.
------------------------------------------------------------------------------
ThinkGeek and WIRED's GeekDad team up for the Ultimate 
GeekDad Father's Day Giveaway. ONE MASSIVE PRIZE to the 
lucky parental unit.  See the prize list and enter to win: 
http://p.sf.net/sfu/thinkgeek-promo
_______________________________________________
Linuxsampler-devel mailing list
Linuxsampler-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/linuxsampler-devel

Reply via email to