We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 7446acd commit 1baba79Copy full SHA for 1baba79
Cookbook/Cookbook/CookbookApp.swift
@@ -15,10 +15,14 @@ struct CookbookApp: App {
15
// Settings.sampleRate default is 44_100
16
if #available(iOS 18.0, *) {
17
if !ProcessInfo.processInfo.isMacCatalystApp && !ProcessInfo.processInfo.isiOSAppOnMac {
18
- // iOS 18 app (not on Mac)
+ // Set samplerRate for iOS 18 and newer
19
Settings.sampleRate = 48_000
20
}
21
22
+ if #available(macOS 15.0, *) {
23
+ // Set samplerRate for macOS 15 and newer
24
+ Settings.sampleRate = 48_000
25
+ }
26
27
try AVAudioSession.sharedInstance().setPreferredIOBufferDuration(Settings.bufferLength.duration)
28
try AVAudioSession.sharedInstance().setCategory(.playAndRecord,
0 commit comments