Welcome to Doom9's Forum, THE in-place to be for everyone interested in DVD conversion. Before you start posting please read the forum rules. By posting to this forum you agree to abide by the rules. |
3rd August 2014, 16:38 | #1 | Link |
Registered User
Join Date: Aug 2006
Location: Taiwan
Posts: 392
|
Deblock
https://github.com/HomeOfVapourSynth...Synth-Deblock/
Ported from the usual AviSynth plugin http://www.avisynth.nl/users/fizick/...s/deblock.html. Nothing new or interesting really. Just picked a plugin which is simple enough for me to practice porting plugin. Last edited by HolyWu; 13th June 2017 at 18:02. |
3rd August 2014, 17:41 | #3 | Link |
Professional Code Monkey
Join Date: Jun 2003
Location: Kinnarps Chair
Posts: 2,555
|
It's the code review patrol!
This is the only definitively wrong part: Code:
if (!isConstantFormat(d.vi) || d.vi->format->colorFamily == cmCompat || d.vi->format->sampleType != stInteger || d.vi->format->bytesPerSample > 2) { vsapi->setError(out, "Deblock: only constant format 8-16 bits integer input supported"); vsapi->freeNode(d.node); return; } Code:
if (!isConstantFormat(d.vi) || d.vi->format->sampleType != stInteger || (d.vi->format->bitsPerSample != 8 && d.vi->format->bitsPerSample != 16)) { vsapi->setError(out, "Deblock: only constant format 8 or 16 bits integer input supported"); vsapi->freeNode(d.node); return; } 1. Normal filters will never get cmCompat formats as input so no need to check for it 2. You actual processing code actually only works for 8 and 16 bit. For 9-15 bits you don't clamp the output range properly so the output will technically be invalid. You could of course fix the clamping too for the 9-16 bit case which is probably more elegant.
__________________
VapourSynth - proving that scripting languages and video processing isn't dead yet |
12th June 2017, 13:04 | #11 | Link |
Registered User
Join Date: Feb 2015
Posts: 38
|
It seems like the VS DeBlock does something diffrent than the AV-version. With quant=25 the AV-version seems to do a better job at deblocking.
http://screenshotcomparison.com/comparison/212508 Edit: AS=Vapoursynth, AV=Avisynth (Some weird typo I did there..) Last edited by TalasNetrag; 13th June 2017 at 20:53. |
13th June 2017, 17:50 | #12 | Link | |
Registered User
Join Date: Aug 2006
Location: Taiwan
Posts: 392
|
Update r6.
Quote:
|
|
3rd August 2017, 17:29 | #17 | Link |
Registered User
Join Date: Apr 2016
Posts: 85
|
Mostly compiled from scratch, though I might have attempted a brew install at some point.
HolyWu, running that command, I get the following: Code:
autoreconf: Entering directory `.' autoreconf: configure.ac: not using Gettext autoreconf: running: aclocal --force autoreconf: configure.ac: tracing autoreconf: running: glibtoolize --copy --force glibtoolize: putting auxiliary files in '.'. glibtoolize: copying file './ltmain.sh' glibtoolize: Consider adding 'AC_CONFIG_MACRO_DIRS([m4])' to configure.ac, glibtoolize: and rerunning glibtoolize and aclocal. glibtoolize: Consider adding '-I m4' to ACLOCAL_AMFLAGS in Makefile.am. autoreconf: running: /usr/local/Cellar/autoconf/2.69/bin/autoconf --force autoreconf: configure.ac: not using Autoheader autoreconf: running: automake --add-missing --copy --force-missing configure.ac:8: installing './compile' configure.ac:8: installing './config.guess' configure.ac:8: installing './config.sub' configure.ac:5: installing './install-sh' configure.ac:5: installing './missing' Makefile.am: installing './depcomp' autoreconf: Leaving directory `.' checking for a BSD-compatible install... /usr/local/bin/ginstall -c checking whether build environment is sane... yes checking for a thread-safe mkdir -p... /usr/local/bin/gmkdir -p checking for gawk... no checking for mawk... no checking for nawk... no checking for awk... awk checking whether make sets $(MAKE)... yes checking whether make supports nested variables... yes checking whether make supports nested variables... (cached) yes checking build system type... x86_64-apple-darwin15.6.0 checking host system type... x86_64-apple-darwin15.6.0 checking how to print strings... printf checking for style of include used by make... GNU checking for gcc... gcc checking whether the C compiler works... yes checking for C compiler default output file name... a.out checking for suffix of executables... checking whether we are cross compiling... no checking for suffix of object files... o checking whether we are using the GNU C compiler... yes checking whether gcc accepts -g... yes checking for gcc option to accept ISO C89... none needed checking whether gcc understands -c and -o together... yes checking dependency style of gcc... gcc3 checking for a sed that does not truncate output... /usr/bin/sed checking for grep that handles long lines and -e... /usr/local/bin/ggrep checking for egrep... /usr/local/bin/ggrep -E checking for fgrep... /usr/local/bin/ggrep -F checking for ld used by gcc... /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/ld checking if the linker (/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/ld) is GNU ld... no checking for BSD- or MS-compatible name lister (nm)... /usr/bin/nm -B checking the name lister (/usr/bin/nm -B) interface... BSD nm checking whether ln -s works... yes checking the maximum length of command line arguments... 196608 checking how to convert x86_64-apple-darwin15.6.0 file names to x86_64-apple-darwin15.6.0 format... func_convert_file_noop checking how to convert x86_64-apple-darwin15.6.0 file names to toolchain format... func_convert_file_noop checking for /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/ld option to reload object files... -r checking for objdump... no checking how to recognize dependent libraries... pass_all checking for dlltool... no checking how to associate runtime and link libraries... printf %s\n checking for ar... ar checking for archiver @FILE support... no checking for strip... strip checking for ranlib... ranlib checking command to parse /usr/bin/nm -B output from gcc object... ok checking for sysroot... no checking for a working dd... /bin/dd checking how to truncate binary pipes... /bin/dd bs=4096 count=1 checking for mt... no checking if : is a manifest tool... no checking for dsymutil... dsymutil checking for nmedit... nmedit checking for lipo... lipo checking for otool... otool checking for otool64... no checking for -single_module linker flag... yes checking for -exported_symbols_list linker flag... yes checking for -force_load linker flag... yes checking how to run the C preprocessor... gcc -E checking for ANSI C header files... yes checking for sys/types.h... yes checking for sys/stat.h... yes checking for stdlib.h... yes checking for string.h... yes checking for memory.h... yes checking for strings.h... yes checking for inttypes.h... yes checking for stdint.h... yes checking for unistd.h... yes checking for dlfcn.h... yes checking for objdir... .libs checking if gcc supports -fno-rtti -fno-exceptions... yes checking for gcc option to produce PIC... -fno-common -DPIC checking if gcc PIC flag -fno-common -DPIC works... yes checking if gcc static flag -static works... no checking if gcc supports -c -o file.o... yes checking if gcc supports -c -o file.o... (cached) yes checking whether the gcc linker (/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/ld) supports shared libraries... yes checking dynamic linker characteristics... darwin15.6.0 dyld checking how to hardcode library paths into programs... immediate checking whether stripping libraries is possible... yes checking if libtool supports shared libraries... yes checking whether to build shared libraries... yes checking whether to build static libraries... no checking for g++... g++ checking whether we are using the GNU C++ compiler... yes checking whether g++ accepts -g... yes checking dependency style of g++... gcc3 checking how to run the C++ preprocessor... g++ -E checking for ld used by g++... /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/ld checking if the linker (/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/ld) is GNU ld... no checking whether the g++ linker (/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/ld) supports shared libraries... yes checking for g++ option to produce PIC... -fno-common -DPIC checking if g++ PIC flag -fno-common -DPIC works... yes checking if g++ static flag -static works... no checking if g++ supports -c -o file.o... yes checking if g++ supports -c -o file.o... (cached) yes checking whether the g++ linker (/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/ld) supports shared libraries... yes checking dynamic linker characteristics... darwin15.6.0 dyld checking how to hardcode library paths into programs... immediate checking for pkg-config... /usr/local/bin/pkg-config checking pkg-config is at least version 0.9.0... yes checking for vapoursynth... yes checking that generated files are newer than configure... done configure: creating ./config.status config.status: creating Makefile config.status: executing depfiles commands config.status: executing libtool commands CXX Deblock/Deblock.lo CXXLD libdeblock.la |
3rd August 2017, 18:46 | #19 | Link |
Registered User
Join Date: Apr 2016
Posts: 85
|
...You are absolutely correct. Sorry for wild goose chase.
Specifically: "make" compiles it into a hidden folder: /VapourSynth-Deblock-master/.libs/libdeblock.dylib "make install" copies libdeblock.dylib to: /usr/local/lib/ |
|
|