From 0aa83d8efcf477675669569b037f291464c4f146 Mon Sep 17 00:00:00 2001 From: Benny Prijono Date: Thu, 10 Apr 2014 10:01:07 +0000 Subject: Re #1758: Initial implementation of OpenH264 wrapper. Supports: - library detection via autoconf - CBP - packetization modes: 0, 1 - key frame request and indication - obey remote's fmtp Also added video codec test in samples (similar to the one in pjmedia test though). And there are some fixes here and there too (e.g. in vid_codec_util.c). git-svn-id: http://svn.pjsip.org/repos/pjproject/trunk@4815 74dad513-b988-da41-8d7b-12977e46ad98 --- aconfigure.ac | 67 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 67 insertions(+) (limited to 'aconfigure.ac') diff --git a/aconfigure.ac b/aconfigure.ac index e0da29ab..3af48d72 100644 --- a/aconfigure.ac +++ b/aconfigure.ac @@ -1095,6 +1095,73 @@ AC_ARG_ENABLE(v4l2, ) ]) +dnl # OpenH264 alt prefix +AC_ARG_WITH(openh264, + AC_HELP_STRING([--with-openh264=DIR], + [Specify alternate OpenH264 prefix]), + [], + [with_openh264=no] + ) + +dnl # Do not use default OpenH264 installation if we are cross-compiling +if test "x$ac_cross_compile" != "x" -a "x$with_openh264" = "xno"; then + enable_openh264=no +fi + +dnl # OpenH264 +AC_SUBST(ac_openh264_cflags) +AC_SUBST(ac_openh264_ldflags) +AC_ARG_ENABLE(openh264, + AC_HELP_STRING([--disable-openh264], + [Disable OpenH264 (default: not disabled)]), + [ + if test "$enable_openh264" = "no"; then + AC_MSG_RESULT([Checking if OpenH264 is disabled... yes]) + fi + ], + [ + if test "x$with_openh264" != "xno" -a "x$with_openh264" != "x"; then + OPENH264_PREFIX=$with_openh264 + OPENH264_CFLAGS="-I$OPENH264_PREFIX/include" + OPENH264_LDFLAGS="-L$OPENH264_PREFIX/lib" + AC_MSG_RESULT([Using OpenH264 prefix... $with_openh264]) + else + OPENH264_CFLAGS="" + OPENH264_LDFLAGS="" + fi + + AC_MSG_CHECKING([OpenH264 availability]) + + OPENH264_LIBS="-lwels" + + SAVED_LIBS="$LIBS" + SAVED_LDFLAGS="$LDFLAGS" + SAVED_CFLAGS="$CFLAGS" + + LIBS="$OPENH264_LIBS $LIBS" + LDFLAGS="$OPENH264_LDFLAGS $LDFLAGS" + CFLAGS="$OPENH264_CFLAGS $CFLAGS" + + AC_LINK_IFELSE([AC_LANG_PROGRAM([[#include + #include + ]], + [int main() { CreateSVCEncoder(0); return 0; }] + )], + [ ac_openh264_cflags="-DPJMEDIA_HAS_OPENH264_CODEC=1 $OPENH264_CFLAGS" + ac_openh264_ldflags="$OPENH264_LDFLAGS $OPENH264_LIBS" + AC_MSG_RESULT(ok) + ], + [ + LIBS="$SAVED_LIBS" + LDFLAGS="$SAVED_LDFLAGS" + CFLAGS="$SAVED_CFLAGS" + AC_MSG_RESULT(failed) + ]) + + ]) + + + dnl ######################################################## dnl # Intel IPP support dnl # -- cgit v1.2.3