mirror of
https://github.com/webmproject/libwebp.git
synced 2025-07-13 14:34:33 +02:00
vwebp_sdl: simple viewer based on SDL
Uses WebPToSDL() generic function defined in vwebp_sdl.[ch]. This function is not included in the libextras library, because it would bring in an SDL dependency. Probably too heavy for now. WebPToSDL() is separate, because it will be called used by the javascript version of libwebp (through emscripten build rules) Change-Id: Ic85b36f8ce4784f46023656278f6480be6802834
This commit is contained in:
40
configure.ac
40
configure.ac
@ -428,6 +428,44 @@ AS_IF([test "x$enable_gl" != "xno"], [
|
||||
])
|
||||
AM_CONDITIONAL([BUILD_VWEBP], [test "$build_vwebp" = "yes"])
|
||||
|
||||
dnl === check for SDL support ===
|
||||
|
||||
AC_ARG_ENABLE([sdl],
|
||||
AS_HELP_STRING([--disable-sdl],
|
||||
[Disable detection of SDL support
|
||||
@<:@default=auto@:>@]))
|
||||
AS_IF([test "x$enable_sdl" != "xno"], [
|
||||
CLEAR_LIBVARS([SDL])
|
||||
WITHLIB_OPTION([sdl], [SDL])
|
||||
|
||||
$sdl_header = "no";
|
||||
LIBCHECK_PROLOGUE([SDL])
|
||||
AC_CHECK_HEADER([SDL/SDL.h], [sdl_header="SDL_SDL.h"],
|
||||
[AC_CHECK_HEADER([SDL.h], [sdl_header="SDL.h"],
|
||||
[AC_MSG_WARN(SDL library not available - no sdl.h)])])
|
||||
if test x"$sdl_header" != "xno" ; then
|
||||
AC_CHECK_LIB(SDL, SDL_Init,
|
||||
[SDL_LIBS="-lSDL"
|
||||
SDL_INCLUDES="-DWEBP_HAVE_SDL"
|
||||
AC_DEFINE(WEBP_HAVE_SDL, [1],
|
||||
[Set to 1 if SDL library is installed])
|
||||
sdl_support=yes
|
||||
],
|
||||
AC_MSG_WARN(Optional SDL library not found),
|
||||
[$MATH_LIBS]),
|
||||
if test x"$sdl_header" == "xSDL.h" ; then
|
||||
SDL_INCLUDES="$SDL_INCLUDES -DWEBP_HAVE_JUST_SDL_H"
|
||||
fi
|
||||
fi
|
||||
LIBCHECK_EPILOGUE([SDL])
|
||||
|
||||
if test "$sdl_support" = "yes" ; then
|
||||
build_vwebp_sdl=yes
|
||||
fi
|
||||
])
|
||||
|
||||
AM_CONDITIONAL([BUILD_VWEBP_SDL], [test "$build_vwebp_sdl" = "yes"])
|
||||
|
||||
dnl === check for PNG support ===
|
||||
|
||||
AC_ARG_ENABLE([png], AS_HELP_STRING([--disable-png],
|
||||
@ -718,4 +756,6 @@ gif2webp : ${build_gif2webp-no}
|
||||
img2webp : ${build_img2webp-no}
|
||||
webpmux : ${enable_libwebpmux-no}
|
||||
vwebp : ${build_vwebp-no}
|
||||
SDL support : ${sdl_support-no}
|
||||
vwebp_sdl : ${build_vwebp_sdl-no}
|
||||
])
|
||||
|
Reference in New Issue
Block a user