Advertise Mobile SDKs Books Events Forum News Social Networking Support Us
Follow @iphonedevsdk on Twitter

Interface 2, Advanced iOS
Mockup & Code Gen
($9.99)

Make your own iPhone apps
and run them live!
(free)

Pic Frame Dynamo: Photo Editing
($0.99)

Abiliator
($1.99)

Want your application or service advertised on iPhone Dev SDK?

Go Back   iPhone Dev SDK Forum

View Single Post
Old 09-24-2011, 11:45 AM   #5 (permalink)
gammapoint
Registered Member
 
Join Date: Feb 2010
Posts: 12
gammapoint is on a distinguished road
Default

Quote:
Originally Posted by tackey123 View Post
Does anyone know how to write code that would do this:

I have about 12 short audio files (mpegs).

I want to hit a "PLAY" button and have one of those audio files chosen at random to play. It would loop twice and then on the third loop it should crossfade into another randomly chosen piece of audio.

That's it. No stop or pause buttons. Just PLAY and the audio files are chosen to randomly play, crossfading into each other.
Crossfade:

I am trying that to work.

Earlier I tried with one audio player but that won't crossfade.

AVAudioPlayer Class Reference:"Play multiple sounds simultaneously, one sound per audio player, with precise synchronization"



So I am going to try with two or more.

Will update.
gammapoint is offline   Reply With Quote
 

» Advertisements
» Online Users: 418
15 members and 403 guests
Alexanskoo, aziz, diane21, elhanche, freewind, guillermotricia, hrushikeshaddon, iram91418, nicsmotherman, pipposanta, PixelEnvision, poke, QuantumDoja, ryantcb, subhan1
Most users ever online was 1,387, 04-10-2012 at 04:21 AM.
» Stats
Members: 175,609
Threads: 94,084
Posts: 402,783
Top Poster: BrianSlick (7,990)
Welcome to our newest member, diane21
Powered by vBadvanced CMPS v3.1.0

All times are GMT -5. The time now is 04:49 AM.
Powered by vBulletin® Version 3.8.0
Copyright ©2000 - 2012, Jelsoft Enterprises Ltd.