# HG changeset patch # User colin # Date 1041605342 0 # Node ID 66f3204117d63d98ea02d4172143dad784dbde1b # Parent a9170a2ab0a4b6c415e0f64c3622fd09b23bcfa0 trivial bigendian fix diff -r a9170a2ab0a4 -r 66f3204117d6 libao2/pl_extrastereo.c --- a/libao2/pl_extrastereo.c Fri Jan 03 13:18:22 2003 +0000 +++ b/libao2/pl_extrastereo.c Fri Jan 03 14:49:02 2003 +0000 @@ -2,7 +2,7 @@ * (linearly increases difference between L&R channels) * * Current limitations: - * - only AFMT_S16_LE is supported currently + * - only AFMT_S16_HE is supported currently * * License: GPLv2 (as a mix of pl_volume.c and * xmms:stereo_plugin/stereo.c) @@ -20,6 +20,7 @@ #include "audio_plugin.h" #include "audio_plugin_internal.h" #include "afmt.h" +#include "../config.h" static ao_info_t info = { "Extra stereo plugin", @@ -57,7 +58,11 @@ // return: 1=success 0=fail static int init(){ switch(ao_plugin_data.format){ +#ifndef WORDS_BIGENDIAN case(AFMT_S16_LE): +#else + case(AFMT_S16_BE): +#endif break; default: fprintf(stderr,"[pl_extrastereo] Audio format not yet suported \n"); @@ -87,7 +92,11 @@ static int play(){ switch(pl_extrastereo.format){ +#ifndef WORDS_BIGENDIAN case(AFMT_S16_LE): { +#else + case(AFMT_S16_BE): { +#endif int16_t* data=(int16_t*)ao_plugin_data.data; int len=ao_plugin_data.len / 2; // 16 bits samples