G0.4: save/restore preset quanh reload khi close GUI (captureState/restoreState, memorystream link truc tiep)

This commit is contained in:
2026-08-15 20:04:56 +07:00
parent 5313d85926
commit eac7f2feb8
6 changed files with 77 additions and 1 deletions
@@ -56,6 +56,10 @@ public:
// it to dedupe repeated OPEN_GUI (frontend retry spam) — re-attaching a
// view that is already attached corrupts plugins (Nexus createView→null).
virtual bool hasAttachedView() const { return false; }
// G0.4: serialize/restore the plugin preset across instance reloads
// (GUI close/reopen). Non-VST engines: no-op (nothing to save).
virtual void captureState() {}
virtual void restoreState() {}
// Real-time Audio PCM Float32 rendering loop
virtual void processAudioBlock(float* outputL, float* outputR, uint32_t numSamples) = 0;