0
0
mirror of https://github.com/mpv-player/mpv.git synced 2024-09-20 12:02:23 +02:00

ao_coreaudio: change physical stream format synchronously

This commit is contained in:
wm4 2015-06-09 18:23:44 +02:00
parent 211088943c
commit b7d833c2a6
2 changed files with 2 additions and 5 deletions

View File

@ -224,10 +224,7 @@ static void init_physical_format(struct ao *ao)
&p->original_asbd);
CHECK_CA_WARN("could not get current physical stream format");
ca_print_asbd(ao, "Trying to set physical format:", &best_asbd);
err = CA_SET(streams[i], kAudioStreamPropertyPhysicalFormat,
&best_asbd);
CHECK_CA_ERROR("could not set physical format");
ca_change_physical_format_sync(ao, streams[i], best_asbd);
break;
}
}

View File

@ -456,7 +456,7 @@ bool ca_change_physical_format_sync(struct ao *ao, AudioStreamID stream,
OSStatus err = noErr;
bool format_set = false;
ca_print_asbd(ao, "setting stream format:", &change_format);
ca_print_asbd(ao, "setting stream physical format:", &change_format);
sem_t wakeup;
if (sem_init(&wakeup, 0, 0)) {