<?xml version="1.0" encoding="UTF-8"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0"><channel><title><![CDATA[Player and expansion communication......]]></title><description><![CDATA[<p dir="auto">So I have a player, with a list of libraries/instruments that it knows about, I want to be able to load an instrument - but retain this list <em>AND ITS STATE</em></p>
<p dir="auto">Now <a class="plugin-mentions-user plugin-mentions-a" href="https://forum.hise.audio/uid/1">@Christoph-Hart</a> tells me:<br />
"and a common shared left tab is not the hardest thing to implement"</p>
<ul>
<li>which is correct - but one that share s open/closed state information is probably quite a lot harder.....</li>
</ul>
<p dir="auto">So the only way I can think of communicating this "state information" between player and instrument is to use a classic file-as-postbox approach ....but but but...</p>
<p dir="auto">I have no way of assuring that the write to postbox is complete before opening the requested instrument. Or do I?</p>
<p dir="auto">There's no callback for write-to-file-complete, and the write is async I think so it will or wont have happened by the time the expansion is reading the file..so no gtee's there either.</p>
<p dir="auto">Anyone put me right or have a better idea on this?</p>
]]></description><link>https://forum.hise.audio/topic/14646/player-and-expansion-communication</link><generator>RSS for Node</generator><lastBuildDate>Mon, 20 Apr 2026 16:34:47 GMT</lastBuildDate><atom:link href="https://forum.hise.audio/topic/14646.rss" rel="self" type="application/rss+xml"/><pubDate>Mon, 20 Apr 2026 12:51:44 GMT</pubDate><ttl>60</ttl><item><title><![CDATA[Reply to Player and expansion communication...... on Mon, 20 Apr 2026 16:14:33 GMT]]></title><description><![CDATA[<p dir="auto"><a class="plugin-mentions-user plugin-mentions-a" href="https://forum.hise.audio/uid/12">@David-Healey</a> said in <a href="/post/119627">Player and expansion communication......</a>:</p>
<blockquote>
<p dir="auto"><a class="plugin-mentions-user plugin-mentions-a" href="https://forum.hise.audio/uid/67">@Lindon</a> If you set the current expansion to "" that will trigger the unload action, so you can respond to that. I'm not sure if that reruns the player's <code>on init</code> but you could test.</p>
<p dir="auto">I think a timer and polling on the message thread is the way to go, the timer won't run when the interface is minimised anyway.</p>
</blockquote>
<p dir="auto">Yeah its the expansion that will be setting the current expansion to "" - so I'm not sure how the player responds to that....I cant see a expansion changed callback or listener...</p>
]]></description><link>https://forum.hise.audio/post/119631</link><guid isPermaLink="true">https://forum.hise.audio/post/119631</guid><dc:creator><![CDATA[Lindon]]></dc:creator><pubDate>Mon, 20 Apr 2026 16:14:33 GMT</pubDate></item><item><title><![CDATA[Reply to Player and expansion communication...... on Mon, 20 Apr 2026 14:08:08 GMT]]></title><description><![CDATA[<p dir="auto"><a class="plugin-mentions-user plugin-mentions-a" href="https://forum.hise.audio/uid/67">@Lindon</a> If you set the current expansion to "" that will trigger the unload action, so you can respond to that. I'm not sure if that reruns the player's <code>on init</code> but you could test.</p>
<p dir="auto">I think a timer and polling on the message thread is the way to go, the timer won't run when the interface is minimised anyway.</p>
]]></description><link>https://forum.hise.audio/post/119627</link><guid isPermaLink="true">https://forum.hise.audio/post/119627</guid><dc:creator><![CDATA[David Healey]]></dc:creator><pubDate>Mon, 20 Apr 2026 14:08:08 GMT</pubDate></item><item><title><![CDATA[Reply to Player and expansion communication...... on Mon, 20 Apr 2026 13:44:04 GMT]]></title><description><![CDATA[<p dir="auto"><a class="plugin-mentions-user plugin-mentions-a" href="https://forum.hise.audio/uid/67">@Lindon</a> said in <a href="/post/119618">Player and expansion communication......</a>:</p>
<blockquote>
<p dir="auto"><a class="plugin-mentions-user plugin-mentions-a" href="https://forum.hise.audio/uid/12">@David-Healey</a> state is simply "open" or "closed" (0 or 1) for every library (which has categories in it) and Categories(which have instruments in them)</p>
<p dir="auto">State needs to be transferable <em>BOTH ways</em> so we start with all libs closed....</p>
<p dir="auto">In the player we open LibA, open CatA and load InstrumentAA</p>
<p dir="auto">InstrumentAA opens and displays the LibPanel with all libs closed <em>except</em> LibA, and within that CatA is also open...</p>
<p dir="auto">In instrumentAA we close LibA and Open LibB, then we close InstrumentAA,</p>
<p dir="auto">The player opens with all libs closed <em>except</em> LibB</p>
</blockquote>
<p dir="auto">The problem(well theres a truck load of problems..) here is I can see how I can save state (in some file) and read it on plugin(player) load...and as soon as the user requests a load of an instrument we write the current states to the file.</p>
<p dir="auto">The instrument reads this state file on load and sets the display correctly. On instrument unload (so the instrument is unloading itself) the instrument saves the new state(assuming its changed) and unloads itself.....</p>
<p dir="auto">..but I dont know how the player now reads this new state file in any efficient manner- meaning not running a timer every 0.5 seconds to re-read the state file......???</p>
<p dir="auto">The player never knows the instrument is now unloaded does it?  Or can it tell from</p>
<p dir="auto">ExpansionHandler.getCurrentExpansion() if it == ""      then whatever it loaded is now unloaded...  ???</p>
<p dir="auto">Or how is the player itself loading/unloading whilst a Full Instrument is in play? I guess I need to know the mechanics of player/instrument load/unload ....do we execute init again? ...<a class="plugin-mentions-user plugin-mentions-a" href="https://forum.hise.audio/uid/1">@Christoph-Hart</a> !!!</p>
]]></description><link>https://forum.hise.audio/post/119625</link><guid isPermaLink="true">https://forum.hise.audio/post/119625</guid><dc:creator><![CDATA[Lindon]]></dc:creator><pubDate>Mon, 20 Apr 2026 13:44:04 GMT</pubDate></item><item><title><![CDATA[Reply to Player and expansion communication...... on Mon, 20 Apr 2026 13:14:05 GMT]]></title><description><![CDATA[<p dir="auto"><a class="plugin-mentions-user plugin-mentions-a" href="https://forum.hise.audio/uid/12">@David-Healey</a> --- havent even considered that, any way you want.</p>
]]></description><link>https://forum.hise.audio/post/119622</link><guid isPermaLink="true">https://forum.hise.audio/post/119622</guid><dc:creator><![CDATA[Lindon]]></dc:creator><pubDate>Mon, 20 Apr 2026 13:14:05 GMT</pubDate></item><item><title><![CDATA[Reply to Player and expansion communication...... on Mon, 20 Apr 2026 13:13:04 GMT]]></title><description><![CDATA[<p dir="auto"><a class="plugin-mentions-user plugin-mentions-a" href="https://forum.hise.audio/uid/67">@Lindon</a> How does it need to work between multiple instances of the plugin?</p>
]]></description><link>https://forum.hise.audio/post/119620</link><guid isPermaLink="true">https://forum.hise.audio/post/119620</guid><dc:creator><![CDATA[David Healey]]></dc:creator><pubDate>Mon, 20 Apr 2026 13:13:04 GMT</pubDate></item><item><title><![CDATA[Reply to Player and expansion communication...... on Mon, 20 Apr 2026 13:11:24 GMT]]></title><description><![CDATA[<p dir="auto"><a class="plugin-mentions-user plugin-mentions-a" href="https://forum.hise.audio/uid/12">@David-Healey</a> state is simply "open" or "closed" (0 or 1) for every library (which has categories in it) and Categories(which have instruments in them)</p>
<p dir="auto">State needs to be transferable <em>BOTH ways</em> so we start with all libs closed....</p>
<p dir="auto">In the player we open LibA, open CatA and load InstrumentAA</p>
<p dir="auto">InstrumentAA opens and displays the LibPanel with all libs closed <em>except</em> LibA, and within that CatA is also open...</p>
<p dir="auto">In instrumentAA we close LibA and Open LibB, then we close InstrumentAA,</p>
<p dir="auto">The player opens with all libs closed <em>except</em> LibB</p>
]]></description><link>https://forum.hise.audio/post/119618</link><guid isPermaLink="true">https://forum.hise.audio/post/119618</guid><dc:creator><![CDATA[Lindon]]></dc:creator><pubDate>Mon, 20 Apr 2026 13:11:24 GMT</pubDate></item><item><title><![CDATA[Reply to Player and expansion communication...... on Mon, 20 Apr 2026 13:03:05 GMT]]></title><description><![CDATA[<p dir="auto"><a class="plugin-mentions-user plugin-mentions-a" href="https://forum.hise.audio/uid/67">@Lindon</a> What information does the "state" include?</p>
]]></description><link>https://forum.hise.audio/post/119617</link><guid isPermaLink="true">https://forum.hise.audio/post/119617</guid><dc:creator><![CDATA[David Healey]]></dc:creator><pubDate>Mon, 20 Apr 2026 13:03:05 GMT</pubDate></item></channel></rss>