bridge: fix Qin VST2 silent playback via per-child SHM sandbox
- out-of-process VST2 sandbox: each Qin track spawns its own plugin_host.exe child with unique SHM (SonicForge_PluginHost2_<bridgePid>_<ch>_<seq>), watchdog <=3 respawns - preset round-trip bridge<->child over SHM (presetIn/presetOut 64KB), stub rejection MIN_PRESET=100 - seed qin_default.b64 default preset into every fresh child; saved patch wins on restore - forward MIDI on channel 0 (Qin_RV only listens on ch0); one instrument per child - controls 4/5/6 = OPEN_GUI/CLOSE_GUI/QUIT - gitignore runtime carla_projects
This commit is contained in:
@@ -87,11 +87,22 @@ struct SharedAudioBufferIPC {
|
||||
// The child renders into the slot it is NOT publishing (writeSlot flips),
|
||||
// then publishes; the bridge reads the published slot. A stale slot is safe
|
||||
// to read (bridge keeps last block), so a slow child never tears audio.
|
||||
// G4.5: preset blob round-trip for VST2 sandbox children. jBridge romplers
|
||||
// like Kong Audio Qin_RV render SILENT from factory state - they need their
|
||||
// program/bank chunk restored (bridge_state presetBase64). presetIn is
|
||||
// bridge->child (base64 text; presetInLen>0 = pending, child applies and
|
||||
// zeroes it). presetOut is child->bridge: the child republishes its chunk
|
||||
// after load / preset apply / GUI edit, so the bridge can persist it.
|
||||
#define PRESET_BLOB_SIZE 65536
|
||||
struct SandboxHostIPC {
|
||||
SharedAudioBufferIPC base; // MIDI/control/heartbeat, offsets unchanged
|
||||
volatile uint32_t writeSlot; // 0 or 1: slot the child finished writing
|
||||
float audioLeft[2][AUDIO_BLOCK_SIZE]; // 2 full blocks
|
||||
float audioRight[2][AUDIO_BLOCK_SIZE];
|
||||
char presetIn[PRESET_BLOB_SIZE]; // bridge -> child (base64 text)
|
||||
volatile uint32_t presetInLen; // >0: pending; child applies + zeroes
|
||||
char presetOut[PRESET_BLOB_SIZE]; // child -> bridge (base64 text)
|
||||
volatile uint32_t presetOutLen; // 0 = none published yet
|
||||
};
|
||||
|
||||
// Shared-memory helpers (impl in SharedMemoryIPC.cpp).
|
||||
|
||||
Reference in New Issue
Block a user