An object that plays audio data from a file or buffer.
(파일 또는 버퍼에서 오디오 데이터를 재생하는 개체입니다.)
Declaration
class AVAudioPlayer : NSObject
Overview
Use an audio player to:
(audio player를 사용하여)
- Play audio of any duration from a file or buffer
(파일 또는 버퍼에서 지속적인 오디오 재생)(아마도 버퍼에 저장된 오디오를 계속 끌어와서 플레이하는 느낌)
- Control the volume, panning, rate, and looping behavior of the played audio
(음량 조절, 오디오에 대한 임의 조정, 속도나 루프 제어)
- Access playback-level metering data
(아마도 재생 진행 상황 표시)(같은느낌)
- Play multiple sounds simultaneously by synchronizing the playback of multiple players
(여러 플레이어의 재생을 동기화하여 여러 소리를 동시에 재생)
init(contentsOf:fileTypeHint:)
Creates a player to play audio from a file of a particular type.
특정 유형의 파일에서 오디오를 재생하는 플레이어를 만듭니다.
Parameters
url
- A URL that identifies the local audio file to play.
재생할 로컬 오디오 파일을 식별하는 URL.
- utiString
The Uniform Type Identifier (UTI) string of the file format.
파일 형식의 UTI(Uniform Type Identifier) 문자열입니다.
play()
Plays audio asynchronously.
비동기식으로 오디오를 재생합니다.