]> git.sesse.net Git - mlt/commitdiff
Merge branch 'videostab' of https://github.com/gmarco/mlt into videostab
authorDan Dennedy <dan@dennedy.org>
Sat, 31 Dec 2011 19:03:43 +0000 (11:03 -0800)
committerDan Dennedy <dan@dennedy.org>
Sat, 31 Dec 2011 19:03:43 +0000 (11:03 -0800)
Conflicts:
src/modules/videostab/transform_image.c

configure
src/framework/Makefile
src/framework/configure
src/framework/mlt_property.h
src/mlt++/configure
src/modules/avformat/factory.c
src/modules/core/producer_noise.c
src/modules/jackrack/factory.c
src/modules/jackrack/plugin_mgr.c
src/modules/rtaudio/RtAudio.cpp
src/modules/rtaudio/configure [new file with mode: 0755]

index 337f67b90a9682f6bbead066cb8757d7d38c3c32..52ff24d5f233073ed53a2f8e480518d0aa880b3e 100755 (executable)
--- a/configure
+++ b/configure
@@ -88,7 +88,7 @@ build_config()
                echo "SHFLAGS=-dynamiclib"
                echo "LDFLAGS+=`sdl-config --libs`"
                ;;
-               Linux|GNU/kFreeBSD)
+               Linux|GNU/kFreeBSD|GNU)
                [ "$(uname -m)" = "x86_64" ] && echo "ARCH_X86_64=1" && echo "CFLAGS+=-DARCH_X86_64"
                [ "$optimisations" = "true" ] &&
                        echo "OPTIMISATIONS+=-ffast-math"
index 004d3e5ad21f05f5f56cd42ecf8d769b7761e1a3..a493dfbc2b24224b9279acde0fa151caf95037f5 100644 (file)
@@ -1,4 +1,5 @@
 include ../../config.mak
+include config.mak
 
 NAME = libmlt$(LIBSUF)
 TARGET = $(NAME).$(version)
@@ -17,6 +18,11 @@ NAME = libmlt$(LIBSUF)
 TARGET = $(NAME).$(version)
 SONAME = $(NAME).$(soversion)
 SHFLAGS += -Wl,-soname,$(SONAME)
+       ifeq ($(targetos), FreeBSD)
+               ifdef HAVE_SYS_PARAM_H
+                       CFLAGS += -DHAVE_SYS_PARAM_H
+               endif
+       endif
 endif
 
 OBJS = mlt_frame.o \
index 52655ae6d3c02f8142937337ba99f4c27b032d9e..439a473e3f9107629652287e580d10ae1c656e3e 100755 (executable)
@@ -1,2 +1,10 @@
 #!/bin/sh
 echo "framework        -I$prefix/include -I$prefix/include/mlt -D_REENTRANT    -L$libdir -lmlt" >> ../../packages.dat
+
+echo -n > config.mak
+if [ "$(uname -s)" = "FreeBSD" ]
+then
+       printf "#include <sys/param.h>\n int main(){ return 0;}" | gcc -c -x c - >/dev/null 2>&1
+       [ "$?" -eq 0 ] && echo "HAVE_SYS_PARAM_H=1" >> config.mak
+fi
+exit 0
index 2f92ff76d0552aa71074e4dbb2a9e1e72ff7c6df..c50302f779d262cb84366f5bb807edb53094cb8a 100644 (file)
 
 #include "mlt_types.h"
 
-#if defined(__GLIBC__) || defined(__DARWIN__)
+#ifdef HAVE_SYS_PARAM_H
+#include <sys/param.h>
+#endif
+
+#if defined(__GLIBC__) || defined(__DARWIN__) || (__FreeBSD_version >= 1000002)
 #include <xlocale.h>
 #else
 typedef void* locale_t;
index ee01e08b6eb6513bd7e344045ca0823d506c5a7d..98e470af90d2fa6d59949a27e307de51bb58fd0e 100755 (executable)
@@ -10,7 +10,7 @@ case $targetos in
                echo "CXXFLAGS+=-D__DARWIN__ -Wall -fPIC"
                echo "LIBFLAGS=-dynamiclib -single_module"
                ;;
-       Linux|FreeBSD|NetBSD|GNU/kFreeBSD)
+       Linux|FreeBSD|NetBSD|GNU/kFreeBSD|GNU)
                echo LIBSUF=.so
                echo "CXXFLAGS+=-Wall $WARNINGS -fPIC -DPIC"
                echo "LIBFLAGS=-shared"
index b5a097b7f60ddb14b7e3dc288b795387462365c7..7676f868b99479e7cc34cf1690c2000bdf7a8436 100644 (file)
@@ -100,6 +100,9 @@ static void avformat_init( )
                av_register_all( );
 #ifdef AVDEVICE
                avdevice_register_all();
+#endif
+#if LIBAVFORMAT_VERSION_INT >= ((53<<16)+(13<<8))
+               avformat_network_init();
 #endif
                mlt_factory_register_for_clean_up( NULL, avformat_destroy );
                av_log_set_level( mlt_log_get_level() );
index 4b9bf21f2e3dbad90a8c1d4482876fe539952ce5..3c676f41dc089ed5e5aa524471470d03063f1b9c 100644 (file)
@@ -112,6 +112,7 @@ static int producer_get_audio( mlt_frame frame, int16_t **buffer, mlt_audio_form
        *samples = *samples <= 0 ? 1920 : *samples;
        *channels = *channels <= 0 ? 2 : *channels;
        *frequency = *frequency <= 0 ? 48000 : *frequency;
+       *format = mlt_audio_s16;
 
        // Calculate the size of the buffer
        size = *samples * *channels * sizeof( int16_t );
index 0c18642abc62ad23b84429e8946d0f4ecf2a412d..7ba3bf8585723efbae3557902e7eb3e7f4ccf539 100644 (file)
@@ -144,8 +144,9 @@ MLT_REPOSITORY
                sprintf( s, "ladspa.%lu", desc->id );
                MLT_REGISTER( filter_type, s, filter_ladspa_init );
                MLT_REGISTER_METADATA( filter_type, s, metadata, NULL );
+               free( s );
        }
-//     mlt_factory_register_for_clean_up( g_jackrack_plugin_mgr, (mlt_destructor) plugin_mgr_destroy );
+       mlt_factory_register_for_clean_up( g_jackrack_plugin_mgr, (mlt_destructor) plugin_mgr_destroy );
 
        MLT_REGISTER( filter_type, "jackrack", filter_jackrack_init );
        MLT_REGISTER_METADATA( filter_type, "jackrack", metadata, "filter_jackrack.yml" );
index 0d67162fb2c5df9448de3635d34f55ca8b3b2e62..b3128cdf900f9af87acdfaf6f4e4b205ea05065e 100644 (file)
@@ -80,7 +80,7 @@ plugin_mgr_get_object_file_plugins (plugin_mgr_t * plugin_mgr, const char * file
   int err;
   
   /* open the object file */
-  dl_handle = dlopen (filename, RTLD_NOW|RTLD_GLOBAL);
+  dl_handle = dlopen (filename, RTLD_LAZY);
   if (!dl_handle)
     {
       mlt_log_info( NULL, "%s: error opening shared object file '%s': %s\n",
index f6b4685243372d380fdd2a632078efb23db96cbc..2bdd89b9884bbc22d590d35fea9ab9e3f3eb17f2 100644 (file)
@@ -6373,7 +6373,7 @@ extern "C" void *alsaCallbackHandler( void *ptr )
 #include <sys/ioctl.h>\r
 #include <unistd.h>\r
 #include <fcntl.h>\r
-#include "soundcard.h"\r
+#include <sys/soundcard.h>\r
 #include <errno.h>\r
 #include <math.h>\r
 \r
diff --git a/src/modules/rtaudio/configure b/src/modules/rtaudio/configure
new file mode 100755 (executable)
index 0000000..3543db6
--- /dev/null
@@ -0,0 +1,12 @@
+#!/bin/sh
+
+if [ "$help" != "1" ]
+then
+
+       if [ "$targetos" != "Darwin" ] && [ "$targetos" != "MinGW" ] && [ "$targetos" != "Linux" ]
+       then
+               echo "- only builds on Linux, OS X, or Windows: disabling"
+               touch ../disable-rtaudio
+               exit 0
+       fi
+fi