43051cec68
* Support for ARM Integrator/CP board system emulation. * Support for MIPS R4K system emulation. * Initial SMP support on x86 (up to 255 CPUs !). * Many new audio emulation features. * Initial USB support. * New networking options for VLAN support between several QEMU instances.
138 lines
4.6 KiB
Text
138 lines
4.6 KiB
Text
$NetBSD: patch-ao,v 1.2 2006/01/01 13:48:45 xtraeme Exp $
|
|
|
|
--- audio/mixeng.c.orig 2005-12-19 17:51:53.000000000 -0500
|
|
+++ audio/mixeng.c
|
|
@@ -101,48 +101,56 @@
|
|
#undef IN_T
|
|
#undef SHIFT
|
|
|
|
+/*
|
|
+ * Work around ugly XX_t #defines in NetBSD 2.x,
|
|
+ * fixed as typedefs in NetBSD 3.x. Two macros needed to
|
|
+ * get CPP defines expanded properly. - HF
|
|
+ */
|
|
+#define _NBglue(x,y,z) x ## y ## z
|
|
+#define NBglue(x,y,z) _NBglue(x,y,z)
|
|
+
|
|
t_sample *mixeng_conv[2][2][2][2] = {
|
|
{
|
|
{
|
|
{
|
|
- conv_natural_uint8_t_to_mono,
|
|
- conv_natural_uint16_t_to_mono
|
|
+ NBglue(conv_natural_, uint8_t, _to_mono),
|
|
+ NBglue(conv_natural_, uint16_t, _to_mono)
|
|
},
|
|
{
|
|
- conv_natural_uint8_t_to_mono,
|
|
- conv_swap_uint16_t_to_mono
|
|
+ NBglue(conv_natural_, uint8_t, _to_mono),
|
|
+ NBglue(conv_swap_, uint16_t, _to_mono)
|
|
}
|
|
},
|
|
{
|
|
{
|
|
- conv_natural_int8_t_to_mono,
|
|
- conv_natural_int16_t_to_mono
|
|
+ NBglue(conv_natural_, int8_t, _to_mono),
|
|
+ NBglue(conv_natural_, int16_t, _to_mono)
|
|
},
|
|
{
|
|
- conv_natural_int8_t_to_mono,
|
|
- conv_swap_int16_t_to_mono
|
|
+ NBglue(conv_natural_, int8_t, _to_mono),
|
|
+ NBglue(conv_swap_, int16_t, _to_mono)
|
|
}
|
|
}
|
|
},
|
|
{
|
|
{
|
|
{
|
|
- conv_natural_uint8_t_to_stereo,
|
|
- conv_natural_uint16_t_to_stereo
|
|
+ NBglue(conv_natural_, uint8_t, _to_stereo),
|
|
+ NBglue(conv_natural_, uint16_t, _to_stereo)
|
|
},
|
|
{
|
|
- conv_natural_uint8_t_to_stereo,
|
|
- conv_swap_uint16_t_to_stereo
|
|
+ NBglue(conv_natural_, uint8_t, _to_stereo),
|
|
+ NBglue(conv_swap_, uint16_t, _to_stereo)
|
|
}
|
|
},
|
|
{
|
|
{
|
|
- conv_natural_int8_t_to_stereo,
|
|
- conv_natural_int16_t_to_stereo
|
|
+ NBglue(conv_natural_, int8_t, _to_stereo),
|
|
+ NBglue(conv_natural_, int16_t, _to_stereo)
|
|
},
|
|
{
|
|
- conv_natural_int8_t_to_stereo,
|
|
- conv_swap_int16_t_to_stereo
|
|
+ NBglue(conv_natural_, int8_t, _to_stereo),
|
|
+ NBglue(conv_swap_, int16_t, _to_stereo)
|
|
}
|
|
}
|
|
}
|
|
@@ -152,44 +160,44 @@ f_sample *mixeng_clip[2][2][2][2] = {
|
|
{
|
|
{
|
|
{
|
|
- clip_natural_uint8_t_from_mono,
|
|
- clip_natural_uint16_t_from_mono
|
|
+ NBglue(clip_natural_, uint8_t, _from_mono),
|
|
+ NBglue(clip_natural_, uint16_t, _from_mono)
|
|
},
|
|
{
|
|
- clip_natural_uint8_t_from_mono,
|
|
- clip_swap_uint16_t_from_mono
|
|
+ NBglue(clip_natural_, uint8_t, _from_mono),
|
|
+ NBglue(clip_swap_, uint16_t, _from_mono)
|
|
}
|
|
},
|
|
{
|
|
{
|
|
- clip_natural_int8_t_from_mono,
|
|
- clip_natural_int16_t_from_mono
|
|
+ NBglue(clip_natural_, int8_t, _from_mono),
|
|
+ NBglue(clip_natural_, int16_t, _from_mono)
|
|
},
|
|
{
|
|
- clip_natural_int8_t_from_mono,
|
|
- clip_swap_int16_t_from_mono
|
|
+ NBglue(clip_natural_, int8_t, _from_mono),
|
|
+ NBglue(clip_swap_, int16_t, _from_mono)
|
|
}
|
|
}
|
|
},
|
|
{
|
|
{
|
|
{
|
|
- clip_natural_uint8_t_from_stereo,
|
|
- clip_natural_uint16_t_from_stereo
|
|
+ NBglue(clip_natural_, uint8_t, _from_stereo),
|
|
+ NBglue(clip_natural_, uint16_t, _from_stereo)
|
|
},
|
|
{
|
|
- clip_natural_uint8_t_from_stereo,
|
|
- clip_swap_uint16_t_from_stereo
|
|
+ NBglue(clip_natural_, uint8_t, _from_stereo),
|
|
+ NBglue(clip_swap_, uint16_t, _from_stereo)
|
|
}
|
|
},
|
|
{
|
|
{
|
|
- clip_natural_int8_t_from_stereo,
|
|
- clip_natural_int16_t_from_stereo
|
|
+ NBglue(clip_natural_, int8_t, _from_stereo),
|
|
+ NBglue(clip_natural_, int16_t, _from_stereo)
|
|
},
|
|
{
|
|
- clip_natural_int8_t_from_stereo,
|
|
- clip_swap_int16_t_from_stereo
|
|
+ NBglue(clip_natural_, int8_t, _from_stereo),
|
|
+ NBglue(clip_swap_, int16_t, _from_stereo)
|
|
}
|
|
}
|
|
}
|