diff ffv1.c @ 3777:20545fbb6f7c libavcodec

add some #ifdef CONFIG_ENCODERS/DECODERS
author mru
date Wed, 27 Sep 2006 19:54:07 +0000
parents 0082fb8c77b6
children c8c591fe26f8
line wrap: on
line diff
--- a/ffv1.c	Wed Sep 27 19:47:39 2006 +0000
+++ b/ffv1.c	Wed Sep 27 19:54:07 2006 +0000
@@ -354,6 +354,7 @@
     return ret;
 }
 
+#ifdef CONFIG_ENCODERS
 static inline int encode_line(FFV1Context *s, int w, int_fast16_t *sample[2], int plane_index, int bits){
     PlaneContext * const p= &s->plane[plane_index];
     RangeCoder * const c= &s->c;
@@ -527,6 +528,7 @@
     for(i=0; i<5; i++)
         write_quant_table(c, f->quant_table[i]);
 }
+#endif /* CONFIG_ENCODERS */
 
 static int common_init(AVCodecContext *avctx){
     FFV1Context *s = avctx->priv_data;
@@ -545,6 +547,7 @@
     return 0;
 }
 
+#ifdef CONFIG_ENCODERS
 static int encode_init(AVCodecContext *avctx)
 {
     FFV1Context *s = avctx->priv_data;
@@ -608,6 +611,7 @@
 
     return 0;
 }
+#endif /* CONFIG_ENCODERS */
 
 
 static void clear_state(FFV1Context *f){
@@ -632,6 +636,7 @@
     }
 }
 
+#ifdef CONFIG_ENCODERS
 static int encode_frame(AVCodecContext *avctx, unsigned char *buf, int buf_size, void *data){
     FFV1Context *f = avctx->priv_data;
     RangeCoder * const c= &f->c;
@@ -687,6 +692,7 @@
         return used_count + (put_bits_count(&f->pb)+7)/8;
     }
 }
+#endif /* CONFIG_ENCODERS */
 
 static int common_end(AVCodecContext *avctx){
     FFV1Context *s = avctx->priv_data;