Engine.isRendering()
-
Having this would be a fantastic addition for all sorts of things. Is that possible, @Christoph-Hart ?
-
@tomekslesicki what do you expect it to return? There's a watchdog that notifies you when the plugin is bypassed that was added recently (although @Dan-Korneff has a few issues with getting it to work correctly), so maybe you can use this?
-
I agree. Probably clearer to name it something like TransportHandler.isOfflineRender() as some DAWs let you do a non-offline render.
This would be great to enable higher quality outputs using oversampling, smaller block sizes, different convolution etc.
While working, you can have one setup running for lower CPU usage, and when exporting or freezing it can be a whole other thing like more mics in use etc.
-
@Christoph-Hart I'd like it to let the plugin know when the audio is being bounced. This could be used for a multitude of things, like killing audio with demo licenses, oversampling on bounce, enabling all sorts of HQ modes and CPU-heavier processing, disabling some stuff (like Sonarworks speaker callibration for example) etc.
-
@aaronventure yup, exactly!
-
@aaronventure Usage would then be
on transport start if offline render adjust parameters like mic bypass, block size, oversampling else keep it at default or whatever is set in the settings for realtime
-
Alright, I've added
TransportHandler.isNonRealtime()
that you then can query in the transport start / stop callbacks. I initially thought to let it register to the actual event of switching between realtime and non realtime, but this is a bit cleaner actually.I've also refactored the code from
Engine.renderAudio()
into a base class and added a "DAW Bounce" simulator in the HISE controller popup using the same logic. If you have a MIDI clip in the timeline you can press the export button and it will render the MIDI clip on a background thread in non-realtime, this way you can simulate this behaviour without having to check your compiled plugin.const var transportHandler = Engine.createTransportHandler(); inline function onStartStop(isPlaying) { Console.print(transportHandler.isNonRealtime()); } transportHandler.setOnTransportChange(SyncNotification, onStartStop);
-
@Christoph-Hart fantastic, thank you!