From 4309a1f7f4396ac97827494ed4c9f151c5e740de Mon Sep 17 00:00:00 2001 From: Christophe Massiot Date: Thu, 6 Feb 2003 15:14:41 +0000 Subject: [PATCH] Fixed AFMT_AC3 and AFMT_S16_NE handling. --- include/audio_output.h | 5 +---- modules/audio_output/oss.c | 16 +++++++++++++++- 2 files changed, 16 insertions(+), 5 deletions(-) diff --git a/include/audio_output.h b/include/audio_output.h index 5e20a08660..dd04ea57b2 100644 --- a/include/audio_output.h +++ b/include/audio_output.h @@ -2,7 +2,7 @@ * audio_output.h : audio output interface ***************************************************************************** * Copyright (C) 2002 VideoLAN - * $Id: audio_output.h,v 1.76 2003/02/02 00:57:20 jobi Exp $ + * $Id: audio_output.h,v 1.77 2003/02/06 15:14:41 massiot Exp $ * * Authors: Christophe Massiot * @@ -68,9 +68,6 @@ struct audio_sample_format_t # define AOUT_FMT_U16_NE VLC_FOURCC('u','1','6','l') #endif -#define AFMT_S16_NE AOUT_FMT_S16_NE -#define AFMT_U16_NE AOUT_FMT_U16_NE - #define AOUT_FMT_NON_LINEAR( p_format ) \ ( ((p_format)->i_format == VLC_FOURCC('s','p','d','i')) \ || ((p_format)->i_format == VLC_FOURCC('a','5','2',' ')) \ diff --git a/modules/audio_output/oss.c b/modules/audio_output/oss.c index 6d47adb147..1fff18229f 100644 --- a/modules/audio_output/oss.c +++ b/modules/audio_output/oss.c @@ -2,7 +2,7 @@ * oss.c : OSS /dev/dsp module for vlc ***************************************************************************** * Copyright (C) 2000-2002 VideoLAN - * $Id: oss.c,v 1.49 2003/02/02 00:57:21 jobi Exp $ + * $Id: oss.c,v 1.50 2003/02/06 15:14:41 massiot Exp $ * * Authors: Michel Kaempf * Samuel Hocevar @@ -53,6 +53,20 @@ # include #endif +/* Patches for ignorant OSS versions */ +#ifndef AFMT_AC3 +# define AFMT_AC3 0x00000400 /* Dolby Digital AC3 */ +#endif + +#ifndef AFMT_S16_NE +# ifdef WORDS_BIGENDIAN +# define AFMT_S16_NE AFMT_S16_BE +# else +# define AFMT_S16_NE AFMT_S16_LE +# endif +#endif + + /***************************************************************************** * aout_sys_t: OSS audio output method descriptor ***************************************************************************** -- 2.39.2