AudioQueue issue

Member
Posts: 50
Joined: 2008.06
Post: #1
I'm playing some audio, using AudioQueue services, pretty much
straight from the iPhone SpeakHere sample code. I've modified it to
play .amr files (had to turn on something since that is a VBR format)
and it all works perfectly well.

Now I'm trying to skip about in the audio file with a slider and
crashing.

So I thought it might be some buffer issue, so I tried to skip some
packets on the FIRST time I played, no luck there either. It seems
that when you call AudioFileReadPackets that the packet you are
reading must both start at zero and then be sequential from the
previous call to AudioFileReadPackets.
Quote this message in a reply
Nibbie
Posts: 1
Joined: 2008.10
Post: #2
Hi,

I'm just starting to look at the audio aspects of iPhone and saw your post.

I put this line:
[self setStartingPacketNumber:132300];

Inside the 'if' statement in the "initWithURL" method and it starts at that packet when playing the file back. Therefore, you cd use some means of input from the user as to where to start the playback.

I want to use a slider, but I'm not sure how to tell how many packets are in the file???
Quote this message in a reply
Post Reply