jvdec: don't use deprecated CODEC_TYPE_*/PKT_FLAG_KEY
authorAnton Khirnov <anton@khirnov.net>
Sat, 2 Apr 2011 09:35:14 +0000 (11:35 +0200)
committerAnton Khirnov <anton@khirnov.net>
Sat, 2 Apr 2011 14:16:44 +0000 (16:16 +0200)
libavcodec/jvdec.c
libavformat/jvdec.c

index 0da1142..8f19ba3 100644 (file)
@@ -205,7 +205,7 @@ static av_cold int decode_close(AVCodecContext *avctx)
 AVCodec ff_jv_decoder = {
     .name           = "jv",
     .long_name      = NULL_IF_CONFIG_SMALL("Bitmap Brothers JV video"),
 AVCodec ff_jv_decoder = {
     .name           = "jv",
     .long_name      = NULL_IF_CONFIG_SMALL("Bitmap Brothers JV video"),
-    .type           = CODEC_TYPE_VIDEO,
+    .type           = AVMEDIA_TYPE_VIDEO,
     .id             = CODEC_ID_JV,
     .priv_data_size = sizeof(JvContext),
     .init           = decode_init,
     .id             = CODEC_ID_JV,
     .priv_data_size = sizeof(JvContext),
     .init           = decode_init,
index 8a81b11..c180e5d 100644 (file)
@@ -74,7 +74,7 @@ static int read_header(AVFormatContext *s,
     if (!ast || !vst)
         return AVERROR(ENOMEM);
 
     if (!ast || !vst)
         return AVERROR(ENOMEM);
 
-    vst->codec->codec_type  = CODEC_TYPE_VIDEO;
+    vst->codec->codec_type  = AVMEDIA_TYPE_VIDEO;
     vst->codec->codec_id    = CODEC_ID_JV;
     vst->codec->codec_tag   = 0; /* no fourcc */
     vst->codec->width       = avio_rl16(pb);
     vst->codec->codec_id    = CODEC_ID_JV;
     vst->codec->codec_tag   = 0; /* no fourcc */
     vst->codec->width       = avio_rl16(pb);
@@ -85,7 +85,7 @@ static int read_header(AVFormatContext *s,
 
     avio_skip(pb, 4);
 
 
     avio_skip(pb, 4);
 
-    ast->codec->codec_type  = CODEC_TYPE_AUDIO;
+    ast->codec->codec_type  = AVMEDIA_TYPE_AUDIO;
     ast->codec->codec_id    = CODEC_ID_PCM_U8;
     ast->codec->codec_tag   = 0; /* no fourcc */
     ast->codec->sample_rate = avio_rl16(pb);
     ast->codec->codec_id    = CODEC_ID_PCM_U8;
     ast->codec->codec_tag   = 0; /* no fourcc */
     ast->codec->sample_rate = avio_rl16(pb);
@@ -151,7 +151,7 @@ static int read_packet(AVFormatContext *s, AVPacket *pkt)
                     return AVERROR(ENOMEM);
                 pkt->stream_index = 0;
                 pkt->pts          = e->timestamp;
                     return AVERROR(ENOMEM);
                 pkt->stream_index = 0;
                 pkt->pts          = e->timestamp;
-                pkt->flags       |= PKT_FLAG_KEY;
+                pkt->flags       |= AV_PKT_FLAG_KEY;
                 return 0;
             }
         case JV_VIDEO:
                 return 0;
             }
         case JV_VIDEO:
@@ -170,7 +170,7 @@ static int read_packet(AVFormatContext *s, AVPacket *pkt)
                 pkt->stream_index = 1;
                 pkt->pts          = jv->pts;
                 if (jvf->video_type != 1)
                 pkt->stream_index = 1;
                 pkt->pts          = jv->pts;
                 if (jvf->video_type != 1)
-                    pkt->flags |= PKT_FLAG_KEY;
+                    pkt->flags |= AV_PKT_FLAG_KEY;
                 return 0;
             }
         case JV_PADDING:
                 return 0;
             }
         case JV_PADDING: