Mercurial > mplayer.hg
diff libmpcodecs/ad_libvorbis.c @ 27397:d47744b95b78
Give a CONFIG_ prefix to preprocessor directives that lacked one and
change arbitrary prefixes to CONFIG_.
| author | diego |
|---|---|
| date | Thu, 07 Aug 2008 12:20:50 +0000 |
| parents | 21ce55d8dde0 |
| children | 21779d5ea61c |
line wrap: on
line diff
--- a/libmpcodecs/ad_libvorbis.c Thu Aug 07 11:58:37 2008 +0000 +++ b/libmpcodecs/ad_libvorbis.c Thu Aug 07 12:20:50 2008 +0000 @@ -20,7 +20,7 @@ LIBAD_EXTERN(libvorbis) -#ifdef TREMOR +#ifdef CONFIG_TREMOR #include <tremor/ivorbiscodec.h> #else #include <vorbis/codec.h> @@ -34,7 +34,7 @@ vorbis_dsp_state vd; /* central working state for the packet->PCM decoder */ vorbis_block vb; /* local working space for packet->PCM decode */ float rg_scale; /* replaygain scale */ -#ifdef TREMOR +#ifdef CONFIG_TREMOR int rg_scale_int; #endif } ov_struct_t; @@ -160,7 +160,7 @@ /* replaygain: security */ if(ov->rg_scale > 15.) ov->rg_scale = 15.; -#ifdef TREMOR +#ifdef CONFIG_TREMOR ov->rg_scale_int = (int)(ov->rg_scale*64.f); #endif mp_msg(MSGT_DECAUDIO,MSGL_V,"OggVorbis: Bitstream is %d channel%s, %dHz, %dbit/s %cBR\n",(int)ov->vi.channels,ov->vi.channels>1?"s":"",(int)ov->vi.rate,(int)ov->vi.bitrate_nominal, @@ -218,7 +218,7 @@ { int len = 0; int samples; -#ifdef TREMOR +#ifdef CONFIG_TREMOR ogg_int32_t **pcm; #else float scale; @@ -250,7 +250,7 @@ /* convert floats to 16 bit signed ints (host order) and interleave */ -#ifdef TREMOR +#ifdef CONFIG_TREMOR if (ov->rg_scale_int == 64) { for(i=0;i<ov->vi.channels;i++){ ogg_int16_t *convbuffer=(ogg_int16_t *)(&buf[len]); @@ -272,15 +272,15 @@ } } } else -#endif /* TREMOR */ +#endif /* CONFIG_TREMOR */ { -#ifndef TREMOR +#ifndef CONFIG_TREMOR scale = 32767.f * ov->rg_scale; #endif for(i=0;i<ov->vi.channels;i++){ ogg_int16_t *convbuffer=(ogg_int16_t *)(&buf[len]); ogg_int16_t *ptr=convbuffer+i; -#ifdef TREMOR +#ifdef CONFIG_TREMOR ogg_int32_t *mono=pcm[i]; for(j=0;j<bout;j++){ int val=(mono[j]*ov->rg_scale_int)>>(9+6); @@ -297,7 +297,7 @@ val=-32768; clipflag=1; } -#endif /* TREMOR */ +#endif /* CONFIG_TREMOR */ *ptr=val; ptr+=ov->vi.channels; }
