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 > Avisynth Development

Closed Thread
 
Thread Tools Search this Thread Display Modes
Old 17th December 2016, 17:46   #2721  |  Link
pinterf
Registered User
 
Join Date: Jan 2014
Posts: 1,853
Quote:
Originally Posted by Myrsloik View Post
Why u use offset float 4 uv? Whyyyyyy?
To tell the truth I didnt know. I had no experience or prejudice about these expert formats. That's why I mentioned 'now' because you guys who have the knowledge, can propose the right way, it's not too late.
pinterf is offline  
Old 17th December 2016, 18:29   #2722  |  Link
jpsdr
Registered User
 
Join Date: Oct 2002
Location: France
Posts: 1,901
@feisty2
I'm doing the 16bits for now, i'll see for the floats latter.
@pinterf
I don't understand. I thought you said all the planes in floats were 0.0-1.0, so the U/V planes are also the same, or have i missed something (because of some english part i may have misunderstood) ?
jpsdr is offline  
Old 17th December 2016, 19:06   #2723  |  Link
pinterf
Registered User
 
Join Date: Jan 2014
Posts: 1,853
Yes. All planes are 0-1.0 at the moment. But it seems that this is unusual.
pinterf is offline  
Old 18th December 2016, 01:13   #2724  |  Link
Myrsloik
Professional Code Monkey
 
Myrsloik's Avatar
 
Join Date: Jun 2003
Location: Ikea Chair
Posts: 2,293
Quote:
Originally Posted by pinterf View Post
Yes. All planes are 0-1.0 at the moment. But it seems that this is unusual.
Use -0.5 to 0.5 for UV and it'll match VS. Will make compatibility so much easier...
__________________
VapourSynth - proving that scripting languages and video processing isn't dead yet
Myrsloik is offline  
Old 18th December 2016, 13:00   #2725  |  Link
jpsdr
Registered User
 
Join Date: Oct 2002
Location: France
Posts: 1,901
@feisty2
I have a question, just to ask if it's normal :
In evalFunc_0 you use prescreener >=2 only if pixelsize=1, wich is normal, but the way the tests are made, if you ask prescreener=2 with pixelsize>1, you fall in "no prescreener". Isn't better to go back to "original" instead ? I mean, somehow you have asked for a prescreener. But in that case, the constructor/Init would have to be adjusted according to this.
jpsdr is offline  
Old 19th December 2016, 08:33   #2726  |  Link
feisty2
I'm Siri
 
feisty2's Avatar
 
Join Date: Oct 2012
Location: Providence, RI
Posts: 2,538
Quote:
Originally Posted by jpsdr View Post
@feisty2
I have a question, just to ask if it's normal :
In evalFunc_0 you use prescreener >=2 only if pixelsize=1, wich is normal, but the way the tests are made, if you ask prescreener=2 with pixelsize>1, you fall in "no prescreener". Isn't better to go back to "original" instead ? I mean, somehow you have asked for a prescreener. But in that case, the constructor/Init would have to be adjusted according to this.
didn't quite get what you were saying... (not sure what you meant by "go back to original")
anyways, pscrn could only be 0 or 1 for high bitdepth samples (as new prescreeners were trained for byte inputs). 2 is illegal for them.
__________________
If I got new ideas, will post here: https://github.com/IFeelBloated
feisty2 is offline  
Old 19th December 2016, 09:35   #2727  |  Link
pinterf
Registered User
 
Join Date: Jan 2014
Posts: 1,853
Quote:
Originally Posted by real.finder View Post
I note that GScriptClip is incompatible with avs+ mt, with mode 2 not work at all and with mode 3 gave random scriptcilp errors
This was not forgotten, but I cannot help with it right now, could you post a test script and a hint what is special in GScriptClip (I have read some info about it but it is still not clear for me, never used)
pinterf is offline  
Old 19th December 2016, 10:15   #2728  |  Link
jpsdr
Registered User
 
Join Date: Oct 2002
Location: France
Posts: 1,901
@pinterf
Quote:
Originally Posted by Myrsloik View Post
Use -0.5 to 0.5 for UV and it'll match VS. Will make compatibility so much easier...
Let me know what you think you'll be doing in final, and if you're doing -0.5/+0.5 for UV, confirm that a PlaneToY will still produce 0.0/1.0.

@feisty2
Ok.
I mean, actualy in the code, from what i've understood, if you've set a value of 2 for the prescrener with high bitdepth, it switches to 0. Maybe it may switche to 1. Just a little thought.

Last edited by jpsdr; 19th December 2016 at 10:19.
jpsdr is offline  
Old 19th December 2016, 10:34   #2729  |  Link
feisty2
I'm Siri
 
feisty2's Avatar
 
Join Date: Oct 2012
Location: Providence, RI
Posts: 2,538
Quote:
Originally Posted by jpsdr View Post
@feisty2
Ok.
I mean, actualy in the code, from what i've understood, if you've set a value of 2 for the prescrener with high bitdepth, it switches to 0. Maybe it may switche to 1. Just a little thought.
it should pop out an error message, not silently switch to another mode without notifying the user
__________________
If I got new ideas, will post here: https://github.com/IFeelBloated
feisty2 is offline  
Old 19th December 2016, 11:25   #2730  |  Link
pinterf
Registered User
 
Join Date: Jan 2014
Posts: 1,853
Quote:
Originally Posted by jpsdr View Post
@pinterf

Let me know what you think you'll be doing in final, and if you're doing -0.5/+0.5 for UV, confirm that a PlaneToY will still produce 0.0/1.0.
Good catch, I was thinking about the same theoretical problem. I wonder if VS has special treatments for this in ShufflePlanes, but I don't think so.
pinterf is offline  
Old 19th December 2016, 11:58   #2731  |  Link
Myrsloik
Professional Code Monkey
 
Myrsloik's Avatar
 
Join Date: Jun 2003
Location: Ikea Chair
Posts: 2,293
Quote:
Originally Posted by pinterf View Post
Good catch, I was thinking about the same theoretical problem. I wonder if VS has special treatments for this in ShufflePlanes, but I don't think so.
Any float value is always valid (except nan and inf) so no special handling at all. If the user wants weird luma they can have it.

There's also no guarantee that the luma channel stays in the 0-1 range so it doesn't matter.
__________________
VapourSynth - proving that scripting languages and video processing isn't dead yet
Myrsloik is offline  
Old 19th December 2016, 12:22   #2732  |  Link
real.finder
Registered User
 
Join Date: Jan 2012
Location: Mesopotamia
Posts: 2,164
Quote:
Originally Posted by pinterf View Post
This was not forgotten, but I cannot help with it right now, could you post a test script and a hint what is special in GScriptClip (I have read some info about it but it is still not clear for me, never used)
Code:
ColorBars(width=640, height=480, pixel_type="yv12")
srestore
Prefetch(6)
it used in Srestore and others
__________________
See My Avisynth Stuff
real.finder is offline  
Old 19th December 2016, 13:24   #2733  |  Link
jpsdr
Registered User
 
Join Date: Oct 2002
Location: France
Posts: 1,901
Well, let me know the final result of float decision, it will decide if i work or not to use float format in nnedi3.
The luma (or grey) plane in nnedi3 is clipped to 0.0-1.0 (and chroma planes are clipped to -0.5/+0.5). So, if you split an YUV format in 3 Y,U,V planes, and feed them separately in nnedi3, and the splitted plane U,V are in -0.5/+0.5 instead of 0.0-1.0 usual grey plane, your result will be messed up. So, if a splitted/extracted planar chroma plane is not shifted to match an usual Y/grey plane, you can't properly use nnedi3 in float format without adding a parameter to specify the the range of the float of the "grey" planar.
For now, even with the code of vapoursynth, i'm still unable to make it work with 16 bits....
jpsdr is offline  
Old 19th December 2016, 13:35   #2734  |  Link
feisty2
I'm Siri
 
feisty2's Avatar
 
Join Date: Oct 2012
Location: Providence, RI
Posts: 2,538
Quote:
Originally Posted by jpsdr View Post
Well, let me know the final result of float decision, it will decide if i work or not to use float format in nnedi3.
The luma (or grey) plane in nnedi3 is clipped to 0.0-1.0 (and chroma planes are clipped to -0.5/+0.5). So, if you split an YUV format in 3 Y,U,V planes, and feed them separately in nnedi3, and the splitted plane U,V are in -0.5/+0.5 instead of 0.0-1.0 usual grey plane, your result will be messed up. So, if a splitted/extracted planar chroma plane is not shifted to match an usual Y/grey plane, you can't properly use nnedi3 in float format without adding a parameter to specify the the range of the float of the "grey" planar.
For now, even with the code of vapoursynth, i'm still unable to make it work with 16 bits....
NO!!!
WHYYYYYYYYYYYY DID YOU DO THAT???
overflow is practically nonexistent to floating points, the MAIN reason to use floating point samples is to avoid clipping to have a more mathematically correct result.

CLIPPING IS TOXIC
__________________
If I got new ideas, will post here: https://github.com/IFeelBloated

Last edited by feisty2; 19th December 2016 at 13:38.
feisty2 is offline  
Old 19th December 2016, 14:18   #2735  |  Link
pinterf
Registered User
 
Join Date: Jan 2014
Posts: 1,853
Quote:
Originally Posted by real.finder View Post
Code:
ColorBars(width=640, height=480, pixel_type="yv12")
srestore
Prefetch(6)
it used in Srestore and others
Could you try this one?
GRunT-1.0.2 (avisynth+ and 2.6, x86 and x64)
I suppose I only made it self register as a NICE_FILTER for Avisynth+.
That means that it doesn't run under avs 2.5x.
And if I had work with it, I made a 64bit version also.
pinterf is offline  
Old 19th December 2016, 14:32   #2736  |  Link
jpsdr
Registered User
 
Join Date: Oct 2002
Location: France
Posts: 1,901
Quote:
Originally Posted by feisty2 View Post
NO!!!
WHYYYYYYYYYYYY DID YOU DO THAT???
Heu... Sorry, i've done nothing yet, take a look at your nnedi3.cpp lines 338, 641.
Did i misunderstood something ?
jpsdr is offline  
Old 19th December 2016, 14:39   #2737  |  Link
feisty2
I'm Siri
 
feisty2's Avatar
 
Join Date: Oct 2012
Location: Providence, RI
Posts: 2,538
Quote:
Originally Posted by jpsdr View Post
Heu... Sorry, i've done nothing yet, take a look at your nnedi3.cpp lines 338, 641.
Did i misunderstood something ?
https://github.com/dubhater/vapoursy...src/nnedi3.cpp
correct link
__________________
If I got new ideas, will post here: https://github.com/IFeelBloated
feisty2 is offline  
Old 19th December 2016, 14:46   #2738  |  Link
jpsdr
Registered User
 
Join Date: Oct 2002
Location: France
Posts: 1,901
Ok, thanks. But i'm still struggling with integer for now...

Edit :
If you have any idea/comment about the potentiel issue i've posted in the nnedi3 thread.
jpsdr is offline  
Old 19th December 2016, 23:13   #2739  |  Link
real.finder
Registered User
 
Join Date: Jan 2012
Location: Mesopotamia
Posts: 2,164
Quote:
Originally Posted by pinterf View Post
Could you try this one?
GRunT-1.0.2 (avisynth+ and 2.6, x86 and x64)
I suppose I only made it self register as a NICE_FILTER for Avisynth+.
That means that it doesn't run under avs 2.5x.
And if I had work with it, I made a 64bit version also.
it show random things in the top of frame
__________________
See My Avisynth Stuff

Last edited by real.finder; 19th December 2016 at 23:16.
real.finder is offline  
Old 21st December 2016, 20:01   #2740  |  Link
pinterf
Registered User
 
Join Date: Jan 2014
Posts: 1,853
Yes, there is garbage. I was blind or I don't know. But it seems to be a very hard problem, at least haven't seen those avisynth internal parts that I have to debug now. First I'm struggling with the source of those hieroglyphs, which show: "ERROR: I don't know what 'current_frame' means." (Put this line at the beginning of the script: SetLogParams("log.txt", LOG_DEBUG))
And why it appears: ScriptClip errors (exception text with source module and line number) are overlayed on the current frame.
For some reason when formatting the error message, the C++ variadic parameter list (va_list) becomes corrupt between calls or after using vsnprintf. But only in this case. Now I'm reinstalling my VS2015.
But that is only the problem of the weird error message rendering. The real problem is the scope of variables, this plugin sets global paramers run-time, and this is somehow different in AVS+ than is classic AVS.
pinterf is offline  
Closed Thread

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 14:41.


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