diff options
author | Kővágó, Zoltán <dirty.ice.hu@gmail.com> | 2020-02-02 20:38:07 +0100 |
---|---|---|
committer | Gerd Hoffmann <kraxel@redhat.com> | 2020-02-06 14:35:57 +0100 |
commit | ed2a4a794184df3dbd5ee4cc06e86fe220663faf (patch) | |
tree | ed340e8120188691fd89b764ef45ad509005c9a6 /audio/mixeng.h | |
parent | 180b044ffde2cdd4a7209c727b5a8ce93d36741f (diff) |
audio: proper support for float samples in mixeng
This adds proper support for float samples in mixeng by adding a new
audio format for it.
Limitations: only native endianness is supported. None of the virtual
sound cards support float samples (it looks like most of them only
support 8 and 16 bit, only hda supports 32 bit), it is only used for the
audio backends (i.e. host side).
Signed-off-by: Kővágó, Zoltán <DirtY.iCE.hu@gmail.com>
Acked-by: Markus Armbruster <armbru@redhat.com>
Message-id: 8a8b0b5698401b78d3c4c8ec90aef83b95babb06.1580672076.git.DirtY.iCE.hu@gmail.com
Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
Diffstat (limited to 'audio/mixeng.h')
-rw-r--r-- | audio/mixeng.h | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/audio/mixeng.h b/audio/mixeng.h index 7ef61763e8..2dcd6df245 100644 --- a/audio/mixeng.h +++ b/audio/mixeng.h @@ -38,13 +38,13 @@ typedef struct st_sample st_sample; typedef void (t_sample) (struct st_sample *dst, const void *src, int samples); typedef void (f_sample) (void *dst, const struct st_sample *src, int samples); +/* indices: [stereo][signed][swap endiannes][8, 16 or 32-bits] */ extern t_sample *mixeng_conv[2][2][2][3]; extern f_sample *mixeng_clip[2][2][2][3]; -void conv_natural_float_to_stereo(struct st_sample *dst, const void *src, - int samples); -void clip_natural_float_from_stereo(void *dst, const struct st_sample *src, - int samples); +/* indices: [stereo] */ +extern t_sample *mixeng_conv_float[2]; +extern f_sample *mixeng_clip_float[2]; void *st_rate_start (int inrate, int outrate); void st_rate_flow(void *opaque, st_sample *ibuf, st_sample *obuf, |