]> git.sesse.net Git - ffmpeg/blobdiff - libavcodec/eacmv.c
Merge remote-tracking branch 'qatar/master'
[ffmpeg] / libavcodec / eacmv.c
index 7f6c2a4577467b58903b9e3a0dd21f5ee72e86b0..408d94881288e566cede837e480b2e88fb2a0e06 100644 (file)
@@ -43,6 +43,10 @@ typedef struct CmvContext {
 
 static av_cold int cmv_decode_init(AVCodecContext *avctx){
     CmvContext *s = avctx->priv_data;
+    avcodec_get_frame_defaults(&s->frame);
+    avcodec_get_frame_defaults(&s->last_frame);
+    avcodec_get_frame_defaults(&s->last2_frame);
+
     s->avctx = avctx;
     avctx->pix_fmt = PIX_FMT_PAL8;
     return 0;
@@ -180,10 +184,10 @@ static int cmv_decode_frame(AVCodecContext *avctx,
     if ((buf[0]&1)) {  // subtype
         cmv_decode_inter(s, buf+2, buf_end);
         s->frame.key_frame = 0;
-        s->frame.pict_type = FF_P_TYPE;
+        s->frame.pict_type = AV_PICTURE_TYPE_P;
     }else{
         s->frame.key_frame = 1;
-        s->frame.pict_type = FF_I_TYPE;
+        s->frame.pict_type = AV_PICTURE_TYPE_I;
         cmv_decode_intra(s, buf+2, buf_end);
     }