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
Register FAQ Calendar Today's Posts Search

Reply
 
Thread Tools Search this Thread Display Modes
Old 3rd March 2018, 17:48   #41  |  Link
Selur
Registered User
 
Selur's Avatar
 
Join Date: Oct 2001
Location: Germany
Posts: 7,277
@l33tmeatwad:
Since I couldn't find ffmsindex or d2vwitch I went through all the filters I could think of that are not part of Vapoursynth directly and listed them:-> would be nice if you could add some of the currently not included filters (+ ffmsindex and d2vwitch) to the installer.

@halls: I have the same effect when using Vapoursynth editor when I used this script:
Code:
# Imports
import vapoursynth as vs
core = vs.get_core()
# Loading /Users/selur/Desktop/test.mp4 using FFMS2
clip = core.ffms2.Source(source="/Users/selur/Desktop/test.mp4",format=vs.YUV420P8,alpha=False)
# making sure input color matrix is set as 470bg
clip = core.resize.Point(clip, matrix_in_s="470bg")
# making sure frame rate is set to 30000/1001
clip = core.std.AssumeFPS(clip, fpsnum=30000, fpsden=1001)
# Making sure input color range is set to TV (limited) range.
clip = core.std.SetFrameProp(clip=clip, prop="_ColorRange", intval=1)
# adjusting output color from: YUV420P8 to YUV420P10 for x264Model (i420)
clip = core.resize.Bicubic(clip=clip, format=vs.YUV420P10)
# Output
clip.set_output()
-> Seems like a bug in either the editor or FFMS2. I even explicitly set the color format etc.

Cu Selur
__________________
Hybrid here in the forum, homepage
Selur is offline   Reply With Quote
Old 3rd March 2018, 19:10   #42  |  Link
jackoneill
unsigned int
 
jackoneill's Avatar
 
Join Date: Oct 2012
Location: 🇪🇺
Posts: 760
Quote:
Originally Posted by Selur View Post
@halls: I have the same effect when using Vapoursynth editor when I used this script:
Code:
# Imports
import vapoursynth as vs
core = vs.get_core()
# Loading /Users/selur/Desktop/test.mp4 using FFMS2
clip = core.ffms2.Source(source="/Users/selur/Desktop/test.mp4",format=vs.YUV420P8,alpha=False)
# making sure input color matrix is set as 470bg
clip = core.resize.Point(clip, matrix_in_s="470bg")
# making sure frame rate is set to 30000/1001
clip = core.std.AssumeFPS(clip, fpsnum=30000, fpsden=1001)
# Making sure input color range is set to TV (limited) range.
clip = core.std.SetFrameProp(clip=clip, prop="_ColorRange", intval=1)
# adjusting output color from: YUV420P8 to YUV420P10 for x264Model (i420)
clip = core.resize.Bicubic(clip=clip, format=vs.YUV420P10)
# Output
clip.set_output()
-> Seems like a bug in either the editor or FFMS2. I even explicitly set the color format etc.

Cu Selur
If you make that

Code:
# Loading /Users/selur/Desktop/test.mp4 using FFMS2
clip = core.ffms2.Source(source="/Users/selur/Desktop/test.mp4",format=vs.YUV420P8,alpha=False)
clip = core.std.BlankClip(clip)
does it still look blue? (It should be black.)
__________________
Buy me a "coffee" and/or hire me to write code!
jackoneill is offline   Reply With Quote
Old 3rd March 2018, 19:12   #43  |  Link
Selur
Registered User
 
Selur's Avatar
 
Join Date: Oct 2001
Location: Germany
Posts: 7,277
Will try tomorrow, don't own a mac anymore, used the one from my mom.
(unless halls reads this and can try it)
__________________
Hybrid here in the forum, homepage
Selur is offline   Reply With Quote
Old 3rd March 2018, 19:46   #44  |  Link
jackoneill
unsigned int
 
jackoneill's Avatar
 
Join Date: Oct 2012
Location: 🇪🇺
Posts: 760
Quote:
Originally Posted by jackoneill View Post
If you make that

Code:
# Loading /Users/selur/Desktop/test.mp4 using FFMS2
clip = core.ffms2.Source(source="/Users/selur/Desktop/test.mp4",format=vs.YUV420P8,alpha=False)
clip = core.std.BlankClip(clip)
does it still look blue? (It should be black.)
Better yet, try this:

Code:
# Loading /Users/selur/Desktop/test.mp4 using FFMS2
clip = core.ffms2.Source(source="/Users/selur/Desktop/test.mp4",format=vs.YUV420P8,alpha=False)

clip = core.std.CropRel(clip, left=128)
clip = core.std.AddBorders(clip, left=128)
Do you get 128 black pixels at the left border? Or still blue?

If black, then the problem is in ffms2. If still blue, then it could be the conversion to RGB (for display), or something in vsedit, or in Qt, or...
__________________
Buy me a "coffee" and/or hire me to write code!
jackoneill is offline   Reply With Quote
Old 4th March 2018, 14:04   #45  |  Link
Selur
Registered User
 
Selur's Avatar
 
Join Date: Oct 2001
Location: Germany
Posts: 7,277
Code:
import vapoursynth as vs
core = vs.get_core()
from vapoursynth import core
c = core.ffms2.Source(source='/Users/selur/Desktop/test.mp4')
c = core.std.BlankClip(c)
c.set_output())
gives a blue screen as does:
Code:
import vapoursynth as vs
core = vs.get_core()
from vapoursynth import core
c = core.ffms2.Source(source='/Users/selur/Desktop/公演后感言.mp4')
c = core.std.CropRel(c, left=128)
c = core.std.AddBorders(c, left=128)
c.set_output()
-> so the problem isn't with ffms2

Cu Selur
__________________
Hybrid here in the forum, homepage
Selur is offline   Reply With Quote
Old 4th March 2018, 15:42   #46  |  Link
jackoneill
unsigned int
 
jackoneill's Avatar
 
Join Date: Oct 2012
Location: 🇪🇺
Posts: 760
Quote:
Originally Posted by Selur View Post
Code:
import vapoursynth as vs
core = vs.get_core()
from vapoursynth import core
c = core.ffms2.Source(source='/Users/selur/Desktop/test.mp4')
c = core.std.BlankClip(c)
c.set_output())
gives a blue screen as does:
Code:
import vapoursynth as vs
core = vs.get_core()
from vapoursynth import core
c = core.ffms2.Source(source='/Users/selur/Desktop/公演后感言.mp4')
c = core.std.CropRel(c, left=128)
c = core.std.AddBorders(c, left=128)
c.set_output()
-> so the problem isn't with ffms2

Cu Selur
Do you have the same problem with Wobbly? It's another application that uses Qt to display video frames in much the same way as vsedit.
__________________
Buy me a "coffee" and/or hire me to write code!
jackoneill is offline   Reply With Quote
Old 4th March 2018, 15:46   #47  |  Link
Selur
Registered User
 
Selur's Avatar
 
Join Date: Oct 2001
Location: Germany
Posts: 7,277
Quote:
Do you have the same problem with Wobbly?
No clue. There's no download for mac os and I'm not starting to install Xcode or similar to compile it on my moms mac.
__________________
Hybrid here in the forum, homepage
Selur is offline   Reply With Quote
Old 5th March 2018, 15:32   #48  |  Link
l33tmeatwad
Registered User
 
l33tmeatwad's Avatar
 
Join Date: Jun 2007
Posts: 414
Quote:
Originally Posted by halls View Post
Thx for the update!


Is anyone to know how can i solve this issue:
Nice blue haze.....

Here is the script:

import vapoursynth as vs
core = vs.get_core()
from vapoursynth import core
c = core.ffms2.Source(source='/Volumes/MacOSX/Users/macosx/Desktop/1.mkv')
c.set_output()
The blue screen when previewing through VapourSynth Editor is an issue I have on all of my Macbook Pros (2010 and 2011), however others have said they do not have an issue. Changing the monitor profile will make fun things happen but aside from that, I have only seen the blue issue with previewing through VapourSynth Editor on certain Macbook models. VapourSynth R34 is the last revision that did not have this issue for me.

Quote:
Originally Posted by Selur View Post
@l33tmeatwad:
Since I couldn't find ffmsindex or d2vwitch I went through all the filters I could think of that are not part of Vapoursynth directly and listed them:
I'll add make sure to add ffmsindex and d2vwitch, as for the others, I'll add when I get the chance. I'm also going to just post my full instructions on how I compile everything for VapourSynth.framework so if anyone else wants to help contribute they can, I just need to clean up my nonsensical notes...

Last edited by l33tmeatwad; 5th March 2018 at 17:15.
l33tmeatwad is offline   Reply With Quote
Old 5th March 2018, 17:11   #49  |  Link
l33tmeatwad
Registered User
 
l33tmeatwad's Avatar
 
Join Date: Jun 2007
Posts: 414
Quote:
Originally Posted by jackoneill View Post
Do you have the same problem with Wobbly? It's another application that uses Qt to display video frames in much the same way as vsedit.
Yeah, Wobbly has the same issue.
l33tmeatwad is offline   Reply With Quote
Old 5th March 2018, 17:47   #50  |  Link
jackoneill
unsigned int
 
jackoneill's Avatar
 
Join Date: Oct 2012
Location: 🇪🇺
Posts: 760
Quote:
Originally Posted by l33tmeatwad View Post
Yeah, Wobbly has the same issue.
The splash image too, or only when you open a video?
__________________
Buy me a "coffee" and/or hire me to write code!
jackoneill is offline   Reply With Quote
Old 5th March 2018, 18:01   #51  |  Link
l33tmeatwad
Registered User
 
l33tmeatwad's Avatar
 
Join Date: Jun 2007
Posts: 414
Quote:
Originally Posted by jackoneill View Post
The splash image too, or only when you open a video?
Splash image is fine I think (color bars?), just loaded videos. I will say rolling back to VS r34 and videos load fine.

Last edited by l33tmeatwad; 5th March 2018 at 18:09.
l33tmeatwad is offline   Reply With Quote
Old 5th March 2018, 18:24   #52  |  Link
Selur
Registered User
 
Selur's Avatar
 
Join Date: Oct 2001
Location: Germany
Posts: 7,277
Quote:
I'm also going to just post my full instructions on how I compile everything for VapourSynth.framework so if anyone else wants to help contribute they can, I just need to clean up my nonsensical notes...
That would be nice.
__________________
Hybrid here in the forum, homepage
Selur is offline   Reply With Quote
Old 5th March 2018, 21:37   #53  |  Link
jackoneill
unsigned int
 
jackoneill's Avatar
 
Join Date: Oct 2012
Location: 🇪🇺
Posts: 760
I kind of doubt this patch fixes the problem, but try it anyway:
Code:
diff --git a/src/core/vsresize.cpp b/src/core/vsresize.cpp
index efd1a73..4f52c5b 100644
--- a/src/core/vsresize.cpp
+++ b/src/core/vsresize.cpp
@@ -493,7 +493,7 @@ public:
             allocate(vsformat, format.width, format.height, graph.get_input_buffering(), vsapi, core);
 
             if (vsformat->id == pfCompatBGR32)
-                m_p2p_func = vsp2p::packed_to_planar<vsp2p::packed_argb32_le>::unpack;
+                m_p2p_func = vsp2p::packed_to_planar<vsp2p::packed_argb32>::unpack;
             else if (vsformat->id == pfCompatYUY2)
                 m_p2p_func = vsp2p::packed_to_planar<vsp2p::packed_yuy2>::unpack;
 
@@ -533,7 +533,7 @@ public:
             allocate(vsformat, format.width, format.height, graph.get_output_buffering(), vsapi, core);
 
             if (vsformat->id == pfCompatBGR32)
-                m_p2p_func = vsp2p::planar_to_packed<vsp2p::packed_argb32_le, true>::pack;
+                m_p2p_func = vsp2p::planar_to_packed<vsp2p::packed_argb32, true>::pack;
             else if (vsformat->id == pfCompatYUY2)
                 m_p2p_func = vsp2p::planar_to_packed<vsp2p::packed_yuy2, true>::pack;
__________________
Buy me a "coffee" and/or hire me to write code!
jackoneill is offline   Reply With Quote
Old 5th March 2018, 22:49   #54  |  Link
l33tmeatwad
Registered User
 
l33tmeatwad's Avatar
 
Join Date: Jun 2007
Posts: 414
Quote:
Originally Posted by jackoneill View Post
I kind of doubt this patch fixes the problem, but try it anyway:
Code:
diff --git a/src/core/vsresize.cpp b/src/core/vsresize.cpp
index efd1a73..4f52c5b 100644
--- a/src/core/vsresize.cpp
+++ b/src/core/vsresize.cpp
@@ -493,7 +493,7 @@ public:
             allocate(vsformat, format.width, format.height, graph.get_input_buffering(), vsapi, core);
 
             if (vsformat->id == pfCompatBGR32)
-                m_p2p_func = vsp2p::packed_to_planar<vsp2p::packed_argb32_le>::unpack;
+                m_p2p_func = vsp2p::packed_to_planar<vsp2p::packed_argb32>::unpack;
             else if (vsformat->id == pfCompatYUY2)
                 m_p2p_func = vsp2p::packed_to_planar<vsp2p::packed_yuy2>::unpack;
 
@@ -533,7 +533,7 @@ public:
             allocate(vsformat, format.width, format.height, graph.get_output_buffering(), vsapi, core);
 
             if (vsformat->id == pfCompatBGR32)
-                m_p2p_func = vsp2p::planar_to_packed<vsp2p::packed_argb32_le, true>::pack;
+                m_p2p_func = vsp2p::planar_to_packed<vsp2p::packed_argb32, true>::pack;
             else if (vsformat->id == pfCompatYUY2)
                 m_p2p_func = vsp2p::planar_to_packed<vsp2p::packed_yuy2, true>::pack;
That fixed the issue, no more blue!
l33tmeatwad is offline   Reply With Quote
Old 6th March 2018, 05:27   #55  |  Link
Selur
Registered User
 
Selur's Avatar
 
Join Date: Oct 2001
Location: Germany
Posts: 7,277
Nice! Looking forward to the next release.
__________________
Hybrid here in the forum, homepage
Selur is offline   Reply With Quote
Old 6th March 2018, 10:05   #56  |  Link
jackoneill
unsigned int
 
jackoneill's Avatar
 
Join Date: Oct 2012
Location: 🇪🇺
Posts: 760
Quote:
Originally Posted by l33tmeatwad View Post
That fixed the issue, no more blue!
So this is a PowerPC, then?
__________________
Buy me a "coffee" and/or hire me to write code!
jackoneill is offline   Reply With Quote
Old 6th March 2018, 15:15   #57  |  Link
l33tmeatwad
Registered User
 
l33tmeatwad's Avatar
 
Join Date: Jun 2007
Posts: 414
Quote:
Originally Posted by jackoneill View Post
So this is a PowerPC, then?
Nope, Intel.
l33tmeatwad is offline   Reply With Quote
Old 6th March 2018, 15:49   #58  |  Link
jackoneill
unsigned int
 
jackoneill's Avatar
 
Join Date: Oct 2012
Location: 🇪🇺
Posts: 760
Quote:
Originally Posted by l33tmeatwad View Post
Nope, Intel.
Okay then. What version of Qt do you have?

Edit: nevermind. Apparently it's a VapourSynth bug, not Qt.
__________________
Buy me a "coffee" and/or hire me to write code!

Last edited by jackoneill; 6th March 2018 at 18:04.
jackoneill is offline   Reply With Quote
Old 6th March 2018, 15:55   #59  |  Link
l33tmeatwad
Registered User
 
l33tmeatwad's Avatar
 
Join Date: Jun 2007
Posts: 414
Quote:
Originally Posted by jackoneill View Post
Okay then. What version of Qt do you have?
I have and use Qt 5.9 for my personal projects, but for VapourSynth Editor I use 5.6 because if I use anything newer the output is a mostly black with blocky distortion, however 5.6 will properly compile it. I used 5.10 from brew on a fresh system to compile Wobbly.

Last edited by l33tmeatwad; 6th March 2018 at 15:59.
l33tmeatwad is offline   Reply With Quote
Old 6th March 2018, 17:14   #60  |  Link
jackoneill
unsigned int
 
jackoneill's Avatar
 
Join Date: Oct 2012
Location: 🇪🇺
Posts: 760
Please test one more patch, but without applying the previous one:
Code:
diff --git a/src/common/p2p.h b/src/common/p2p.h
index 60f50e9..0895b93 100644
--- a/src/common/p2p.h
+++ b/src/common/p2p.h
@@ -26,6 +26,10 @@
 #include <climits>
 #include <type_traits>
 
+#ifdef _WIN32
+  #include <stdlib.h> // _byteswap_x
+#endif
+
 #ifdef P2P_USER_NAMESPACE
   #define P2P_NAMESPACE P2P_USER_NAMESPACE
 #else
@@ -34,12 +38,10 @@
 
 #ifdef _WIN32
   #define P2P_LITTLE_ENDIAN
-  #include <stdlib.h>
-#else
-  #include <sys/param.h>
-  #if __BYTE_ORDER == __BIG_ENDIAN
+#elif defined(__BYTE_ORDER__)
+  #if __BYTE_ORDER__ == __ORDER_BIG_ENDIAN__
     #define P2P_BIG_ENDIAN
-  #elif __BYTE_ORDER == __LITTLE_ENDIAN
+  #elif __BYTE_ORDER__ == __ORDER_LITTLE_ENDIAN__
     #define P2P_LITTLE_ENDIAN
   #endif
 #endif
__________________
Buy me a "coffee" and/or hire me to write code!
jackoneill is offline   Reply With Quote
Reply


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 05:50.


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