using SimpleAudioEngine with avaudioRecorder

184 views Asked by At

I know i cant use the SimpleAudioEngine before the avaudioRecorder because it sets the session to play and not record.

If i record with the recorder then play with :

[[SimpleAudioEngine sharedEngine]  playEffect:soundFilePath pitch:2.0f pan:0.0f gain:1.0f];

it works great, but if then i am trying to record again, its not .

i have to play with the SimpleAudioEngine , and i am looking for a way to let it record again after i play.

i have tried after playing to do :

[[AVAudioSession sharedInstance] setCategory:AVAudioSessionCategoryPlayAndRecord error:nil];

with no success .

any help ?

thanks.

0

There are 0 answers