Guest User

Untitled

a guest
Feb 20th, 2018
77
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.45 KB | None | 0 0
  1. // Setup input source
  2. let audioSession = AVAudioSession.sharedInstance()
  3. do {
  4. //try audioSession.setCategory(AVAudioSessionCategoryRecord, with: .allowBluetooth)
  5. try audioSession.setCategory(AVAudioSessionCategoryRecord)
  6. try audioSession.setMode(AVAudioSessionModeMeasurement)
  7. try audioSession.setActive(true, with: .notifyOthersOnDeactivation)
  8. } catch {
  9. print("audioSession properties weren't set because of an error.")
  10. }
Add Comment
Please, Sign In to add comment