configure.ac, modules/visualization/goom.c: updated for libgoom2 (goom 2k4). You can find it here: http://www.ios-software.com/index.php3?page=projet&quoi=1

This commit is contained in:
Gildas Bazin 2004-05-09 09:35:12 +00:00
parent 44b413e922
commit f5ed9a6957
2 changed files with 23 additions and 15 deletions

View File

@ -3408,27 +3408,32 @@ then
dnl test for --with-goom-tree
dnl
if test "${with_goom_tree}" != "no" -a -n "${with_goom_tree}"; then
AC_MSG_CHECKING(for libgoom.a in ${with_goom_tree})
AC_MSG_CHECKING(for libgoom2.a in ${with_goom_tree})
real_goom_tree="`cd ${with_goom_tree} 2>/dev/null && pwd`"
if test -z "${real_goom_tree}"; then
dnl The given directory can't be found
AC_MSG_RESULT(no)
AC_MSG_ERROR([cannot cd to ${with_goom_tree}])
fi
if test -f "${real_goom_tree}/libgoom.a"; then
AC_MSG_RESULT(${real_goom_tree}/libgoom.a)
if test -f "${real_goom_tree}/src/.libs/libgoom2.a"; then
AC_MSG_RESULT(${real_goom_tree}/src/.libs/libgoom2.a)
AX_ADD_BUILTINS([goom])
AX_ADD_LDFLAGS([goom],[-L${real_goom_tree} -lgoom])
AX_ADD_CPPFLAGS([goom],[-I${real_goom_tree}])
AX_ADD_LDFLAGS([goom],[-L${real_goom_tree}/src/.libs -lgoom2])
AX_ADD_CPPFLAGS([goom],[-I${real_goom_tree}/src -DUSE_GOOM_TREE])
else
dnl The given libgoom wasn't built
AC_MSG_RESULT(no)
AC_MSG_ERROR([cannot find ${real_goom_tree}/libgoom.a, make sure you compiled goom in ${with_goom_tree}])
AC_MSG_ERROR([cannot find ${real_goom_tree}/src/.libs/libgoom2.a, make sure you compiled goom in ${with_goom_tree}])
fi
else
dnl The --with-goom-tree isn't specified wasn't built
AC_MSG_RESULT(no)
AC_MSG_ERROR([You have to specify a tree with --with-goom-tree])
AC_CHECK_HEADERS(goom/goom.h, [
AC_CHECK_LIB(goom2, goom_init, [
AX_ADD_PLUGINS([goom])
AX_ADD_LDFLAGS([goom],[-lgoom2])
],[
AC_MSG_ERROR([Could not find goom on your system: you may get it from http://www.ios-software.com/.])
])
])
fi
fi

View File

@ -35,8 +35,10 @@
#include <vlc/vout.h>
#include "aout_internal.h"
#ifndef WIN32
#include "goom_core.h"
#ifdef USE_GOOM_TREE
# include "goom.h"
#else
# include <goom/goom.h>
#endif
/*****************************************************************************
@ -299,6 +301,7 @@ static void Thread( vlc_object_t *p_this )
audio_date_t i_pts;
int16_t p_data[2][512];
int i_data = 0, i_count = 0;
PluginInfo *p_plugin_info;
var_Get( p_this, "goom-width", &width );
var_Get( p_this, "goom-height", &height );
@ -308,8 +311,7 @@ static void Thread( vlc_object_t *p_this )
speed.i_int = MAX_SPEED - speed.i_int;
if( speed.i_int < 0 ) speed.i_int = 0;
goom_init( width.i_int, height.i_int, 0 );
goom_set_font( NULL, NULL, NULL );
p_plugin_info = goom_init( width.i_int, height.i_int );
while( !p_thread->b_die )
{
@ -329,7 +331,8 @@ static void Thread( vlc_object_t *p_this )
/* Frame dropping if necessary */
if( aout_DateGet( &i_pts ) + GOOM_DELAY <= mdate() ) continue;
plane = goom_update( p_data, 0, 0.0, p_thread->psz_title, NULL );
plane = goom_update( p_plugin_info, p_data, 0, 0.0,
p_thread->psz_title, NULL );
if( p_thread->psz_title )
{
@ -351,7 +354,7 @@ static void Thread( vlc_object_t *p_this )
vout_DisplayPicture( p_thread->p_vout, p_pic );
}
goom_close();
goom_close( p_plugin_info );
}
/*****************************************************************************