]> git.sesse.net Git - ffmpeg/blobdiff - libavformat/libmodplug.c
avformat/framehash: enable new output
[ffmpeg] / libavformat / libmodplug.c
index 75699e89b473e551d59f91c1080e4934db007c94..f18c610c4624dc607013d3356bdc5892f9cdb8a2 100644 (file)
@@ -224,10 +224,10 @@ static int modplug_read_header(AVFormatContext *s)
         return AVERROR(ENOMEM);
     avpriv_set_pts_info(st, 64, 1, 1000);
     st->duration = ModPlug_GetLength(modplug->f);
-    st->codec->codec_type  = AVMEDIA_TYPE_AUDIO;
-    st->codec->codec_id    = AV_CODEC_ID_PCM_S16LE;
-    st->codec->channels    = settings.mChannels;
-    st->codec->sample_rate = settings.mFrequency;
+    st->codecpar->codec_type  = AVMEDIA_TYPE_AUDIO;
+    st->codecpar->codec_id    = AV_CODEC_ID_PCM_S16LE;
+    st->codecpar->channels    = settings.mChannels;
+    st->codecpar->sample_rate = settings.mFrequency;
 
     // timebase = 1/1000, 2ch 16bits 44.1kHz-> 2*2*44100
     modplug->ts_per_packet = 1000*AUDIO_PKT_SIZE / (4*44100.);
@@ -238,10 +238,10 @@ static int modplug_read_header(AVFormatContext *s)
             return AVERROR(ENOMEM);
         avpriv_set_pts_info(vst, 64, 1, 1000);
         vst->duration = st->duration;
-        vst->codec->codec_type = AVMEDIA_TYPE_VIDEO;
-        vst->codec->codec_id   = AV_CODEC_ID_XBIN;
-        vst->codec->width      = modplug->w << 3;
-        vst->codec->height     = modplug->h << 3;
+        vst->codecpar->codec_type = AVMEDIA_TYPE_VIDEO;
+        vst->codecpar->codec_id   = AV_CODEC_ID_XBIN;
+        vst->codecpar->width      = modplug->w << 3;
+        vst->codecpar->height     = modplug->h << 3;
         modplug->linesize = modplug->w * 3;
         modplug->fsize    = modplug->linesize * modplug->h;
     }