xine-lib-ffmpeg3.patch 2.3 KB

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