]> git.sesse.net Git - ffmpeg/commitdiff
Replace deprecated CODEC_TYPE_AUDIO and CODEC_TYPE_VIDEO with the
authorStefano Sabatini <stefano.sabatini-lala@poste.it>
Sat, 25 Sep 2010 23:27:16 +0000 (23:27 +0000)
committerStefano Sabatini <stefano.sabatini-lala@poste.it>
Sat, 25 Sep 2010 23:27:16 +0000 (23:27 +0000)
corresponding AVMEDIA_TYPE_* symbols.

Originally committed as revision 25201 to svn://svn.ffmpeg.org/ffmpeg/trunk

libavcodec/ansi.c
libavcodec/libxavs.c
libavcodec/pictordec.c
libavcodec/ra144enc.c
libavfilter/vf_pad.c
libavformat/asfdec.c
libavformat/flic.c
libavformat/flvenc.c
libavformat/rtpdec_qdm2.c
libavformat/rtpdec_svq3.c
libavformat/tty.c

index ad85906095ce23024aeb78e96eedd88e068ae2ce..8e7171c6c1e96c5d3cd1845963171e1e36576423 100644 (file)
@@ -424,7 +424,7 @@ static av_cold int decode_close(AVCodecContext *avctx)
 
 AVCodec ansi_decoder = {
     .name           = "ansi",
-    .type           = CODEC_TYPE_VIDEO,
+    .type           = AVMEDIA_TYPE_VIDEO,
     .id             = CODEC_ID_ANSI,
     .priv_data_size = sizeof(AnsiContext),
     .init           = decode_init,
index c4ac73333bc5ca7ab4697303f9e38ef8b3e8b877..aa5dc23bc24000e201fc91e1fb11c0c42d3e21ea 100644 (file)
@@ -338,7 +338,7 @@ static av_cold int XAVS_init(AVCodecContext *avctx)
 
 AVCodec libxavs_encoder = {
     .name           = "libxavs",
-    .type           = CODEC_TYPE_VIDEO,
+    .type           = AVMEDIA_TYPE_VIDEO,
     .id             = CODEC_ID_CAVS,
     .priv_data_size = sizeof(XavsContext),
     .init           = XAVS_init,
index 8f46fc06e8b47952ede08ccdf3b79e3509196b08..04667f61f259495a8b599bd6dda9eea2ff24c84c 100644 (file)
@@ -239,7 +239,7 @@ static av_cold int decode_end(AVCodecContext *avctx)
 
 AVCodec pictor_decoder = {
     "pictor",
-    CODEC_TYPE_VIDEO,
+    AVMEDIA_TYPE_VIDEO,
     CODEC_ID_PICTOR,
     sizeof(PicContext),
     NULL,
index 9e2cf36c2df539cb8522b6b028383fe188a85ea4..195821cddbd86d328789ec1b988e311453c698f1 100644 (file)
@@ -502,7 +502,7 @@ static int ra144_encode_frame(AVCodecContext *avctx, uint8_t *frame,
 AVCodec ra_144_encoder =
 {
     "real_144",
-    CODEC_TYPE_AUDIO,
+    AVMEDIA_TYPE_AUDIO,
     CODEC_ID_RA_144,
     sizeof(RA144Context),
     ra144_encode_init,
index d79baeab22fb0e1e9978c3d7276bdd46b7585419..2b798cc5b43576361b8d229f3550dad85cb54df1 100644 (file)
@@ -456,7 +456,7 @@ AVFilter avfilter_vsrc_color = {
     .inputs    = (AVFilterPad[]) {{ .name = NULL}},
 
     .outputs   = (AVFilterPad[]) {{ .name            = "default",
-                                    .type            = CODEC_TYPE_VIDEO,
+                                    .type            = AVMEDIA_TYPE_VIDEO,
                                     .request_frame   = color_request_frame,
                                     .config_props    = color_config_props },
                                   { .name = NULL}},
index 6caffce7433ff1fa6777c79236835a244c58e08a..6741f8ce17b987e4a45e583b2aae5ac442dc64a6 100644 (file)
@@ -639,7 +639,7 @@ static int asf_read_header(AVFormatContext *s, AVFormatParameters *ap)
                 av_reduce(&st->sample_aspect_ratio.num,
                           &st->sample_aspect_ratio.den,
                           dar[i].num, dar[i].den, INT_MAX);
-            } else if ((dar[0].num > 0) && (dar[0].den > 0) && (st->codec->codec_type==CODEC_TYPE_VIDEO)) // Use ASF container value if the stream doesn't AR set.
+            } else if ((dar[0].num > 0) && (dar[0].den > 0) && (st->codec->codec_type==AVMEDIA_TYPE_VIDEO)) // Use ASF container value if the stream doesn't AR set.
                 av_reduce(&st->sample_aspect_ratio.num,
                           &st->sample_aspect_ratio.den,
                           dar[0].num, dar[0].den, INT_MAX);
index 27145db086a846d1aac6cf867954acfa026e726e..fbdf931517f872360f1893baec30fb9998c4b5c0 100644 (file)
@@ -152,7 +152,7 @@ static int flic_read_header(AVFormatContext *s,
 
         /* all audio frames are the same size, so use the size of the first chunk for block_align */
         ast->codec->block_align = AV_RL32(&preamble[0]);
-        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;
         ast->codec->sample_rate = FLIC_TFTD_SAMPLE_RATE;
index 29b7b1d1ef8f7c52fd9c034df3b082410bc162f0..e1382921090457400ddfd419745fbb15c8448fe0 100644 (file)
@@ -337,7 +337,7 @@ static int flv_write_trailer(AVFormatContext *s)
     /* Add EOS tag */
     for (i = 0; i < s->nb_streams; i++) {
         AVCodecContext *enc = s->streams[i]->codec;
-        if (enc->codec_type == CODEC_TYPE_VIDEO &&
+        if (enc->codec_type == AVMEDIA_TYPE_VIDEO &&
                 enc->codec_id == CODEC_ID_H264) {
             put_avc_eos_tag(pb, flv->last_video_ts);
         }
@@ -405,7 +405,7 @@ static int flv_write_packet(AVFormatContext *s, AVPacket *pkt)
     }
 
     ts = pkt->dts + flv->delay; // add delay to force positive dts
-    if (enc->codec_type == CODEC_TYPE_VIDEO) {
+    if (enc->codec_type == AVMEDIA_TYPE_VIDEO) {
         if (flv->last_video_ts < ts)
             flv->last_video_ts = ts;
     }
index e9e221a7a51061be82d81f5448cd7d5437f85795..bd56942c303673b38016d54531ca6a67785d90eb 100644 (file)
@@ -307,7 +307,7 @@ static void qdm2_extradata_free(PayloadContext *qdm)
 
 RTPDynamicProtocolHandler ff_qdm2_dynamic_handler = {
     "X-QDM",
-    CODEC_TYPE_AUDIO,
+    AVMEDIA_TYPE_AUDIO,
     CODEC_ID_NONE,
     NULL,
     qdm2_extradata_new,
index 3c4d75f085066507e1295b6db5be731aae3574f8..d0c298fb591043e31e83693b4b8af493ab49e840 100644 (file)
@@ -129,7 +129,7 @@ static void svq3_extradata_free(PayloadContext *sv)
 
 RTPDynamicProtocolHandler ff_svq3_dynamic_handler = {
     "X-SV3V-ES",
-    CODEC_TYPE_VIDEO,
+    AVMEDIA_TYPE_VIDEO,
     CODEC_ID_NONE,          // see if (config_packet) above
     NULL,                   // parse sdp line
     svq3_extradata_new,
index e4ed22d4c11b5e23dab17b713a644f2262ab05f7..6aa6fa2c277c84a1ea10a4ad864814dac3dceada 100644 (file)
@@ -75,7 +75,7 @@ static int read_header(AVFormatContext *avctx,
     if (!st)
         return AVERROR(ENOMEM);
     st->codec->codec_tag   = 0;
-    st->codec->codec_type  = CODEC_TYPE_VIDEO;
+    st->codec->codec_type  = AVMEDIA_TYPE_VIDEO;
     st->codec->codec_id    = CODEC_ID_ANSI;
     if (ap->width)  st->codec->width  = ap->width;
     if (ap->height) st->codec->height = ap->height;