]> git.sesse.net Git - ffmpeg/blobdiff - libavcodec/asv1.c
Set cur_channel in the AAC encoder context where needed.
[ffmpeg] / libavcodec / asv1.c
index 7a385e47a15acef8d1e7d499942412f2cb5951b1..211a13faf8e0ea2748d23da649cbd000d142dc80 100644 (file)
  */
 
 /**
- * @file libavcodec/asv1.c
+ * @file
  * ASUS V1/V2 codec.
  */
 
 #include "avcodec.h"
-#include "get_bits.h"
+#include "libavutil/common.h"
 #include "put_bits.h"
 #include "dsputil.h"
 #include "mpeg12data.h"
@@ -48,7 +48,7 @@ typedef struct ASV1Context{
     int mb_height;
     int mb_width2;
     int mb_height2;
-    DECLARE_ALIGNED_16(DCTELEM, block[6][64]);
+    DECLARE_ALIGNED(16, DCTELEM, block)[6][64];
     uint16_t intra_matrix[64];
     int q_intra_matrix[64];
     uint8_t *bitstream_buffer;
@@ -140,11 +140,11 @@ static av_cold void init_vlcs(ASV1Context *a){
 
 //FIXME write a reversed bitstream reader to avoid the double reverse
 static inline int asv2_get_bits(GetBitContext *gb, int n){
-    return ff_reverse[ get_bits(gb, n) << (8-n) ];
+    return av_reverse[ get_bits(gb, n) << (8-n) ];
 }
 
 static inline void asv2_put_bits(PutBitContext *pb, int n, int v){
-    put_bits(pb, n, ff_reverse[ v << (8-n) ]);
+    put_bits(pb, n, av_reverse[ v << (8-n) ]);
 }
 
 static inline int asv1_get_level(GetBitContext *gb){
@@ -417,7 +417,7 @@ static int decode_frame(AVCodecContext *avctx,
     else{
         int i;
         for(i=0; i<buf_size; i++)
-            a->bitstream_buffer[i]= ff_reverse[ buf[i] ];
+            a->bitstream_buffer[i]= av_reverse[ buf[i] ];
     }
 
     init_get_bits(&a->gb, a->bitstream_buffer, buf_size*8);
@@ -519,7 +519,7 @@ static int encode_frame(AVCodecContext *avctx, unsigned char *buf, int buf_size,
     else{
         int i;
         for(i=0; i<4*size; i++)
-            buf[i]= ff_reverse[ buf[i] ];
+            buf[i]= av_reverse[ buf[i] ];
     }
 
     return size*4;
@@ -615,7 +615,7 @@ static av_cold int decode_end(AVCodecContext *avctx){
 
 AVCodec asv1_decoder = {
     "asv1",
-    CODEC_TYPE_VIDEO,
+    AVMEDIA_TYPE_VIDEO,
     CODEC_ID_ASV1,
     sizeof(ASV1Context),
     decode_init,
@@ -628,7 +628,7 @@ AVCodec asv1_decoder = {
 
 AVCodec asv2_decoder = {
     "asv2",
-    CODEC_TYPE_VIDEO,
+    AVMEDIA_TYPE_VIDEO,
     CODEC_ID_ASV2,
     sizeof(ASV1Context),
     decode_init,
@@ -642,7 +642,7 @@ AVCodec asv2_decoder = {
 #if CONFIG_ASV1_ENCODER
 AVCodec asv1_encoder = {
     "asv1",
-    CODEC_TYPE_VIDEO,
+    AVMEDIA_TYPE_VIDEO,
     CODEC_ID_ASV1,
     sizeof(ASV1Context),
     encode_init,
@@ -656,7 +656,7 @@ AVCodec asv1_encoder = {
 #if CONFIG_ASV2_ENCODER
 AVCodec asv2_encoder = {
     "asv2",
-    CODEC_TYPE_VIDEO,
+    AVMEDIA_TYPE_VIDEO,
     CODEC_ID_ASV2,
     sizeof(ASV1Context),
     encode_init,