updated on Thu Jan 26 16:09:46 UTC 2012
[aur-mirror.git] / gstreamer-vaapi / ffmpeg_deprecated.patch
blob702c0f5fc40ca18b2d98c6a6cd0bea10cbbeb365
1 --- gst-libs/gst/vaapi/gstvaapidecoder_ffmpeg.c 2011-07-08 01:18:06.000000000 +0300
2 +++ gst-libs/gst/vaapi/gstvaapidecoder_ffmpeg.c.new 2011-07-08 01:53:13.170179549 +0300
3 @@ -1,4 +1,4 @@
4 -/*
5 +/**
6 * gstvaapidecoder_ffmpeg.c - FFmpeg-based decoder
8 * gstreamer-vaapi (C) 2010-2011 Splitted-Desktop Systems
9 @@ -480,11 +480,18 @@
10 int bytes_read, got_picture = 0;
12 GST_VAAPI_DISPLAY_LOCK(display);
13 - bytes_read = avcodec_decode_video(
15 + AVPacket packet;
16 + av_init_packet(&packet);
17 + packet.data = buf;
18 + packet.size = buf_size;
21 + bytes_read = avcodec_decode_video2(
22 priv->avctx,
23 priv->frame,
24 &got_picture,
25 - buf, buf_size
26 + &packet
28 GST_VAAPI_DISPLAY_UNLOCK(display);
29 if (!got_picture)
30 @@ -530,12 +537,12 @@
32 if (priv->pctx) {
33 do {
34 - int parsed_size = av_parser_parse(
35 + int parsed_size = av_parser_parse2(
36 priv->pctx,
37 priv->avctx,
38 &outbuf, &outbuf_size,
39 GST_BUFFER_DATA(buffer) + inbuf_ofs, inbuf_size,
40 - inbuf_ts, inbuf_ts
41 + inbuf_ts, inbuf_ts, AV_NOPTS_VALUE
43 got_frame = outbuf && outbuf_size > 0;