Sto provando a riprodurre un file .amr.Come riprodurre un file audio AMR?
func prepareAudio() {
do {
self.audioPlayer = try AVAudioPlayer(contentsOfURL: NSURL(fileURLWithPath: NSBundle.mainBundle().pathForResource("welcome", ofType: "amr")!))
self.audioPlayer.play()
} catch {
print("Error")
}
}
outPut
ERROR: >aq> 327: AudioConverterNew from AudioQueueNew returned 'fmt?'
io: 1 ch, 8000 Hz, Float32
client: 1 ch, 8000 Hz, 'samr' (0x00000000) 0 bits/channel, 0 bytes/packet, 2400 frames/packet, 0 bytes/frame
AMR non è più supportato da AVPlayer: http://stackoverflow.com/questions/24103790/avaudioplayer-do-not-play-amr-files – Moritz