View | Details | Raw Unified | Return to bug 208817
Collapse All | Expand All

(-)multimedia/libxine/files/patch-ffmpeg3 (+57 lines)
Line 0 Link Here
1
Index: src/combined/ffmpeg/ff_audio_decoder.c
2
===================================================================
3
--- xine-lib-1.2.6.orig/src/combined/ffmpeg/ff_audio_decoder.c
4
+++ src/combined/ffmpeg/ff_audio_decoder.c
5
@@ -590,7 +590,7 @@ static int ff_audio_decode (ff_audio_dec
6
   int got_frame;
7
   float gain = this->class->gain;
8
   if (!this->av_frame)
9
-    this->av_frame = avcodec_alloc_frame ();
10
+    this->av_frame = av_frame_alloc ();
11
 
12
   consumed = avcodec_decode_audio4 (this->context, this->av_frame, &got_frame, &avpkt);
13
   if ((consumed >= 0) && got_frame) {
14
@@ -1071,7 +1071,7 @@ static void ff_audio_reset (audio_decode
15
   /* try to reset the wma decoder */
16
   if( this->decoder_ok ) {
17
 #if AVAUDIO > 3
18
-    avcodec_free_frame (&this->av_frame);
19
+    av_frame_free (&this->av_frame);
20
 #endif
21
     pthread_mutex_lock (&ffmpeg_lock);
22
     avcodec_close (this->context);
23
@@ -1105,7 +1105,7 @@ static void ff_audio_dispose (audio_deco
24
 
25
   if( this->context && this->decoder_ok ) {
26
 #if AVAUDIO > 3
27
-    avcodec_free_frame (&this->av_frame);
28
+    av_frame_free (&this->av_frame);
29
 #endif
30
     pthread_mutex_lock (&ffmpeg_lock);
31
     avcodec_close (this->context);
32
Index: src/combined/ffmpeg/ff_video_decoder.c
33
===================================================================
34
--- xine-lib-1.2.6.orig/src/combined/ffmpeg/ff_video_decoder.c
35
+++ src/combined/ffmpeg/ff_video_decoder.c
36
@@ -2523,7 +2523,7 @@ static video_decoder_t *ff_video_open_pl
37
   this->stream                            = stream;
38
   this->class                             = (ff_video_class_t *) class_gen;
39
 
40
-  this->av_frame          = avcodec_alloc_frame();
41
+  this->av_frame          = av_frame_alloc();
42
   this->context           = avcodec_alloc_context();
43
   this->context->opaque   = this;
44
 #if AVPALETTE == 1
45
Index: src/dxr3/ffmpeg_encoder.c
46
===================================================================
47
--- src/dxr3/ffmpeg_encoder.c.orig	2016-02-17 07:54:31.950881580 +0000
48
+++ src/dxr3/ffmpeg_encoder.c	2016-02-17 07:55:42.897237494 +0000
49
@@ -161,7 +161,7 @@
50
       "dxr3_mpeg_encoder: Couldn't start the ffmpeg library\n");
51
     return 0;
52
   }
53
-  this->picture = avcodec_alloc_frame();
54
+  this->picture = av_frame_alloc();
55
   if (!this->picture) {
56
     xprintf(drv->class->xine, XINE_VERBOSITY_LOG,
57
       "dxr3_mpeg_encoder: Couldn't allocate ffmpeg frame\n");

Return to bug 208817