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

Reply
 
Thread Tools Search this Thread Display Modes
Old 8th July 2016, 22:00   #21  |  Link
Wilbert
Moderator
 
Join Date: Nov 2001
Location: Netherlands
Posts: 6,364
I can't replicate your issue. If i open the script in Virtualdub (with either 2.6.0, 2.6.1a1 (AviSynth_20160517_VC2008Exp SSE2.exe) or latest csv) i get no errors.

I got an error though if i convert the solution to msvc2010, compile a debug build and run the script
Code:
ColorBars(width=720, height=480, pixel_type="RGB32")
ConvertToY8()  # crashes on this line
ConvertToRGB32()
If i click on negeren (= ignore) the script loads fine. If i compile a release build the script runs also fine
Attached Images
 

Last edited by Wilbert; 8th July 2016 at 22:09.
Wilbert is offline   Reply With Quote
Old 8th July 2016, 22:42   #22  |  Link
Groucho2004
 
Join Date: Mar 2006
Location: Barcelona
Posts: 5,034
Quote:
Originally Posted by real.finder View Post
Code:
ColorBars(width=720, height=480, pixel_type="RGB32")
ConvertToY8()
orig = last
Blur(1)
compare(last,orig)
This is what I get when running that script with AVSMeter:
Code:
AVSMeter 2.3.0 (x86) - Copyright (c) 2012-2016 Groucho2004
AviSynth 2.61, build:May 17 2016 [16:06:18] VC2008Exp (2.6.1.0)

Exception 0xC0000005 [STATUS_ACCESS_VIOLATION]
Module:   D:\WINNT\system32\avisynth.dll
Address:  0x00ABFC0B
This also happens with 2.6.0. The script runs fine with AVS+.
__________________
Groucho's Avisynth Stuff

Last edited by Groucho2004; 9th July 2016 at 00:43.
Groucho2004 is offline   Reply With Quote
Old 9th July 2016, 02:03   #23  |  Link
sqrt(9801)
Registered User
 
Join Date: Jun 2013
Posts: 24
Quote:
Originally Posted by real.finder View Post
Code:
ColorBars(width=720, height=480, pixel_type="RGB32")
ConvertToY8()
orig = last
Blur(1)
compare(last,orig)
Getting an access violation as well, on 2.6.1 and 2.6.0.

It looks like using Compare() on two Y8 clips causes it, unless you specify channels="Y".
sqrt(9801) is offline   Reply With Quote
Old 9th July 2016, 09:29   #24  |  Link
StainlessS
HeartlessS Usurer
 
StainlessS's Avatar
 
Join Date: Dec 2009
Location: Over the rainbow
Posts: 10,980
What sqrt(9801) said.

Maybe need special case here

text-overlay.cpp, line 1379 [ Compare::Compare() ]
Code:
  if (channels[0] == 0) {
    if (vi.IsRGB())
      channels = "RGB";
    else if (vi.IsYUV())
      channels = "YUV";
    else env->ThrowError("Compare: Clips have unknown colorspace. RGB and YUV supported.");
  }
EDIT: Could probably also add some kind of channel legality check, below also has access violation
Code:
ColorBars(width=720, height=480, pixel_type="RGB32")
ConvertToY8()
compare(last,Last,Channels="u")
return ConvertToRGB24
__________________
I sometimes post sober.
StainlessS@MediaFire ::: AND/OR ::: StainlessS@SendSpace

"Some infinities are bigger than other infinities", but how many of them are infinitely bigger ???

Last edited by StainlessS; 9th July 2016 at 16:11.
StainlessS is offline   Reply With Quote
Old 11th July 2016, 21:56   #25  |  Link
Wilbert
Moderator
 
Join Date: Nov 2001
Location: Netherlands
Posts: 6,364
Code:
  if (channels[0] == 0) {
    if (vi.IsRGB())
      channels = "RGB";
    else if (vi.IsY8())
      channels = "Y";
    else if (vi.IsYUV())
      channels = "YUV";
    else env->ThrowError("Compare: Clips have unknown colorspace. RGB and YUV supported.");
  }

  if ((vi.IsY8() || vi2.IsY8()) && !(channels[0] == 'Y') && !(channels[0] == 'y')) {
    env->ThrowError("Compare: One of the clips is Y8. In this case only channels = \"Y\" is supported.");
  }
fixes both issues. Will be fixed in next release.

Last edited by Wilbert; 11th July 2016 at 22:20.
Wilbert is offline   Reply With Quote
Old 23rd July 2016, 12:15   #26  |  Link
bcn_246
Registered User
 
bcn_246's Avatar
 
Join Date: Nov 2005
Location: UK
Posts: 117
Any word on an MT build of v2.6.1?
bcn_246 is offline   Reply With Quote
Old 23rd July 2016, 16:51   #27  |  Link
jackoneill
unsigned int
 
jackoneill's Avatar
 
Join Date: Oct 2012
Location: 🇪🇺
Posts: 760
Quote:
Originally Posted by bcn_246 View Post
Any word on an MT build of v2.6.1?
http://forum.doom9.org/showthread.php?t=168856
http://forum.doom9.org/showthread.php?t=165771
__________________
Buy me a "coffee" and/or hire me to write code!
jackoneill is offline   Reply With Quote
Old 30th July 2016, 16:04   #28  |  Link
bcn_246
Registered User
 
bcn_246's Avatar
 
Join Date: Nov 2005
Location: UK
Posts: 117
I chose to stick with StaxRip v1.2.2.0 which doesn't play nice with AviSynth+ (newer x64 builds were to buggy). A big effort has been made to port common filters to as x64 a lot of (especially older more obscure filters) are still x86 only.

I do some transfers that relay on some pretty obscure filters which it could be some time before a x64/VS port.

The speed benefit of x64 is undeniable for simple rips that use just common De-block/De-interlace/Crop/Resize, but if my processing chain looks like you will see why I have stuck with AviSynth v2.6 MT

Code:
Source decode -> AviSynth x86 filters -> Lossless AVI render -> Load AVI -> AviSynth x64 filter -> x264/x265 encode
rather than ...
Code:
Source decode -> AviSynth x86 filters-> x264/x265 encode
Peace
bcn_246 is offline   Reply With Quote
Old 30th July 2016, 17:51   #29  |  Link
jackoneill
unsigned int
 
jackoneill's Avatar
 
Join Date: Oct 2012
Location: 🇪🇺
Posts: 760
Quote:
Originally Posted by bcn_246 View Post
I chose to stick with StaxRip v1.2.2.0 which doesn't play nice with AviSynth+ (newer x64 builds were to buggy). A big effort has been made to port common filters to as x64 a lot of (especially older more obscure filters) are still x86 only.

I do some transfers that relay on some pretty obscure filters which it could be some time before a x64/VS port.

The speed benefit of x64 is undeniable for simple rips that use just common De-block/De-interlace/Crop/Resize, but if my processing chain looks like you will see why I have stuck with AviSynth v2.6 MT

Code:
Source decode -> AviSynth x86 filters -> Lossless AVI render -> Load AVI -> AviSynth x64 filter -> x264/x265 encode
rather than ...
Code:
Source decode -> AviSynth x86 filters-> x264/x265 encode
Peace
Would you list those obscure filters, please? It may be useful to someone looking to expand VapourSynth's filter collection.
__________________
Buy me a "coffee" and/or hire me to write code!
jackoneill is offline   Reply With Quote
Old 5th September 2016, 06:57   #30  |  Link
StainlessS
HeartlessS Usurer
 
StainlessS's Avatar
 
Join Date: Dec 2009
Location: Over the rainbow
Posts: 10,980
:SOLVED:
No idea where I should post this, dont know if Avisynth, Grunt, VSFilter problem, or something daft that I've done.

Problem exhibited in AVS v2.6 (Standard and ICL) and also v2.58.

Changing pretty much anything below will remove the "Avisynth: Unknown Exception".

Code:
Function TestXXX(clip c,int q) {Return c}

Function FindXXX(clip c) {
    q=0
    return c.ScriptClip("TestXXX(q)",args="q")  # args, req Grunt()
}

Colorbars
#ConvertToRGB24
TextSub("Cabaret.srt")
FindXXX()
Also tried with different subtitle file.

EDIT: Can anybody else confirm/reproduce similar problem.

EDIT: Same with empty plugins, except for VSFilter[v2.39.5.1 - 980 KB (1,003,520 bytes)] and Grunt.
EDIT: Same avs v2.61 (AviSynth_20160517_VC2008Exp SSE2.exe).

EDIT: Avisynth+ r2772 MT i386, "An error occurred while playing the file. (Error=80004005)"
Seems to be general unspecified error.
Quote:
Troubleshooting Code Error 80004005 - Unspecified Error

Think of error 80004005 as meaning the script could not access your data. The most likely reason is a permissions related problem. Your best chance of resolving this problem is to study carefully any associated message, for example, 'File already in use', or 'Logon Failed'.
Opening in VirtualDubFilterMod, "CAVIStreamSynth: unhandled C++ exception".
EDIT: And MPC-HC reports this
Quote:
kernel32!RaiseException+0x53
WARNING: Following frames may be wrong.
vcruntime140!CxxThrowException+0x65
avisynth+0x33aac
vsfilter!VirtualdubFilterModuleDeinit+0xe70
avisynth+0x19d08
Maybe VSFilter problem (disappears if ConvertToRGB24 [or almost any other mod]).

EDIT: XP32SP3.

EDIT: Also tried VSFilter v2.39.5.2 with same result.

Went back to old version VSFilter v1.0.1.1, and no more problem (dated 20050301), gonna stay with that one [From WarpEnterprises].

:SOLVED:
__________________
I sometimes post sober.
StainlessS@MediaFire ::: AND/OR ::: StainlessS@SendSpace

"Some infinities are bigger than other infinities", but how many of them are infinitely bigger ???

Last edited by StainlessS; 5th September 2016 at 21:09.
StainlessS is offline   Reply With Quote
Old 18th October 2016, 12:36   #31  |  Link
StainlessS
HeartlessS Usurer
 
StainlessS's Avatar
 
Join Date: Dec 2009
Location: Over the rainbow
Posts: 10,980
Is This new to v2.6 ? (I know I could install v2.58 and check but I'm lazy)

Code:
x=2  # False
#x=3 # True
#x=4 # True
#x=5 # True
#x=6 # False
Z=(3 <= x <= 5)   # I would usually use something like (3 <= x && x <= 5)
MessageClip(String(z))
Thought I'de found a bug in my script Assert() but seems to work just fine.
Is there anything to be aware of when using as above ? (I've never noticed any similar usage before).

EDIT: This also works
Code:
x=2.0  # False
#x=3.0 # True
#x=4.0 # True
#x=5.0 # True
#x=6.0 # False
Z=(3.0 <= x <= 5.0)
MessageClip(String(z))
__________________
I sometimes post sober.
StainlessS@MediaFire ::: AND/OR ::: StainlessS@SendSpace

"Some infinities are bigger than other infinities", but how many of them are infinitely bigger ???

Last edited by StainlessS; 18th October 2016 at 15:29.
StainlessS is offline   Reply With Quote
Old 18th October 2016, 15:33   #32  |  Link
Groucho2004
 
Join Date: Mar 2006
Location: Barcelona
Posts: 5,034
Quote:
Originally Posted by StainlessS View Post
Is This new to v2.6 ? (I know I could install v2.58 and check but I'm lazy)

Code:
x=2  # False
#x=3 # True
#x=4 # True
#x=5 # True
#x=6 # False
Z=(3 <= x <= 5)   # I would usually use something like (3 <= x && x <= 5)
MessageClip(String(z))
Thought I'de found a bug in my script Assert() but seems to work just fine.
Is there anything to be aware of when using as above ? (I've never noticed any similar usage before).

EDIT: This also works
Code:
x=2.0  # False
#x=3.0 # True
#x=4.0 # True
#x=5.0 # True
#x=6.0 # False
Z=(3.0 <= x <= 5.0)
MessageClip(String(z))
These scripts work fine in 2.5.8. I recommend using the Avisynth switcher, makes it a lot easier to compare features.
__________________
Groucho's Avisynth Stuff
Groucho2004 is offline   Reply With Quote
Old 18th October 2016, 15:48   #33  |  Link
StainlessS
HeartlessS Usurer
 
StainlessS's Avatar
 
Join Date: Dec 2009
Location: Over the rainbow
Posts: 10,980
Thanx G2K4, but is it intended to work like that, or just a happy accident.
Dont see nuttin in docs about it.

By the way, in next ICL AVS 2.6, can you please ensure VersionString includes the comma separator after version number
"AviSynth 2.60, build:Mar 31 2015 [16:38:54]"
I use it to strip off just the version in Builtin AVS functions script, without build number [EDIT: Date] etc.
Maybe something like "AviSynth 2.60, (ICL) build:Mar 31 2015 [16:38:54]", I dont recall exactly how it was formatted.

Cheers

EDIT:
or
"AviSynth (ICL) 2.60, build:Mar 31 2015 [16:38:54]", to include ICL in stripped out version.
EDIT: I think same script works fine with AVS+. (I was gonna fix for ICL anyway)
EDIT: I strip off the build etc because I use it to produce a filename without ':' in it (guess I could scan/replace all non valid filename chars).
__________________
I sometimes post sober.
StainlessS@MediaFire ::: AND/OR ::: StainlessS@SendSpace

"Some infinities are bigger than other infinities", but how many of them are infinitely bigger ???

Last edited by StainlessS; 18th October 2016 at 15:58.
StainlessS is offline   Reply With Quote
Old 18th October 2016, 15:59   #34  |  Link
Groucho2004
 
Join Date: Mar 2006
Location: Barcelona
Posts: 5,034
Quote:
Originally Posted by StainlessS View Post
Thanx G2K4, but is it intended to work like that, or just a happy accident.
Who knows. You'll have to look at the script parser code to find out.

Quote:
Originally Posted by StainlessS View Post
By the way, in next ICL AVS 2.6, can you please ensure VersionString includes the comma separator after version number
"AviSynth 2.60, build:Mar 31 2015 [16:38:54]"
I use it to strip off just the version in Builtin AVS functions script, without build number [EDIT: Date] etc.
Maybe something like "AviSynth 2.60, (ICL) build:Mar 31 2015 [16:38:54]", I dont recall exactly how it was formatted.

Cheers

EDIT:
or
"AviSynth (ICL) 2.60, build:Mar 31 2015 [16:38:54]", to include ICL in stripped out version.
I doubt that I'll ever make a new one (based on 2.6.1) but I can update the current build.
__________________
Groucho's Avisynth Stuff

Last edited by Groucho2004; 18th October 2016 at 16:12.
Groucho2004 is offline   Reply With Quote
Old 18th October 2016, 16:04   #35  |  Link
StainlessS
HeartlessS Usurer
 
StainlessS's Avatar
 
Join Date: Dec 2009
Location: Over the rainbow
Posts: 10,980
Quote:
but I can update the current build.
No please dont go to the trouble, Ill find a way around it, thanx anyway.
__________________
I sometimes post sober.
StainlessS@MediaFire ::: AND/OR ::: StainlessS@SendSpace

"Some infinities are bigger than other infinities", but how many of them are infinitely bigger ???
StainlessS is offline   Reply With Quote
Old 19th October 2016, 00:40   #36  |  Link
Gavino
Avisynth language lover
 
Join Date: Dec 2007
Location: Spain
Posts: 3,431
Quote:
Originally Posted by StainlessS View Post
is it intended to work like that, or just a happy accident.
As far as I know, it's deliberate and has always worked like that.
The parser accepts a chain of comparisons (see function ParseComparison() in scriptparser.cpp).
You can even do things like:
Code:
a < y > b == c # ... and more conditions if you want
which is interpreted as:
Code:
(a < y) && (y > b) && (b == c) # ...
__________________
GScript and GRunT - complex Avisynth scripting made easier
Gavino is offline   Reply With Quote
Old 19th October 2016, 01:32   #37  |  Link
StainlessS
HeartlessS Usurer
 
StainlessS's Avatar
 
Join Date: Dec 2009
Location: Over the rainbow
Posts: 10,980
Quote:
which is interpreted as:
WOW, I is totally GobSmacked, that should not go un-noted in docs. (beautifully succinct)

Quote:
see function ParseComparison() in scriptparser.cpp
Hmm, I am reasonably capable of parsing text/numbers, but that may I think be a bit beyond me (although I have not looked at it).

Just tried this too
Code:
x="a"  # False
#x="b" # True
#x="C" # True
#x="d" # True
#x="E" # False
Z=("b" <= x <= "D")
MessageClip(String(z))
Still works OK (case insignificant).

Cheers big G, or should I say (to use your full name), Albus Percival Wulfric Brian Gavino.
__________________
I sometimes post sober.
StainlessS@MediaFire ::: AND/OR ::: StainlessS@SendSpace

"Some infinities are bigger than other infinities", but how many of them are infinitely bigger ???

Last edited by StainlessS; 19th October 2016 at 04:49.
StainlessS is offline   Reply With Quote
Old 9th January 2017, 02:40   #38  |  Link
StainlessS
HeartlessS Usurer
 
StainlessS's Avatar
 
Join Date: Dec 2009
Location: Over the rainbow
Posts: 10,980
We seem to have a little bit of inconsistency between RGB24 and RGB32 conversions from YV12 in Avisynth 2.6 and v2.61. (v2.5 and Avs+ immune).

Code:
Avisource("F:\v\StarWars.avi").Trim(10000,-1)
A=ConvertToRGB24.ShowBlue(pixel_type="YV12")
B=ConvertToRGB32.ShowBlue(pixel_type="YV12")
Subtract(A,B)
current_frame=0
return subtitle(String(averageLuma,"%f"))
On above particular frame of movie shows 126.001534 for ShowBlue Channel, other channels always 126.0.
Did not try other Planar, YUY2 -> RGB seems ok.

EDIT: YV24 also affected, no other planar tried.
EDIT: Problem resides down the left edge of frame, ie first byte blue channel (RGB32 I think).

EDIT: Show Difference (Amplified)
Code:
Function ClipDelta(clip clip1,clip clip2,bool "amp",bool "show") {
    amp=Default(amp,false)
    show=Default(show,false)
    c2=clip1.levels(128-32,1.0,128+32,128-32,128+32).greyscale()
    c1=clip1.subtract(clip2)
    c1=(amp)?c1.levels(127,1.0,129,0,255):c1
    return (show)?c1.Merge(c2):c1
}

Avisource("F:\v\StarWars.avi").Trim(10000,-1)
A=ConvertToRGB24.ShowBlue(pixel_type="YV12")
B=ConvertToRGB32.ShowBlue(pixel_type="YV12")
return ClipDelta(A,B,True)
__________________
I sometimes post sober.
StainlessS@MediaFire ::: AND/OR ::: StainlessS@SendSpace

"Some infinities are bigger than other infinities", but how many of them are infinitely bigger ???

Last edited by StainlessS; 9th January 2017 at 04:10.
StainlessS is offline   Reply With Quote
Old 10th January 2017, 18:58   #39  |  Link
FranceBB
Broadcast Encoder
 
FranceBB's Avatar
 
Join Date: Nov 2013
Location: Royal Borough of Kensington & Chelsea, UK
Posts: 2,883
Does compiling avisynth itself with anything greater than SSE2 bring any speed benefits?
FranceBB is offline   Reply With Quote
Old 11th January 2017, 22:35   #40  |  Link
StainlessS
HeartlessS Usurer
 
StainlessS's Avatar
 
Join Date: Dec 2009
Location: Over the rainbow
Posts: 10,980
Can someone at least acknowledge post #38, not sure if [Edit: above] post obscured it. Thanx.

EDIT: v2.6 anv2.61 are producing BAD (Blue channel) pixels down LHS of frame (RGB32, I think, could be wrong there).

[I'm guessin that its sumimck like < instead of <= that is the prob).
__________________
I sometimes post sober.
StainlessS@MediaFire ::: AND/OR ::: StainlessS@SendSpace

"Some infinities are bigger than other infinities", but how many of them are infinitely bigger ???

Last edited by StainlessS; 11th January 2017 at 22:53.
StainlessS is offline   Reply With Quote
Reply

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 09:08.


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