From 1a4f4f80bf06e6d0a25aabb15adfd15062417991 Mon Sep 17 00:00:00 2001 From: Stefano Pigozzi Date: Thu, 8 May 2014 22:34:21 +0200 Subject: ao_coreaudio: remove useless code This code doesn't actually makes much of a difference, and the AudioUnit mostly wants layout tags anyway. --- audio/out/ao_coreaudio.c | 15 --------------- 1 file changed, 15 deletions(-) (limited to 'audio') diff --git a/audio/out/ao_coreaudio.c b/audio/out/ao_coreaudio.c index c74648cd6b..1d44c81124 100644 --- a/audio/out/ao_coreaudio.c +++ b/audio/out/ao_coreaudio.c @@ -407,21 +407,6 @@ static int init_lpcm(struct ao *ao, AudioStreamBasicDescription asbd) CHECK_CA_ERROR_L(coreaudio_error_audiounit, "can't link audio unit to selected device"); - if (ao->channels.num > 2) { - // No need to set a channel layout for mono and stereo inputs - AudioChannelLayout acl = (AudioChannelLayout) { - .mChannelLayoutTag = kAudioChannelLayoutTag_UseChannelBitmap, - .mChannelBitmap = mp_chmap_to_waveext(&ao->channels) - }; - - err = AudioUnitSetProperty(p->audio_unit, - kAudioUnitProperty_AudioChannelLayout, - kAudioUnitScope_Input, 0, &acl, - sizeof(AudioChannelLayout)); - CHECK_CA_ERROR_L(coreaudio_error_audiounit, - "can't set channel layout bitmap into audio unit"); - } - p->buffer = mp_ring_new(p, get_ring_size(ao)); print_buffer(ao, p->buffer); -- cgit v1.2.3