From 20727f5f09723a5a9949f12bb5d3bf66f84752b0 Mon Sep 17 00:00:00 2001 From: Paolo Marrone Date: Tue, 9 Jul 2024 12:20:18 +0200 Subject: [PATCH] ifdef fix --- templates/ios/src/native.mm | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/templates/ios/src/native.mm b/templates/ios/src/native.mm index ba0b404..086999c 100644 --- a/templates/ios/src/native.mm +++ b/templates/ios/src/native.mm @@ -301,7 +301,10 @@ char audioStart() { #endif plugin_set_sample_rate(&instance, (float)device.sampleRate); - sample_rate = (float)device.sampleRate; +#ifdef PARAM_OUT_CPU_INDEX + sample_rate = (float)device.sampleRate; +#endif + size_t req = plugin_mem_req(&instance); if (req != 0) { mem = malloc(req);