// native_bridge/include/RenderJob.h #ifndef RENDER_JOB_H #define RENDER_JOB_H #include // Offline render mode: `daw_vst_bridge --render --out `. // Parses the job, creates the instrument headless, renders the MIDI notes to // a 16-bit stereo WAV, and exits. Realtime SHM mode is untouched. // // job.json: { instrument_type, plugin_path, preset?, sample_rate?, block_size?, // bpm?, soundfont_bank?, soundfont_program?, // notes: [{pitch?, velocity?, start_beat?, duration_beats?}] } // instrument_type: 0=VST3, 1=VST2, 2=SF2/SF3, 3=SFZ (InstrumentType enum). // pitch/velocity: velocity 0..1 (float) or 0..127; start/duration in beats. // // Returns 0 on success. On failure prints a clear error to stderr and returns // non-zero (1 = job/argument error, 2 = instrument load failure, 3 = plugin // crashed mid-render). Any partial output file is removed. int run_render_job(const std::string& jobPath, const std::string& outPath); #endif // RENDER_JOB_H