comparison c93.c @ 5910:536e5527c1e0 libavformat

Define AVMediaType enum, and use it instead of enum CodecType, which is deprecated and will be dropped at the next major bump.
author stefano
date Tue, 30 Mar 2010 23:30:55 +0000
parents c900e8690782
children 11bb10c37225
comparison
equal deleted inserted replaced
5909:b8041f85c327 5910:536e5527c1e0
81 81
82 video = av_new_stream(s, 0); 82 video = av_new_stream(s, 0);
83 if (!video) 83 if (!video)
84 return AVERROR(ENOMEM); 84 return AVERROR(ENOMEM);
85 85
86 video->codec->codec_type = CODEC_TYPE_VIDEO; 86 video->codec->codec_type = AVMEDIA_TYPE_VIDEO;
87 video->codec->codec_id = CODEC_ID_C93; 87 video->codec->codec_id = CODEC_ID_C93;
88 video->codec->width = 320; 88 video->codec->width = 320;
89 video->codec->height = 192; 89 video->codec->height = 192;
90 /* 4:3 320x200 with 8 empty lines */ 90 /* 4:3 320x200 with 8 empty lines */
91 video->sample_aspect_ratio = (AVRational) { 5, 6 }; 91 video->sample_aspect_ratio = (AVRational) { 5, 6 };
118 if (datasize > 42) { 118 if (datasize > 42) {
119 if (!c93->audio) { 119 if (!c93->audio) {
120 c93->audio = av_new_stream(s, 1); 120 c93->audio = av_new_stream(s, 1);
121 if (!c93->audio) 121 if (!c93->audio)
122 return AVERROR(ENOMEM); 122 return AVERROR(ENOMEM);
123 c93->audio->codec->codec_type = CODEC_TYPE_AUDIO; 123 c93->audio->codec->codec_type = AVMEDIA_TYPE_AUDIO;
124 } 124 }
125 url_fskip(pb, 26); /* VOC header */ 125 url_fskip(pb, 26); /* VOC header */
126 ret = voc_get_packet(s, pkt, c93->audio, datasize - 26); 126 ret = voc_get_packet(s, pkt, c93->audio, datasize - 26);
127 if (ret > 0) { 127 if (ret > 0) {
128 pkt->stream_index = 1; 128 pkt->stream_index = 1;