From 8ead62cfc21f61a32677892c721674e06e9f6153 Mon Sep 17 00:00:00 2001 From: bellard Date: Tue, 4 Jul 2006 16:51:32 +0000 Subject: audio fixes + initial audio capture support (malc) git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@2040 c046a42c-6fe2-441c-8c8c-71466251a162 --- audio/audio_int.h | 18 +++++++++++++++++- 1 file changed, 17 insertions(+), 1 deletion(-) (limited to 'audio/audio_int.h') diff --git a/audio/audio_int.h b/audio/audio_int.h index ca240ccc7b..c01c16add6 100644 --- a/audio/audio_int.h +++ b/audio/audio_int.h @@ -79,6 +79,7 @@ typedef struct HWVoiceOut { int samples; LIST_HEAD (sw_out_listhead, SWVoiceOut) sw_head; + LIST_HEAD (sw_cap_listhead, SWVoiceOut) sw_cap_head; struct audio_pcm_ops *pcm_ops; LIST_ENTRY (HWVoiceOut) entries; } HWVoiceOut; @@ -115,6 +116,7 @@ struct SWVoiceOut { volume_t vol; struct audio_callback callback; LIST_ENTRY (SWVoiceOut) entries; + LIST_ENTRY (SWVoiceOut) cap_entries; }; struct SWVoiceIn { @@ -160,14 +162,28 @@ struct audio_pcm_ops { int (*ctl_in) (HWVoiceIn *hw, int cmd, ...); }; +struct capture_callback { + struct audio_capture_ops ops; + void *opaque; + LIST_ENTRY (capture_callback) entries; +}; + +typedef struct CaptureVoiceOut { + HWVoiceOut hw; + void *buf; + LIST_HEAD (cb_listhead, capture_callback) cb_head; + LIST_ENTRY (CaptureVoiceOut) entries; +} CaptureVoiceOut; + struct AudioState { struct audio_driver *drv; void *drv_opaque; QEMUTimer *ts; - LIST_HEAD (card_head, QEMUSoundCard) card_head; + LIST_HEAD (card_listhead, QEMUSoundCard) card_head; LIST_HEAD (hw_in_listhead, HWVoiceIn) hw_head_in; LIST_HEAD (hw_out_listhead, HWVoiceOut) hw_head_out; + LIST_HEAD (cap_listhead, CaptureVoiceOut) cap_head; int nb_hw_voices_out; int nb_hw_voices_in; }; -- cgit v1.2.3