2017-10-03 6 views
1

AVAudioSessionRouteChangeReason 알림을 조사했습니다. 입력 및 출력 포트의 설정은 변경되지 않았습니다 AVAudioSessionRouteChangeReasonRouteConfigurationChange어떤 시나리오에서 AVAudioSessionRouteChangeReasonRouteConfigurationChange를 호출 할 수 있습니까?

하지만, 그 구성은-에 대한 한 예를 들어, 포트의 선택된 데이터 소스가 변경되었습니다 : 그들 중 하나는 애플 문서에 따르면

AVAudioSessionRouteChangeReasonRouteConfigurationChange 

입니다.

AVAudioSessionRouteChangeReasonRouteConfigurationChange가 호출 될 수있는 시나리오가 명확하지 않습니다. 누군가가 포트의 선택된 데이터 소스가 의미를 바꾸는 것을 모범으로 삼을 수 있다면?

감사

답변

0

나는뿐만 아니라 '독'대답을 찾고 있어요,하지만 난 또한 몇 가지 예를 제공 할 수 있습니다.

{ 
AVAudioSessionRouteChangePreviousRouteKey = "<AVAudioSessionRouteDescription: 0x1c001e380, \ninputs = (null); \noutputs = (\n \"<AVAudioSessionPortDescription: 0x1c001e4d0, type = Speaker; name = G\\U0142o\\U015bnik; UID = Speaker; selectedDataSource = (null)>\"\n)>";  
AVAudioSessionRouteChangeReasonKey = 8; 
} 

새로운 경로이었다 :

<AVAudioSessionRouteDescription: 0x1c401de70, 
inputs = (
    "<AVAudioSessionPortDescription: 0x1c401dac0, type = MicrophoneBuiltIn; name = iPhone Mikrofon; UID = Built-In Microphone; selectedDataSource = Bottom>" 
); 
outputs = (
    "<AVAudioSessionPortDescription: 0x1c401df10, type = Speaker; name = G\U0142o\U015bnik; UID = Speaker; selectedDataSource = (null)>" 
)> 

은 그래서 바닥에 널 (null)로 변경 마이크 선택한 데이터 소스처럼 보이는 전화 통화 후 나는 AVAudioSessionInterruptionTypeEnded 통지를받은 그냥이 하나가 후했다.