diff --git a/Makefile.am b/Makefile.am new file mode 100644 index 0000000..a02c018 --- /dev/null +++ b/Makefile.am @@ -0,0 +1,13 @@ +warning_flags = -Wall -Wextra -Wshadow -Wno-unused-parameter +common_cflags = -O3 $(MFLAGS) $(warning_flags) +AM_CXXFLAGS = -std=c++11 $(common_cflags) + +AM_CPPFLAGS = $(VapourSynth_CFLAGS) $(LIBBLURAY_CFLAGS) + +lib_LTLIBRARIES = libreadmpls.la + +libreadmpls_la_SOURCES = ReadMpls/ReadMpls.cpp + +libreadmpls_la_LIBADD = $(LIBBLURAY_LIBS) + +libreadmpls_la_LDFLAGS = -no-undefined -avoid-version $(PLUGINLDFLAGS) diff --git a/README.md b/README.md index 00cd9d1..dd78ee5 100644 --- a/README.md +++ b/README.md @@ -11,8 +11,22 @@ Usage * source: The full path of the mpls file. Don't use relative path. + After obtaining the dictionary, you can use your favorite source filter to open them all with a for-loop and splice them together. For example: + ```python mpls = core.mpls.Read('D:/rule6/BDMV/PLAYLIST/00001.mpls') ret = core.std.Splice([core.ffms2.Source(mpls['clip'][i]) for i in range(mpls['count'])]) ``` + + +Compilation +=========== + +Requires libbluray for compiling. + +``` +./autogen.sh +./configure +make +``` diff --git a/autogen.sh b/autogen.sh new file mode 100644 index 0000000..a8fd885 --- /dev/null +++ b/autogen.sh @@ -0,0 +1,3 @@ +#!/bin/sh + +autoreconf --verbose --install --force diff --git a/configure.ac b/configure.ac new file mode 100644 index 0000000..dfa1c05 --- /dev/null +++ b/configure.ac @@ -0,0 +1,49 @@ +AC_INIT([ReadMpls], [1], [https://github.com/HomeOfVapourSynthEvolution/VapourSynth-ReadMpls/issues], [EEDI2], [https://github.com/HomeOfVapourSynthEvolution/VapourSynth-ReadMpls/]) + +: ${CXXFLAGS=""} + +AM_INIT_AUTOMAKE([foreign no-dist-gzip dist-xz subdir-objects no-define]) +AM_SILENT_RULES([yes]) + +LT_INIT([disable-static win32-dll]) + +AC_PROG_CXX + +AC_CANONICAL_HOST + + +X86="false" + +AS_CASE( + [$host_cpu], + [i?86], [BITS="32" X86="true"], + [x86_64], [BITS="64" X86="true"], +) + +AS_CASE( + [$host_os], + [cygwin*|mingw*], + [ + AS_IF( + [test "x$BITS" = "x32"], + [ + AC_SUBST([PLUGINLDFLAGS], ["-Wl,--kill-at"]) + ] + ) + ] +) + +AS_IF( + [test "x$X86" = "xtrue"], + [ + AC_SUBST([MFLAGS], ["-mfpmath=sse -msse2"]) + ] +) + + +PKG_CHECK_MODULES([VapourSynth], [vapoursynth]) + +PKG_CHECK_MODULES([LIBBLURAY], [libbluray]) + +AC_CONFIG_FILES([Makefile]) +AC_OUTPUT