Questions tagged [audiotoolbox]

The Audio Toolbox framework provides interfaces for recording, playback, and stream parsing. In iOS, the framework provides additional interfaces for managing audio sessions.

Audio Toolbox Framework Reference

366 questions
6
votes
3 answers

Basic math behind mixing audio channels

I have an app where I flick the touchscreen and unleash a dot which animates across the screen, reads the pixel color under is, and converts that to audio based on some parameters. This is working great for the most part. Currently I'm creating one…
VaporwareWolf
  • 10,143
  • 10
  • 54
  • 80
5
votes
2 answers

AudioServicesAddSystemSoundCompletion under ARC using __bridge

I hope the title is not too misleading... :) I play a system sound and add the SoundCompletion-Callback to it like so: AudioServicesAddSystemSoundCompletion(soundID, NULL, NULL, completionCallback, (__bridge_retained void *)self); Whereas «self» is…
Swissdude
  • 3,486
  • 3
  • 35
  • 68
5
votes
3 answers

Audio Output Routes for AirPlay

I have looked but can't find a way to access the Audio Output Routes so i can detect if the audio is coming out via AirPlay. This is what i found in the Documentation for iOS 5.0 kAudioSessionOutputRoute_AirPlay Discussion These strings are used…
Bassem
  • 119
  • 2
  • 7
5
votes
1 answer

Crashed: AVAudioSession Notify Thread in iOS

I am getting EXC_BAD_ACCESS crash that occurs in the AudioToolBox. How to handle interrupts properly? Please have a look at crashlytics screenshot for more info.
Vinu David Jose
  • 2,569
  • 1
  • 21
  • 38
5
votes
1 answer

How to create a MIDI file with Swift?

I'm currently learning how use MIDI with swift. I sought how to create a MIDI file, but that sound like not so easy. I checked frameworks like AudioKit, but i don't find too. Which's informations i need to learn doing it? (for example to know MIDI…
Kyz
  • 141
  • 9
5
votes
1 answer

Convert Recorded sound in iphone from one format to another say wav to mp3

I am trying to record some audio and convert them to other sound formats. I am using AVAudioRecorder class to record and these are the recording settings I used.. NSDictionary *recordSetting = [[NSMutableDictionary alloc] init]; [recordSetting…
5
votes
1 answer

How to get Mac audio level?

Currently, I have code that successfully returns the value of the users system audio value that they can set with the volume keys. However, what I want is a value of the audio the speakers are playing. So if the user is watching Netflix and a…
user2284295
4
votes
3 answers

MonoTouch: Playing sound

I am trying to play a short sound when user taps on the specific button. But the problem is that I always receive Object reference not set to an instance object. means Null! I first tried…
Peyman
  • 3,059
  • 1
  • 33
  • 68
4
votes
1 answer

Is AudioServicesDisposeSystemSoundID required?

I recently started working with the AudioToolbox framework and noticed that there is a method called AudioServicesDisposeSystemSoundID(). Just to know, is it a memory leak not to call the above method when calling AudioServicesCreateSystemSoundID()…
Matoe
  • 2,742
  • 6
  • 33
  • 52
4
votes
1 answer

Playback MP3 data buffer using AudioQueue Service : Prime failed (-50)

These days I was struggling for finding the way to playback network audio stream (in MP3 packet format) using AudioQueue Service on iPhone. To achieve this target successively, I firstly got the common local MP3 file to playback using AudioQueue,…
4
votes
5 answers

AudioToolbox/OpenAL ExtAudioFile to play compressed audio

I'm currently using OpenAL to play game music. It works fine, except that it doesn't work with anything except for raw WAV files. This means that I end up with a ~9mb soundtrack. I'm new to OpenAL, and I'm using code directly from Apple's example…
Greg
  • 9,068
  • 6
  • 49
  • 91
4
votes
3 answers

AudioQueueStart is returning error code -50

Start audio recording giving error sometimes and below method returns error Error Domain=NSOSStatusErrorDomain Code=-50 "(null)" UserInfo= status = AudioQueueStart(_state.queue, NULL); Followed below steps for recording audo - Created a…
Sudhakar Tharigoppula
  • 2,857
  • 3
  • 16
  • 17
4
votes
2 answers

Playing multi-sampled Instruments using AudioKit, controlling ADSR envelope

I'm trying to play instrument of several .wav samples using AudioKit. I've tried so far: Using AKSampler (with underlying AVAudioUnitSampler) – it worked fine, but I can't figure out how to control ADSR envelope here – calling stop will stop note…
Pavel Alexeev
  • 6,026
  • 4
  • 43
  • 51
4
votes
1 answer

iPhone AudioServicesPlaySystemSound: route though headphones?

I'm having trouble using AudioServicesPlaySystemSound. Things work great when output goes through the speakers. However, when a user plugs in headphones, there is no output. Is there an easy way to set up some kind of listener so that audio is…
Chris Ladd
  • 2,795
  • 1
  • 29
  • 22
4
votes
1 answer

AudioQueueNewInput callback latency

Regardless of the size of the buffers I provide the callback provided to AudioQueueNewInput occurs at roughly the same time interval. For example: If you have .05 second buffers and are recording at 44k the callback first called about at .09…
madmik3
  • 6,975
  • 3
  • 38
  • 60
1 2
3
24 25