bugfixes, better MusicXML support and 1.1.0
This commit is contained in:
Vendored
+6
-1
@@ -31,7 +31,12 @@ public func make___FILEBASENAMEASIDENTIFIER___() -> LyrebirdTask {
|
||||
// The example below schedules one short Synthesizer every 250 ms
|
||||
// until `stop()` is called.
|
||||
while true {
|
||||
let note: ExampleNote = ExampleNote()
|
||||
// SynthesizerBase subclasses are @MainActor-isolated; construct on the
|
||||
// main thread synchronously, then hand the instance to ctx.add which
|
||||
// dispatches the engine.add to main via DispatchQueue.main.async.
|
||||
let note: ExampleNote = DispatchQueue.main.sync {
|
||||
MainActor.assumeIsolated { ExampleNote() }
|
||||
}
|
||||
ctx.add(note)
|
||||
try ctx.wait(seconds: 0.25)
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user