expo-juce 0.2.20 → 0.2.22
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/ios/ExpoJuceModule.swift +2 -7
- package/ios/JuceToneGenerator.mm +8 -11
- package/package.json +1 -1
package/ios/ExpoJuceModule.swift
CHANGED
|
@@ -24,13 +24,8 @@ public class ExpoJuceModule: Module {
|
|
|
24
24
|
// ── Synth ───────────────────────────────────────────────────────
|
|
25
25
|
|
|
26
26
|
Function("setup") {
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
self?.sendEvent("onBeat", [
|
|
30
|
-
"beat": beat,
|
|
31
|
-
"bpm": bpm,
|
|
32
|
-
])
|
|
33
|
-
}
|
|
27
|
+
NSLog("[ExpoJuce] setup called from JS (NO-OP diagnostic)")
|
|
28
|
+
// DIAGNOSTIC: skip all native calls to isolate crash
|
|
34
29
|
}
|
|
35
30
|
|
|
36
31
|
Function("playTone") { (frequency: Double, duration: Double) -> String in
|
package/ios/JuceToneGenerator.mm
CHANGED
|
@@ -313,19 +313,14 @@ private:
|
|
|
313
313
|
// ── Synth Methods ─────────────────────────────────────────────────
|
|
314
314
|
|
|
315
315
|
- (void)playToneWithFrequency:(double)frequency duration:(double)duration {
|
|
316
|
-
NSLog(@"[ExpoJuce] playTone freq=%.1f dur=%.0f", frequency, duration);
|
|
317
|
-
|
|
318
|
-
|
|
319
|
-
self.engine->setFrequency(frequency);
|
|
320
|
-
self.engine->noteOn();
|
|
321
|
-
|
|
322
|
-
dispatch_after(dispatch_time(DISPATCH_TIME_NOW, (int64_t)(duration / 1000.0 * NSEC_PER_SEC)), dispatch_get_main_queue(), ^{
|
|
323
|
-
self.engine->noteOff();
|
|
324
|
-
});
|
|
316
|
+
NSLog(@"[ExpoJuce] playTone freq=%.1f dur=%.0f (NO-OP)", frequency, duration);
|
|
317
|
+
// DIAGNOSTIC: skip C++ call
|
|
325
318
|
}
|
|
326
319
|
|
|
327
320
|
- (void)setFrequency:(double)frequency {
|
|
321
|
+
NSLog(@"[ExpoJuce] setFrequency: %.1f, engine=%p", frequency, self.engine);
|
|
328
322
|
if (self.engine) self.engine->setFrequency(frequency);
|
|
323
|
+
NSLog(@"[ExpoJuce] setFrequency done");
|
|
329
324
|
}
|
|
330
325
|
|
|
331
326
|
- (void)setLevel:(double)level {
|
|
@@ -357,13 +352,15 @@ private:
|
|
|
357
352
|
}
|
|
358
353
|
|
|
359
354
|
- (void)noteOn {
|
|
360
|
-
NSLog(@"[ExpoJuce] noteOn");
|
|
355
|
+
NSLog(@"[ExpoJuce] noteOn, engine=%p", self.engine);
|
|
361
356
|
if (self.engine) self.engine->noteOn();
|
|
357
|
+
NSLog(@"[ExpoJuce] noteOn done");
|
|
362
358
|
}
|
|
363
359
|
|
|
364
360
|
- (void)noteOff {
|
|
365
|
-
NSLog(@"[ExpoJuce] noteOff");
|
|
361
|
+
NSLog(@"[ExpoJuce] noteOff, engine=%p", self.engine);
|
|
366
362
|
if (self.engine) self.engine->noteOff();
|
|
363
|
+
NSLog(@"[ExpoJuce] noteOff done");
|
|
367
364
|
}
|
|
368
365
|
|
|
369
366
|
// ── DSP Params ────────────────────────────────────────────────────
|