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.

 

Go Back   Doom9's Forum > Capturing and Editing Video > VapourSynth

Reply
 
Thread Tools Search this Thread Display Modes
Old 10th December 2016, 02:29   #141  |  Link
xekon
Registered User
 
Join Date: Jul 2011
Posts: 224
jackoneill, I tried your fork, upon loading the sample in VSedit that I provided here, and pressing F5 to generate a preview, it at first appeared to be a proper frame, no graphical anomilyies.

But if you use the seek bar to change a frames a few times, it appears I still get the garbled output.

Both your fork, and the d2vsource I was originally using, output good frames (no garbled picture) if I add 'rff=False' from this:
Code:
import vapoursynth as vs
core = vs.get_core()
ret = core.d2v.Source(input=r'/media/sf_enc/005t.d2v')
ret.set_output()
to this:

Code:
import vapoursynth as vs
core = vs.get_core()
ret = core.d2v.Source(input=r'/media/sf_enc/005t.d2v', rff=False)
ret.set_output()
could It be something to do with my install method?
I shared it here: http://pastebin.com/wDttQwHP
running kubuntu 16.04.1

Last edited by xekon; 10th December 2016 at 02:33.
xekon is offline   Reply With Quote
Old 10th December 2016, 14:07   #142  |  Link
jackoneill
unsigned int
 
jackoneill's Avatar
 
Join Date: Oct 2012
Location: 🇪🇺
Posts: 760
Quote:
Originally Posted by xekon View Post
jackoneill, I tried your fork, upon loading the sample in VSedit that I provided here, and pressing F5 to generate a preview, it at first appeared to be a proper frame, no graphical anomilyies.

But if you use the seek bar to change a frames a few times, it appears I still get the garbled output.

Both your fork, and the d2vsource I was originally using, output good frames (no garbled picture) if I add 'rff=False' from this:
Code:
import vapoursynth as vs
core = vs.get_core()
ret = core.d2v.Source(input=r'/media/sf_enc/005t.d2v')
ret.set_output()
to this:

Code:
import vapoursynth as vs
core = vs.get_core()
ret = core.d2v.Source(input=r'/media/sf_enc/005t.d2v', rff=False)
ret.set_output()
could It be something to do with my install method?
I shared it here: http://pastebin.com/wDttQwHP
running kubuntu 16.04.1
I don't see anything wrong in your install method.

Perhaps you should load the new d2vsource plugin directly, to be sure you're testing the right one.

Does it only happen with random access, or can you get the garbled images by moving one frame at a time with the right arrow? If yes, can you get the garbled images by using vspipe instead of vsedit?
Code:
vspipe 005t.py 005t.y4m --y4m
__________________
Buy me a "coffee" and/or hire me to write code!
jackoneill is offline   Reply With Quote
Old 10th December 2016, 16:05   #143  |  Link
xekon
Registered User
 
Join Date: Jul 2011
Posts: 224
I just made sure to remove the original d2vsource:
sudo rm /usr/local/lib/libd2vsource.so
sudo rm /usr/local/lib/libd2vsource.la
sudo rm /usr/local/lib/vapoursynth/d2vscan.pl
sudo rm /usr/local/lib/vapoursynth/d2vsource.so

at this point I could no longer use core.d2v.Source()

I then reinstalled your fork, same result, I tried pressing the right arrow key, as i go frame by frame, roughly half of them display garbled.

I would be happy to explicitly load your plugin if you need, what is the code to do that?

wasnt sure how to view the output of 005t.y4m so i did this:
vspipe --y4m 005t.vpy - | x264 --demuxer y4m - --output 005t.mkv

here is a video without using rff=False, oddly the output is not garbled like it is in vapoursynth, there just appears to be some kind of interlacing visible(look at raditz black hair as the frame zooms out.)
http://www.mediafire.com/file/8g7285x2dlr99cc/005t.mkv

here is one using rff=False, this one does not show interlacing or garbled output in vsedit.
http://www.mediafire.com/file/58hi1w..._rff_False.mkv

Last edited by xekon; 10th December 2016 at 16:13.
xekon is offline   Reply With Quote
Old 10th December 2016, 22:37   #144  |  Link
jackoneill
unsigned int
 
jackoneill's Avatar
 
Join Date: Oct 2012
Location: 🇪🇺
Posts: 760
After updating everything, I figured it out. The problem is not in d2vsource but in VapourSynth's resizer, which vsedit uses to convert to RGB for display.

Just for future reference, this is how you load a plugin manually:
Code:
core.std.LoadPlugin("/some/place/libd2vsource.so")
__________________
Buy me a "coffee" and/or hire me to write code!
jackoneill is offline   Reply With Quote
Old 10th December 2016, 22:43   #145  |  Link
xekon
Registered User
 
Join Date: Jul 2011
Posts: 224
Right on Jackoneill! way to go dude.
xekon is offline   Reply With Quote
Old 10th December 2016, 23:08   #146  |  Link
Mystery Keeper
Beyond Kawaii
 
Mystery Keeper's Avatar
 
Join Date: Feb 2008
Location: Russia
Posts: 724
Quote:
Originally Posted by jackoneill View Post
After updating everything, I figured it out. The problem is not in d2vsource but in VapourSynth's resizer, which vsedit uses to convert to RGB for display.
With resizer itself or with the way I use it?
__________________
...desu!
Mystery Keeper is offline   Reply With Quote
Old 11th December 2016, 11:04   #147  |  Link
jackoneill
unsigned int
 
jackoneill's Avatar
 
Join Date: Oct 2012
Location: 🇪🇺
Posts: 760
Quote:
Originally Posted by Mystery Keeper View Post
With resizer itself or with the way I use it?
The resizer itself. vsedit is not required to reproduce the bug. See https://github.com/vapoursynth/vapoursynth/issues/256
__________________
Buy me a "coffee" and/or hire me to write code!
jackoneill is offline   Reply With Quote
Old 30th January 2017, 03:13   #148  |  Link
xekon
Registered User
 
Join Date: Jul 2011
Posts: 224
so I'm trying to compile this as a DLL for use on windows, having never used mingw or msys before, was hoping somebody could help.
Code:
$ ./autogen.sh
./autogen.sh: line 3: autoreconf: command not found

Last edited by xekon; 3rd February 2017 at 02:00.
xekon is offline   Reply With Quote
Old 30th January 2017, 03:40   #149  |  Link
JoeyMonco
Guest
 
Posts: n/a
You don't have autotools installed.
  Reply With Quote
Old 30th January 2017, 03:43   #150  |  Link
JoeyMonco
Guest
 
Posts: n/a
Quote:
Originally Posted by xekon View Post
oh I just assumed that was part of the msys2 package, i will have to try and figure out how to get that installed then, thank you.
Or maybe your PATH isn't set up correctly? *shrug*
  Reply With Quote
Old 30th January 2017, 05:46   #151  |  Link
xekon
Registered User
 
Join Date: Jul 2011
Posts: 224
Thank you JoeyMonco, your posts steered me in the correct direction, after a couple google searches I found that you have to install autotools using pacman
now it gets stuck running configure:

Code:
$ ./configure
checking for VapourSynth... no
configure: error: Package requirements (vapoursynth) were not met:

No package 'vapoursynth' found

Consider adjusting the PKG_CONFIG_PATH environment variable if you
installed software in a non-standard prefix.

Alternatively, you may set the environment variables VapourSynth_CFLAGS
and VapourSynth_LIBS to avoid the need to call pkg-config.
See the pkg-config man page for more details.

Last edited by xekon; 3rd February 2017 at 02:02.
xekon is offline   Reply With Quote
Old 30th January 2017, 05:52   #152  |  Link
JoeyMonco
Guest
 
Posts: n/a
And the location to the PKG_CONFIG_PATH as the error states.
  Reply With Quote
Old 30th January 2017, 05:54   #153  |  Link
xekon
Registered User
 
Join Date: Jul 2011
Posts: 224
what do I need to set VapourSynth_CFLAGS and VapourSynth_LIBS to? seems that would be the easier route, no .pc file needed.

Code:
export VapourSynth_CFLAGS=what goes here?
export VapourSynth_LIBS=and what goes here?

Last edited by xekon; 30th January 2017 at 06:37.
xekon is offline   Reply With Quote
Old 30th January 2017, 12:50   #154  |  Link
jackoneill
unsigned int
 
jackoneill's Avatar
 
Join Date: Oct 2012
Location: 🇪🇺
Posts: 760
Quote:
Originally Posted by xekon View Post
what do I need to set VapourSynth_CFLAGS and VapourSynth_LIBS to? seems that would be the easier route, no .pc file needed.

Code:
export VapourSynth_CFLAGS=what goes here?
export VapourSynth_LIBS=and what goes here?
For the CFLAGS you need the folder where VapourSynth.h is. For the LIBS you just need a harmless string to make configure happy (it can't be empty).

Code:
VapourSynth_CFLAGS="-I/some/folder"
VapourSynth_LIBS="-L."
__________________
Buy me a "coffee" and/or hire me to write code!
jackoneill is offline   Reply With Quote
Old 30th January 2017, 14:23   #155  |  Link
xekon
Registered User
 
Join Date: Jul 2011
Posts: 224
thank you so much jackoneill, i got your other post showing me the workaround as well.
but for the sake of learning I would still like to try building this, I made those changes and have successfully ran ./configure now

now when I tried to run 'make' i was getting TONS of 'undefined reference to `std::__cxx11::basic_string' messages.
I resolved those by opening all the .cpp .hpp files in the d2vsource folder and adding the following to the top of each file:
Code:
#define _GLIBCXX_USE_CXX11_ABI 0

Here is my current install routine:
1. msys2-x86_64-20161025.exe http://msys2.github.io/
install to c:\msys64

2. win-builds-1.5.0.exe http://win-builds.org/doku.php/downl...n_from_windows
select "Cygwin or MSYS" and "x86_64", on the next page click process in the top right corner.

3. download d2vsource-master and vapoursynth-master, extract and place into C:\msys64\
you should have the following directory structure:
C:\msys64\d2vsource-master\autogen.sh
C:\msys64\vapoursynth-master\include\VapourSynth.h

4. open the MSYS2 MinGW 64-bit shell, enter the following to install autotools:
Code:
pacman -S make pkgconfig autoconf automake autogen libtool mingw-w64-x86_64-gcc
pacman -Syuu
5. update your "PKG_CONFIG_PATH", to view its current value enter:
Code:
echo ${PKG_CONFIG_PATH}
update it to include win-builds files, also set vapoursynth flags/libs:
Code:
export PKG_CONFIG_PATH="/mingw64/lib/pkgconfig:/mingw64/share/pkgconfig:/opt/windows_64/lib64/pkgconfig"
export VapourSynth_CFLAGS="-I/vapoursynth-master/include"
export VapourSynth_LIBS="-L."
6. navigate to the d2vsource folder and build the project:
Code:
cd /d2vsource-master
./autogen.sh
./configure
make
make install

Last edited by xekon; 3rd February 2017 at 02:04.
xekon is offline   Reply With Quote
Old 2nd February 2017, 20:14   #156  |  Link
Pat357
Registered User
 
Join Date: Jun 2006
Posts: 452
Code:
pacman -S mingw-w64-x86_64-gcc
should've been be installed with GCC, but maybe you have another version hanging around ?

If the above doesn't work, try
Code:
pacman -S --force mingw-w64-x86_64-gcc
Pat357 is offline   Reply With Quote
Old 3rd February 2017, 02:09   #157  |  Link
xekon
Registered User
 
Join Date: Jul 2011
Posts: 224
Thank you Pat357, I tried the force command as you showed, and it reinstalled that package, but I am still getting the same errors, is there a way to "force" when running make? something like: "make --force mingw64"?
looking at my shell prompt I can see its in MINGW64 mode, it shows it on the end of my command prompt in purple, just before the directory im currently in.

I updated my current complete install routine in my previous post, have uninstalled and reinstalled a few times so far: https://forum.doom9.org/showpost.php...&postcount=155

here is the error message I am getting when running 'make'
Code:
$ make
  CXX      src/core/compat.lo
  CXX      src/core/d2v.lo
  CXX      src/core/decode.lo
  CXX      src/vs/applyrff.lo
  CXX      src/vs/d2vsource.lo
  CXX      src/vs/directrender.lo
  CXX      src/vs/vapoursynth.lo
  CXXLD    libd2vsource.la
src/core/.libs/compat.o:compat.cpp:(.text+0xde): undefined reference to `std::__throw_out_of_range_fmt(char const*, ...)'
src/core/.libs/d2v.o:d2v.cpp:(.text+0x2c2): undefined reference to `std::__throw_out_of_range_fmt(char const*, ...)'
src/core/.libs/d2v.o:d2v.cpp:(.text+0x3c5): undefined reference to `std::__throw_out_of_range_fmt(char const*, ...)'
src/core/.libs/d2v.o:d2v.cpp:(.text+0x491): undefined reference to `operator delete[](void*, unsigned long long)'
src/core/.libs/d2v.o:d2v.cpp:(.text+0x4e1): undefined reference to `operator delete(void*, unsigned long long)'
src/core/.libs/d2v.o:d2v.cpp:(.text+0x11f1): undefined reference to `std::__throw_out_of_range_fmt(char const*, ...)'
src/core/.libs/d2v.o:d2v.cpp:(.text+0x1b56): undefined reference to `std::__throw_out_of_range_fmt(char const*, ...)'
src/core/.libs/d2v.o:d2v.cpp:(.text+0x1be1): undefined reference to `std::__throw_out_of_range_fmt(char const*, ...)'
src/core/.libs/d2v.o:d2v.cpp:(.text+0x1bf7): undefined reference to `std::__throw_out_of_range_fmt(char const*, ...)'
src/core/.libs/d2v.o:d2v.cpp:(.text+0x1c0d): undefined reference to `std::__throw_out_of_range_fmt(char const*, ...)'
src/core/.libs/d2v.o:d2v.cpp:(.text+0x1c23): more undefined references to `std::__throw_out_of_range_fmt(char const*, ...)' follow
src/core/.libs/d2v.o:d2v.cpp:(.text+0x1cf4): undefined reference to `operator delete[](void*, unsigned long long)'
src/core/.libs/decode.o:decode.cpp:(.text+0x3cc): undefined reference to `operator delete(void*, unsigned long long)'
src/core/.libs/decode.o:decode.cpp:(.text+0x3f4): undefined reference to `operator delete(void*, unsigned long long)'
src/core/.libs/decode.o:decode.cpp:(.text+0x1034): undefined reference to `operator delete(void*, unsigned long long)'
src/vs/.libs/applyrff.o:applyrff.cpp:(.text+0x76b): undefined reference to `operator delete(void*, unsigned long long)'
src/vs/.libs/applyrff.o:applyrff.cpp:(.text+0x58): undefined reference to `operator delete(void*, unsigned long long)'
src/vs/.libs/directrender.o:directrender.cpp:(.text+0x24): more undefined references to `operator delete(void*, unsigned long long)' follow
collect2.exe: error: ld returned 1 exit status
make: *** [Makefile:502: libd2vsource.la] Error 1
also here is the output from checking gcc version gcc -v:
Code:
xekon@xekon-PC MINGW64 /d2vsource-master
$ gcc -v
Using built-in specs.
COLLECT_GCC=C:\msys64\mingw64\bin\gcc.exe
COLLECT_LTO_WRAPPER=C:/msys64/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/6.3.0/lto-wrapper.exe
Target: x86_64-w64-mingw32
Configured with: ../gcc-6.3.0/configure --prefix=/mingw64 --with-local-prefix=/mingw64/local --build=x86_64-w64-mingw32 --host=x86_64-w64-mingw32
   --target=x86_64-w64-mingw32 --with-native-system-header-dir=/mingw64/x86_64-w64-mingw32/include --libexecdir=/mingw64/lib --enable-bootstrap
   --with-arch=x86-64 --with-tune=generic --enable-languages=c,lto,c++,objc,obj-c++,fortran,ada --enable-shared --enable-static --enable-libatomic
   --enable-threads=posix --enable-graphite --enable-fully-dynamic-string --enable-libstdcxx-time=yes --disable-libstdcxx-pch --disable-libstdcxx-debug
   --disable-isl-version-check --enable-lto --enable-libgomp --disable-multilib --enable-checking=release --disable-rpath --disable-win32-registry
   --disable-nls --disable-werror --disable-symvers --with-libiconv --with-system-zlib --with-gmp=/mingw64 --with-mpfr=/mingw64 --with-mpc=/mingw64
   --with-isl=/mingw64 --with-pkgversion='Rev1, Built by MSYS2 project' --with-bugurl=https://sourceforge.net/projects/msys2 --with-gnu-as --with-gnu-ld
Thread model: posix
gcc version 6.3.0 (Rev1, Built by MSYS2 project)

Last edited by xekon; 3rd February 2017 at 05:40.
xekon is offline   Reply With Quote
Old 6th February 2017, 21:59   #158  |  Link
jackoneill
unsigned int
 
jackoneill's Avatar
 
Join Date: Oct 2012
Location: 🇪🇺
Posts: 760
Does it help to know that those missing symbols are part of the standard C++ library (libstdc++)? I have no idea how to fix the problem.
__________________
Buy me a "coffee" and/or hire me to write code!
jackoneill is offline   Reply With Quote
Old 7th February 2017, 18:24   #159  |  Link
Pat357
Registered User
 
Join Date: Jun 2006
Posts: 452
Updated d2vsource to latest git

Since some important bugs have been fixed in d2vsource since v1.0 was released,
I've compiled both ffmpeg and d2vsource from git (6021968)

See https://github.com/dwbuiten/d2vsource/commits/master for changes since d2vsource v1.0

Code:
Commits on Dec 24, 2016

    @dwbuiten

    Merge pull request #31 from dubhater/master
    dwbuiten committed on GitHub on 24 Dec 2016

Commits on Dec 9, 2016

    @dubhater

    applyrff: Make it actually work 

dubhater committed on 9 Dec 2016
Commits on Aug 13, 2016

    @dubhater

    d2vsource: Avoid double free 

dubhater committed on 13 Aug 2016
Commits on Aug 9, 2016

    @dubhater

    Remove outdated comment
    dubhater committed on 9 Aug 2016

Commits on Jul 25, 2016

    @dwbuiten

    Merge pull request #29 from dubhater/master 

dwbuiten committed on GitHub on 25 Jul 2016
Commits on Jun 21, 2016

    @dubhater

    d2vsource: Fix inverted _ColorRange frame property 

dubhater committed on 21 Jun 2016

Here are the latest windows binaries (x86 & x64) compiled under Mingw64 using GCC v6.3.0 :

http://www33.zippyshare.com/v/4GGpY6Yb/file.html

Let me know if you have problems with this version.
All credits go to dwbuiten & dubhater for all the coding.

Last edited by Pat357; 8th February 2017 at 18:41.
Pat357 is offline   Reply With Quote
Old 7th February 2017, 19:16   #160  |  Link
Pat357
Registered User
 
Join Date: Jun 2006
Posts: 452
Quote:
Originally Posted by xekon View Post
here is the error message I am getting when running 'make'
I agree that your problem has to do with libstdc++.a.
Can you find this file in /ming64 ? If no were's it on your system ?

Open a MSYS2 console and do pacman -Syu to update everything, just to be sure.

I've seen similar errors after this lib got updated and you use other libs which were compiled before the update i.e 2 different versions can give this error.
Make sure you recompile ffmpeg and ALL it's libs to make sure they all use the latest libstdc++.a (you can temporally rename libstdc++.dll.a)
How do you configure ffmpeg ?

further set LIBS="-lstdc++" right before configure (for d2vsource) like this :
Code:
./autogen.sh
[[ -f Makefile || -f config.log ]] && make distclean
LDFLAGS+=" -static-libgcc -static-libstdc++"  CXXFLAGS+=" -static-libgcc" \
LIBS="-lstdc++"  ./configure  ##     (yes on the same line)
make
make install
Try this and let me know.
You can also try my compile ;-)

Last edited by Pat357; 11th February 2017 at 17:53. Reason: typo : Makefile starts with capital)
Pat357 is offline   Reply With Quote
Reply

Tags
d2v, dgindex, vapoursynth

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT +1. The time now is 22:31.


Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2024, vBulletin Solutions Inc.