static void coreaudio_logstatus (OSStatus status)
{
- char *str = "BUG";
+ const char *str = "BUG";
switch(status) {
case kAudioHardwareNoError:
break;
default:
- AUD_log (AUDIO_CAP, "Reason: status code %ld\n", status);
+ AUD_log (AUDIO_CAP, "Reason: status code %" PRId32 "\n", (int32_t)status);
return;
}
return 0;
}
-static int coreaudio_run_out (HWVoiceOut *hw)
+static int coreaudio_run_out (HWVoiceOut *hw, int live)
{
- int live, decr;
+ int decr;
coreaudioVoiceOut *core = (coreaudioVoiceOut *) hw;
if (coreaudio_lock (core, "coreaudio_run_out")) {
return 0;
}
- live = audio_pcm_hw_get_live_out (hw);
-
if (core->decr > live) {
ldebug ("core->decr %d live %d core->live %d\n",
core->decr,
&core->audioDevicePropertyBufferFrameSize);
if (status != kAudioHardwareNoError) {
coreaudio_logerr2 (status, typ,
- "Could not set device buffer frame size %ld\n",
- core->audioDevicePropertyBufferFrameSize);
+ "Could not set device buffer frame size %" PRIu32 "\n",
+ (uint32_t)core->audioDevicePropertyBufferFrameSize);
return -1;
}
}
static struct audio_option coreaudio_options[] = {
- {.name = "BUFFER_SIZE",
- .tag = AUD_OPT_INT,
- .valp = &conf.buffer_frames,
- .descr = "Size of the buffer in frames"},
- {.name = "BUFFER_COUNT",
- .tag = AUD_OPT_INT,
- .valp = &conf.nbuffers,
- .descr = "Number of buffers"},
+ {
+ .name = "BUFFER_SIZE",
+ .tag = AUD_OPT_INT,
+ .valp = &conf.buffer_frames,
+ .descr = "Size of the buffer in frames"
+ },
+ {
+ .name = "BUFFER_COUNT",
+ .tag = AUD_OPT_INT,
+ .valp = &conf.nbuffers,
+ .descr = "Number of buffers"
+ },
{ /* End of list */ }
};