diff sonic.c @ 8590:7a463923ecd1 libavcodec

Change semantic of CONFIG_*, HAVE_* and ARCH_*. They are now always defined to either 0 or 1.
author aurel
date Tue, 13 Jan 2009 23:44:16 +0000
parents 6efb15a24e91
children e9d9d946f213
line wrap: on
line diff
--- a/sonic.c	Tue Jan 13 21:13:45 2009 +0000
+++ b/sonic.c	Tue Jan 13 23:44:16 2009 +0000
@@ -408,7 +408,7 @@
     return x;
 }
 
-#if defined(CONFIG_SONIC_ENCODER) || defined(CONFIG_SONIC_LS_ENCODER)
+#if CONFIG_SONIC_ENCODER || CONFIG_SONIC_LS_ENCODER
 // Heavily modified Levinson-Durbin algorithm which
 // copes better with quantization, and calculates the
 // actual whitened result as it goes.
@@ -479,12 +479,12 @@
 
     av_free(state);
 }
-#endif /* defined(CONFIG_SONIC_ENCODER) || defined(CONFIG_SONIC_LS_ENCODER) */
+#endif /* CONFIG_SONIC_ENCODER || CONFIG_SONIC_LS_ENCODER */
 
 static const int samplerate_table[] =
     { 44100, 22050, 11025, 96000, 48000, 32000, 24000, 16000, 8000 };
 
-#if defined(CONFIG_SONIC_ENCODER) || defined(CONFIG_SONIC_LS_ENCODER)
+#if CONFIG_SONIC_ENCODER || CONFIG_SONIC_LS_ENCODER
 static inline int code_samplerate(int samplerate)
 {
     switch (samplerate)
@@ -747,9 +747,9 @@
     flush_put_bits(&pb);
     return (put_bits_count(&pb)+7)/8;
 }
-#endif /* defined(CONFIG_SONIC_ENCODER) || defined(CONFIG_SONIC_LS_ENCODER) */
+#endif /* CONFIG_SONIC_ENCODER || CONFIG_SONIC_LS_ENCODER */
 
-#ifdef CONFIG_SONIC_DECODER
+#if CONFIG_SONIC_DECODER
 static av_cold int sonic_decode_init(AVCodecContext *avctx)
 {
     SonicContext *s = avctx->priv_data;
@@ -936,7 +936,7 @@
 }
 #endif /* CONFIG_SONIC_DECODER */
 
-#ifdef CONFIG_SONIC_ENCODER
+#if CONFIG_SONIC_ENCODER
 AVCodec sonic_encoder = {
     "sonic",
     CODEC_TYPE_AUDIO,
@@ -950,7 +950,7 @@
 };
 #endif
 
-#ifdef CONFIG_SONIC_LS_ENCODER
+#if CONFIG_SONIC_LS_ENCODER
 AVCodec sonic_ls_encoder = {
     "sonicls",
     CODEC_TYPE_AUDIO,
@@ -964,7 +964,7 @@
 };
 #endif
 
-#ifdef CONFIG_SONIC_DECODER
+#if CONFIG_SONIC_DECODER
 AVCodec sonic_decoder = {
     "sonic",
     CODEC_TYPE_AUDIO,