---
libavformat/filmstripenc.c | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/libavformat/filmstripenc.c b/libavformat/filmstripenc.c
index 0794b18..5a09691 100644
--- a/libavformat/filmstripenc.c
+++ b/libavformat/filmstripenc.c
@@ -35,7 +35,7 @@ typedef struct FilmstripMuxContext {
static int write_header(AVFormatContext *s)
{
- if (s->streams[0]->codec->pix_fmt != AV_PIX_FMT_RGBA) {
+ if (s->streams[0]->codecpar->format != AV_PIX_FMT_RGBA) {
av_log(s, AV_LOG_ERROR, "only AV_PIX_FMT_RGBA is supported\n");
return AVERROR_INVALIDDATA;
}
@@ -61,8 +61,8 @@ static int write_trailer(AVFormatContext *s)
avio_wb32(pb, film->nb_frames);
avio_wb16(pb, 0); // packing method
avio_wb16(pb, 0); // reserved
- avio_wb16(pb, st->codec->width);
- avio_wb16(pb, st->codec->height);
+ avio_wb16(pb, st->codecpar->width);
+ avio_wb16(pb, st->codecpar->height);
avio_wb16(pb, 0); // leading
// TODO: should be avg_frame_rate
avio_wb16(pb, 1/av_q2d(st->time_base));
--
2.0.0
_______________________________________________
libav-devel mailing list
[email protected]
https://lists.libav.org/mailman/listinfo/libav-devel