From 639ccaab5e2f7e3abdc0ced04efdbce3abb3b450 Mon Sep 17 00:00:00 2001 From: Wim Taymans Date: Wed, 6 Oct 2010 16:57:05 +0200 Subject: ffmpeg: compile against HEAD Compile against HEAD Add G722 codec --- configure.ac | 1 + ext/ffmpeg/gstffmpegcodecmap.c | 11 +++++++++++ ext/ffmpeg/gstffmpegprotocol.c | 2 +- ffmpegrev | 5 +++-- 4 files changed, 16 insertions(+), 3 deletions(-) diff --git a/configure.ac b/configure.ac index 10d7b57..7253ad2 100644 --- a/configure.ac +++ b/configure.ac @@ -271,6 +271,7 @@ else dnl libgstffmpeg.la: libs to statically link to FFMPEG_LIBS="\$(top_builddir)/gst-libs/ext/ffmpeg/libavformat/libavformat.a \ \$(top_builddir)/gst-libs/ext/ffmpeg/libavcodec/libavcodec.a \ + \$(top_builddir)/gst-libs/ext/ffmpeg/libavcore/libavcore.a \ \$(top_builddir)/gst-libs/ext/ffmpeg/libavutil/libavutil.a" dnl POSTPROC_CFLAGS="-I \$(top_srcdir)/gst-libs/ext/ffmpeg/libpostproc \ diff --git a/ext/ffmpeg/gstffmpegcodecmap.c b/ext/ffmpeg/gstffmpegcodecmap.c index 45581a5..96ede9f 100644 --- a/ext/ffmpeg/gstffmpegcodecmap.c +++ b/ext/ffmpeg/gstffmpegcodecmap.c @@ -443,6 +443,9 @@ gst_ff_aud_caps_new (AVCodecContext * context, enum CodecID codec_id, case CODEC_ID_TRUEHD: maxchannels = 8; break; + case CODEC_ID_ADPCM_G722: + maxchannels = 1; + break; default: break; } @@ -1274,6 +1277,10 @@ gst_ffmpeg_codecid_to_caps (enum CodecID codec_id, caps = gst_ff_aud_caps_new (context, codec_id, "audio/x-alaw", NULL); break; + case CODEC_ID_ADPCM_G722: + caps = gst_ff_aud_caps_new (context, codec_id, "audio/G722", NULL); + break; + case CODEC_ID_ADPCM_G726: { /* the G726 decoder can also handle G721 */ @@ -3161,6 +3168,10 @@ gst_ffmpeg_caps_to_codecid (const GstCaps * caps, AVCodecContext * context) } if (id != CODEC_ID_NONE) audio = TRUE; + + } else if (!strcmp (mimetype, "audio/G722")) { + id = CODEC_ID_ADPCM_G722; + audio = TRUE; } else if (!strcmp (mimetype, "video/x-4xm")) { id = CODEC_ID_4XM; video = TRUE; diff --git a/ext/ffmpeg/gstffmpegprotocol.c b/ext/ffmpeg/gstffmpegprotocol.c index f46ac28..713a874 100644 --- a/ext/ffmpeg/gstffmpegprotocol.c +++ b/ext/ffmpeg/gstffmpegprotocol.c @@ -154,7 +154,7 @@ gst_ffmpegdata_read (URLContext * h, unsigned char *buf, int size) } static int -gst_ffmpegdata_write (URLContext * h, unsigned char *buf, int size) +gst_ffmpegdata_write (URLContext * h, const unsigned char *buf, int size) { GstProtocolInfo *info; GstBuffer *outbuf; diff --git a/ffmpegrev b/ffmpegrev index 773e5d5..f99b04b 100644 --- a/ffmpegrev +++ b/ffmpegrev @@ -1,6 +1,7 @@ -FFMPEG_REVISION=23623 +FFMPEG_REVISION=HEAD FFMPEG_CO_DIR=gst-libs/ext/ffmpeg -FFMPEG_SVN=svn://svn.ffmpeg.org/ffmpeg/branches/0.6 +#FFMPEG_SVN=svn://svn.ffmpeg.org/ffmpeg/branches/0.6 +FFMPEG_SVN=svn://svn.ffmpeg.org/ffmpeg/trunk # Because ffmpeg trunk checks out libswscale via an svn:externals, checking # out an old ffmpeg does not check out a corresponding libswscale. # Keep the swscale checkout manually synchronized, then. Update this -- cgit v1.2.3