#include "qemu/osdep.h"
-#include "monitor/monitor.h"
+#include "qemu/qemu-print.h"
#include "qapi/error.h"
#include "qemu/error-report.h"
#include "audio.h"
g_free (wav->path);
}
-static void wav_capture (void *opaque, void *buf, int size)
+static void wav_capture(void *opaque, const void *buf, int size)
{
WAVState *wav = opaque;
WAVState *wav = opaque;
char *path = wav->path;
- monitor_printf (cur_mon, "Capturing audio(%d,%d,%d) to %s: %d bytes\n",
- wav->freq, wav->bits, wav->nchannels,
- path ? path : "<not available>", wav->bytes);
+ qemu_printf("Capturing audio(%d,%d,%d) to %s: %d bytes\n",
+ wav->freq, wav->bits, wav->nchannels,
+ path ? path : "<not available>", wav->bytes);
}
static struct capture_ops wav_capture_ops = {
.info = wav_capture_info
};
-int wav_start_capture (CaptureState *s, const char *path, int freq,
- int bits, int nchannels)
+int wav_start_capture(AudioState *state, CaptureState *s, const char *path,
+ int freq, int bits, int nchannels)
{
WAVState *wav;
uint8_t hdr[] = {
goto error_free;
}
- cap = AUD_add_capture (&as, &ops, wav);
+ cap = AUD_add_capture(state, &as, &ops, wav);
if (!cap) {
error_report("Failed to add audio capture");
goto error_free;