Files
for-gentoo/media-plugins/alsa-plugins/files/alsa-plugins-1.0.26-libav9.patch
T

35 lines
1003 B
Diff

Author: Reinhard Tartler <siretart@ubuntu.com>
Description: Update to newer libav API - compatible to libav 0.8 and libav 9
Index: alsa-plugins-1.0.26/a52/pcm_a52.c
===================================================================
--- alsa-plugins-1.0.26.orig/a52/pcm_a52.c 2013-04-22 20:29:05.107102697 +0200
+++ alsa-plugins-1.0.26/a52/pcm_a52.c 2013-04-22 20:34:12.985107208 +0200
@@ -25,6 +25,8 @@
#include <alsa/asoundlib.h>
#include <alsa/pcm_external.h>
#include <alsa/pcm_plugin.h>
+#include <libavutil/audioconvert.h>
+#include <libavutil/mem.h>
#include AVCODEC_HEADER
struct a52_ctx {
@@ -429,7 +431,7 @@
a52_free(rec);
- rec->avctx = avcodec_alloc_context();
+ rec->avctx = avcodec_alloc_context3(rec->codec);
if (! rec->avctx)
return -ENOMEM;
@@ -457,7 +459,7 @@
}
#endif
- if (avcodec_open(rec->avctx, rec->codec) < 0)
+ if (avcodec_open2(rec->avctx, rec->codec, NULL) < 0)
return -EINVAL;
rec->inbuf = malloc(rec->avctx->frame_size * 2 * io->channels);