Questions tagged [extaudiofileread]

10 questions
4
votes
1 answer

Looping AAC file with ExtAudioFileRead - bug?

Reading audio files on iOS with ExtAudioFileRead, it seems that reaching eof completely freezes the reader… Example, assumes _abl AudioBufferList and _eaf ExtendedAudioFileRef are allocated and correctly configured: - ( void )testRead { UInt32…
Gregzo
  • 1,194
  • 7
  • 18
2
votes
0 answers

AudioFileReadBytes error -38

I have a .aif file which I try to read and add to a char* buffer. After the first read, I get the -38 error. What does it mean and how to solve this? Here is my code: NSBundle *mainBundle = [NSBundle mainBundle]; NSString *filename = [NSString…
just ME
  • 1,817
  • 6
  • 32
  • 53
1
vote
1 answer

ExtAudioFileRead is too slow. How to make it faster?

I've written my own audio library. (Silly, I know but I enjoy it.) Right now, I'm using it to play stereo files from the iPod library on iOS. It works well except that sometimes the call to ExtAudioFileRead() takes longer than 23ms. Since my…
1
vote
1 answer

Glitches occur when data is read using ExtAudioFile in combination with a circular buffer

I am trying to process audio data that is read using ExtAudioFile. However when I try to put this data in a circular buffer I hear several glitches. In the example code below I pass data from "inBuffer" directly to "outBuffer" (both of type…
Gerard
  • 349
  • 2
  • 16
1
vote
0 answers

Playing audio using kAudioUnitSubType_AudioFilePlayer

I successfully implemented an audio file player using the remote I/O audio unit and a render callback where I use ExtAudioFileRead to render audio frames. At this moment I was just wondering what the difference would be of using…
Gerard
  • 349
  • 2
  • 16
0
votes
0 answers

Decoding AAC ADTS to PCM (weird sound)

I'm trying to decode AAC to PCM and everything seems to be working okay. The problem is that I can hear an strange sound in my audio file (Like a snake) :) The audio file is this one:…
Pablo Martinez
  • 1,573
  • 12
  • 31
0
votes
1 answer

Playing .caf audio file with ExtAudioFileRead is not sync

My app does huge data processing on audio coming from the mic input. In order to get a "demo mode", I want to do the same thing based on a local .caf audio file. I managed to get the audio file. Now I am trying to use ExtAudioFileRead to read the…
jcr
  • 303
  • 1
  • 6
  • 16
0
votes
1 answer

Reducing amplitude of output from ExtAudioFileRead

I'm looking to reduce the amplitude of ExtAudioFileRead's output before resaving it to file. Here's my original code: AudioBufferList convertedData; convertedData.mNumberBuffers=1; …
Rogare
  • 3,234
  • 3
  • 27
  • 50
0
votes
1 answer

Core Audio Large (Compressed) File Playback and Memory Footprint

So, I have setup a multichannel mixer and a Remote I/O unit to mix/play several buffers of PCM data that I read from audio files. For short sound effects in my game, I load the whole file into a memory buffer using ExtAudioFileRead(). For my…
Nicolas Miari
  • 16,006
  • 8
  • 81
  • 189
0
votes
1 answer

What causes ExtAudioFileRead to make ioData->mBuffers[0].mDataByteSize negative?

The problem occurs when I often stop and start audio playback and seek a lot back and forth in an AAC audio file through an ExtAudioFileRef object. In few cases, this strange behaviour is shown by ExtAudioFileRead: Sometimes it assigns these numbers…
Daniel S.
  • 6,458
  • 4
  • 35
  • 78