From 81d1514a1daf379d58c61080244bb01c7ee7e662 Mon Sep 17 00:00:00 2001
From: fritsch <peter.fruehberger@gmail.com>
Date: Mon, 30 Apr 2012 21:33:18 +0200
Subject: [PATCH] xvba: (VC-1) rename FF_P_TYPE, FF_B_TYPE and FF_I_TYPE to
 new ffmpeg conventions

---
 libavcodec/xvba_vc1.c |   10 +++-------
 1 file changed, 3 insertions(+), 7 deletions(-)

diff --git a/libavcodec/xvba_vc1.c b/libavcodec/xvba_vc1.c
index c202b9c..7315b62 100644
--- a/libavcodec/xvba_vc1.c
+++ b/libavcodec/xvba_vc1.c
@@ -82,7 +82,7 @@ static int end_frame(AVCodecContext *avctx)
     // xvba-video set this to 1 only 4:2:0 supported
     // doc says: if not set, choose 1 - we try this
     pic_descriptor->chroma_format                           = 1;
-    pic_descriptor->avc_intra_flag                          = s->pict_type == FF_I_TYPE || v->bi_type == 1;
+    pic_descriptor->avc_intra_flag                          = s->pict_type == AV_PICTURE_TYPE_I || v->bi_type == 1;
     pic_descriptor->avc_reference                           = (s->current_picture_ptr->f.reference & 3) ? 1 : 0;
     
     // VC-1 explicit parameters see page 30 of sdk
@@ -128,13 +128,13 @@ static int end_frame(AVCodecContext *avctx)
     pic_descriptor->past_surface                            = 0;
     pic_descriptor->future_surface                          = 0;
     switch (s->pict_type) {
-    case FF_B_TYPE:
+    case AV_PICTURE_TYPE_B:
         next = (struct xvba_render_state *)s->next_picture.f.data[0];
         assert(next);
         if (next)
           pic_descriptor->past_surface = next->surface;
         // fall-through
-    case FF_P_TYPE:
+    case AV_PICTURE_TYPE_P:
         last = (struct xvba_render_state *)s->last_picture.f.data[0];
         assert(last);
         if (last)
@@ -173,11 +173,9 @@ static int decode_slice(AVCodecContext *avctx, const uint8_t *buffer, uint32_t s
     .type           = AVMEDIA_TYPE_VIDEO,
     .id             = CODEC_ID_WMV3,
     .pix_fmt        = PIX_FMT_XVBA_VLD,
-    .capabilities   = 0,
     .start_frame    = start_frame,
     .end_frame      = end_frame,
     .decode_slice   = decode_slice,
-    .priv_data_size = 0,
 };
 #endif
 
@@ -186,9 +184,7 @@ static int decode_slice(AVCodecContext *avctx, const uint8_t *buffer, uint32_t s
     .type           = AVMEDIA_TYPE_VIDEO,
     .id             = CODEC_ID_VC1,
     .pix_fmt        = PIX_FMT_XVBA_VLD,
-    .capabilities   = 0,
     .start_frame    = start_frame,
     .end_frame      = end_frame,
     .decode_slice   = decode_slice,
-    .priv_data_size = 0,
 };
-- 
1.7.10

