Files
Lyrebird/docs/roadmap/auv3-extension-project.md
T
2026-06-01 18:27:40 -07:00

77 lines
3.0 KiB
Markdown

# AUv3 Extension Project (Phase 104b sketch)
Phase 104a ships only the Swift API surface (``LyrebirdAudioUnit``,
``AUv3Driver``, parameter mapping, ring buffer, `fullState`). Wrapping that as
an actual `.appex` plugin is Phase 104b's job, which lives in a separate
Xcode-managed sub-directory because SwiftPM cannot build app extensions.
This file is the planning sketch for that work — kept as a roadmap entry so
contributors can pick it up after 104a lands.
## Demos/LyrebirdAUv3Demo layout (104b)
```
Demos/LyrebirdAUv3Demo/
LyrebirdAUv3Demo.xcodeproj
LyrebirdAUv3Demo/ container app target
LyrebirdAUv3DemoApp.swift minimal SwiftUI app entry
ContentView.swift "Install me so the AU registers"
Info.plist
LyrebirdFMExtension/ .appex AUv3 extension target
LyrebirdFM.swift example SynthesizerBase subclass
LyrebirdFMAudioUnit.swift LyrebirdAudioUnit subclass
LyrebirdFMAudioUnitViewController.swift empty AUViewController (104c populates)
Info.plist AudioComponents declaration
README.md "How to copy this template"
```
## Example AudioComponentDescription
```xml
<key>NSExtension</key>
<dict>
<key>NSExtensionAttributes</key>
<dict>
<key>AudioComponents</key>
<array>
<dict>
<key>type</key> <string>aumu</string>
<key>subtype</key> <string>LBFM</string>
<key>manufacturer</key><string>RLZS</string>
<key>name</key> <string>Realized Sound: LyrebirdFM</string>
<key>version</key> <integer>1</integer>
<key>factoryFunction</key><string>...</string>
<key>sandboxSafe</key><true/>
<key>tags</key> <array><string>Synth</string></array>
</dict>
</array>
</dict>
<key>NSExtensionPointIdentifier</key>
<string>com.apple.AudioUnit-UI</string>
<key>NSExtensionPrincipalClass</key>
<string>$(PRODUCT_MODULE_NAME).LyrebirdFMAudioUnitViewController</string>
</dict>
```
## Validation pass
- `auval -v aumu LBFM RLZS` from terminal — must produce a `PASS` summary.
- Load in Logic Pro / GarageBand / AUM / Loopy Pro and verify the plugin
instantiates, exposes its parameters, and plays back via host MIDI.
## auval pitfalls 104a already handles
- `parameterTree` non-nil before `allocateRenderResources` ✓
- `latency` returns finite value (0 for instrument) ✓
- `tailTime` returns 0 for instrument ✓
- `internalRenderBlock` returns `noErr` and writes into the supplied ABL ✓
- `maximumFramesToRender` honoured by the driver's ring sizing ✓
## Open items handed off to 104b
- Code-signing scheme (Josh's team ID or placeholder for forks).
- iOS app-extension entitlements (`com.apple.security.app-sandbox` etc.).
- Embedding the SwiftPM `Lyrebird` package as a local dependency of the
Xcode project (vs. publishing the package to a registry).
- README walkthrough of "how to fork this template for your own synth".