diff options
author | Mathieu Duponchelle <mathieu@centricular.com> | 2018-06-29 04:52:02 +0200 |
---|---|---|
committer | Mathieu Duponchelle <mathieu@centricular.com> | 2018-07-13 00:53:26 +0200 |
commit | 4f28ea23eb57e8df5cdf86055566602c75dc2bf2 (patch) | |
tree | 448cd4aa61fbe182a50525abd628b95cf7c827c8 /ext/libav/gstavdemux.c | |
parent | 9cc57a74d80d389530ef6373474957e9fa61c1fa (diff) | |
download | gst-libav-4f28ea23eb57e8df5cdf86055566602c75dc2bf2.tar.gz |
Remove all uses of AVPicture
https://bugzilla.gnome.org/show_bug.cgi?id=792900
Diffstat (limited to 'ext/libav/gstavdemux.c')
-rw-r--r-- | ext/libav/gstavdemux.c | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/ext/libav/gstavdemux.c b/ext/libav/gstavdemux.c index 7de25e4..c296238 100644 --- a/ext/libav/gstavdemux.c +++ b/ext/libav/gstavdemux.c @@ -26,6 +26,7 @@ #include <string.h> #include <libavformat/avformat.h> +#include <libavutil/imgutils.h> /* #include <ffmpeg/avi.h> */ #include <gst/gst.h> #include <gst/base/gstflowcombiner.h> @@ -1491,7 +1492,7 @@ gst_ffmpegdemux_loop (GstFFMpegDemux * demux) /* copy the data from packet into the target buffer * and do conversions for raw video packets */ if (rawvideo) { - AVPicture src, dst; + AVFrame src, dst; const gchar *plugin_name = ((GstFFMpegDemuxClass *) (G_OBJECT_GET_CLASS (demux)))->in_plugin->name; GstMapInfo map; @@ -1506,8 +1507,9 @@ gst_ffmpegdemux_loop (GstFFMpegDemux * demux) avstream->codec->pix_fmt, avstream->codec->width, avstream->codec->height); - av_picture_copy (&dst, &src, avstream->codec->pix_fmt, - avstream->codec->width, avstream->codec->height); + av_image_copy (dst.data, dst.linesize, (const uint8_t **) src.data, + src.linesize, avstream->codec->pix_fmt, avstream->codec->width, + avstream->codec->height); gst_buffer_unmap (outbuf, &map); } else { gst_buffer_fill (outbuf, 0, pkt.data, outsize); |