diff options
author | Alessandro Decina <alessandro.decina@collabora.co.uk> | 2009-03-13 19:42:18 +0100 |
---|---|---|
committer | Alessandro Decina <alessandro.decina@collabora.co.uk> | 2009-03-23 12:16:52 +0100 |
commit | 276228da806728723fecde73b539c0c33863d761 (patch) | |
tree | 378bb68cf99aeca6f7f918ed4b7df69ab2c96021 | |
parent | 2f6d3fdd0ab2f83ac564fccf8882f24f1fedf316 (diff) | |
download | gst-plugins-bad-276228da806728723fecde73b539c0c33863d761.tar.gz gst-plugins-bad-276228da806728723fecde73b539c0c33863d761.tar.bz2 gst-plugins-bad-276228da806728723fecde73b539c0c33863d761.zip |
celtenc: build with celt 0.5.
-rw-r--r-- | configure.ac | 11 | ||||
-rw-r--r-- | ext/celt/gstceltenc.c | 10 |
2 files changed, 16 insertions, 5 deletions
diff --git a/configure.ac b/configure.ac index 9cc6fdf4..0df70751 100644 --- a/configure.ac +++ b/configure.ac @@ -527,10 +527,15 @@ AG_GST_CHECK_FEATURE(CDAUDIO, [cdaudio], cdaudio, [ dnl *** celt *** translit(dnm, m, l) AM_CONDITIONAL(USE_CELT, true) AG_GST_CHECK_FEATURE(CELT, [celt], celt, [ - PKG_CHECK_MODULES(CELT, celt >= 0.4.0, [ + PKG_CHECK_MODULES(CELT, celt >= 0.5.0, [ HAVE_CELT="yes"], [ - HAVE_CELT="no" - AC_MSG_RESULT(no) + PKG_CHECK_MODULES(CELT, celt >= 0.4.0, [ + HAVE_CELT="yes" + AC_DEFINE([HAVE_CELT_0_4], 1, [Define if libcelt 0.4 is installed]) + ],[ + HAVE_CELT="no" + AC_MSG_RESULT(no) + ]) ]) AC_SUBST(CELT_CFLAGS) AC_SUBST(CELT_LIBS) diff --git a/ext/celt/gstceltenc.c b/ext/celt/gstceltenc.c index d76fd886..11b57e55 100644 --- a/ext/celt/gstceltenc.c +++ b/ext/celt/gstceltenc.c @@ -738,9 +738,15 @@ gst_celt_enc_encode (GstCeltEnc * enc, gboolean flush) GST_DEBUG_OBJECT (enc, "encoding %d samples (%d bytes)", frame_size, bytes); +#ifdef HAVE_CELT_0_4 outsize = - celt_encode (enc->state, data, GST_BUFFER_DATA (outbuf), - bytes_per_packet); + celt_encode (enc->state, data, + GST_BUFFER_DATA (outbuf), bytes_per_packet); +#else + outsize = + celt_encode (enc->state, data, NULL, + GST_BUFFER_DATA (outbuf), bytes_per_packet); +#endif g_free (data); |