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
1
vote
0 answers

Unable to play ACC stream using AVSampleBufferAudioRenderer

I am working on an app that receives a stream of packets with video and audio. I was able to decode the video and play it using AVSampleBufferDisplayLayer. (Code can be found here) But I've been struggling for over a week to decode the audio. At the…
Ender
  • 13
  • 4
1
vote
2 answers

AudioUnit framework not found

I am implementing an audio based application, in that I need to play both application audio and ipod auido. When I try to run my application I am getting an error like, ld: framework not found AudioUnit collect2: ld returned 1 exit status Command…
Sekhar Bhetalam
  • 4,501
  • 6
  • 33
  • 52
1
vote
1 answer

Can't play sound after setting Hog mode

I try to play an audio file with AVAudioEngine and AVAudioPlayerNode to an USB device (DAC). When I set the device in Hog Mode, the sound is not played but it works great without Hog Mode. I also try with AVAudioPlayer, and it doesn't work…
Carbonimax
  • 13
  • 1
  • 3
1
vote
1 answer

iPhone - AudioToolbox and recording

In my application, I'm playing an audio using audio toolbox framework. When its playing, how can I record the same? I tried using AVAudioRecording by setting audio session "Play and Record". But when recording, the volume of the audio being played…
Satyam
  • 15,493
  • 31
  • 131
  • 244
1
vote
1 answer

Disable sound through speaker while recording audio using AUAudioUnit

I try to record audio using AUAudioUnit. I successfully get audio buffers but I also hear recorded sound through the speaker while recording. The question is how to get just buffers not passing sound to the speaker? func startRecording() { …
Bambuh
  • 21
  • 1
  • 4
1
vote
1 answer

Distorted audio when converting PCM to AAC using AudioConverter and writing to .mp4 file using AVAssetWriter

I'm trying to compress input from AVCaptureSession and save it to an .mp4 file. I've managed to convert and save video but am having trouble with audio. I've reached a point where I'm using https://github.com/nevyn/LBMediaToolkit to convert audio. I…
1
vote
1 answer

What is Audio level metering in iPhone Audio Tool box?

What is Audio level metering in iPhone Audio Tool box? What is the use of it?
RK-
  • 12,099
  • 23
  • 89
  • 155
1
vote
0 answers

AudioToolBox crash report only in iOS 12.3 above OS apple devices

From iOS 12.3 and above iOS versions we are getting AudioToolBox crashes, we do not know why these crashes are happening. We have Crashlytics Crash report but we are not able to debug the issue with the help of Crashlytics crash report. I have…
reddy007
  • 11
  • 2
1
vote
1 answer

How to make a long vibration in iOS

I want to make a button that you press and your phone vibrates. When you release, the vibration should stop. Ideally, it will have touch sensitivity, so the harder you press, the stronger the buzz.…
1
vote
0 answers

CMSampleBuffer from Replay Kit after encoding to Mpeg-TS Video is normal, Audio is corrupted

I am trying to stream AAC encoded audio data received as CMSampleBuffer. AudioConverterFillComplexBuffer returns 0 status code. But after passing this data to my FFMPEG HLSWriter audio is not correctly saved (short truncated signals). Below is the…
Sos A
  • 23
  • 5
1
vote
0 answers

Audiotoolbox API AudioConvertNewSpecific returning wrong output packet size when converting to G711u instead of AAC in Objective C

I am trying to convert the RAW PCM buffers to G711u Codec in IOS using Audio Toolbox. I see many code examples working for the AAC codec using the same code and APIs.But when I try to do it for PCMU then it is not working. AudioConverter is setup…
Varun
  • 11
  • 2
1
vote
0 answers

Two simultaneous AVAudioSessions

I have an app that uses WebRTC for voice chat. After a lot of troubleshooting I came to the conclusion that whenever I receive a stream, the WebRTC will set the AVAudioSession shared instance to the following: try…
Tarek
  • 783
  • 10
  • 31
1
vote
0 answers

No Sound on iPhone Simulator - xcode 10, Swift 4

I am trying to make the xcode simulated iPhone play a wav audio file when one of 7 buttons from the UI interface are pressed. The code is the following: import UIKit import AudioToolbox class ViewController: UIViewController{ override func…
1
vote
2 answers

Differences in audio frameworks on iPhone 3G, 3GS and 4

I'm building an app that measures sound volume. I understand that audio hardware in the iPhone is not as accurate as professional hardware, which is OK, but I need to know if there are any differences between the different iPhone models. For…
Rits
  • 5,105
  • 4
  • 42
  • 53
1
vote
0 answers

Swift AudioToolbox not playing back audio file nor filling audio buffer

I am trying to play back an audio file using AudioToolbox. I wrote this and swift based on an old objective C example on the apple website. It compiles and runs, however the callback function never gets triggered once CFRunLoop starts. (It gets…
dmann200
  • 529
  • 4
  • 11