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. |
2nd February 2021, 00:06 | #61 | Link |
Registered User
Join Date: Apr 2013
Posts: 346
|
Yet another request:
Can the text lines showing up as “No Combing” be removed? They don’t indicate moire/combing, but add to the number of frames. When I try to do it, it throws off syntax errors. I guess there is some conditional intertwining and some of the symbols, e.g.; “: \” are befuddling me. |
2nd February 2021, 01:49 | #62 | Link |
HeartlessS Usurer
Join Date: Dec 2009
Location: Over the rainbow
Posts: 10,980
|
I have not really looked at it but suspect you only need call it with All=false.
__________________
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 ??? |
4th February 2021, 05:46 | #63 | Link |
Registered User
Join Date: Apr 2013
Posts: 346
|
In addition to asking if the script adjustment that would eliminate the “No combing” lines can be done, I am reporting some odd behavior with VDub2 and running the “FindCombingRed” function, although I suspect that it is a flaw in VDub2.
When I run a single avs file through VDub2’s “Run video analysis pass”, the results are as expected. However, when I try to load these avs files into VDub2’s “Queue batch operation”, specifying “Run video analysis pass”, the resulting text files all have a doubled “Frame count” line at the end, instead of just the one “Frame count” line that should be there. Additionally, some files result in empty text files with batch mode, but are fully populated when run alone, outside the batch process. Is this a flaw in VDub2, or is it somehow related to the script? Remember: the avs files run perfectly when fed through VDub2 one at a time. If you think it’s VDub2, I’ll post over there. Last edited by Danette; 4th February 2021 at 05:49. |
4th February 2021, 05:58 | #64 | Link | |
Registered User
Join Date: Sep 2007
Posts: 5,374
|
Quote:
SS mentioned it opened a few times in vdub2, probably a few more when you queue it Why not use batch avsr64 for the "analysis" pass. It will be faster than vdub for each run, also you don't have to queue them one by one - that ends up being much faster and less tedious Code:
for %a in ("*.avs") do avsr64 "%a" |
|
4th February 2021, 22:11 | #65 | Link |
HeartlessS Usurer
Join Date: Dec 2009
Location: Over the rainbow
Posts: 10,980
|
Groucho is the man:- https://forum.doom9.org/showthread.php?t=173259
[But zeppo was better] EDIT: Down link at top of page. EDIT: This was in answer to Danette asking where avsr64 was. The post seems to have disappeared.
__________________
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; 4th February 2021 at 23:15. |
4th February 2021, 23:38 | #66 | Link | |
Registered User
Join Date: Apr 2013
Posts: 346
|
Quote:
Incidentally, the bug I mentioned does seem to be specific to VDub2. I ran the batch function in my old VDub, v1.10.4, and it performed flawlessly. |
|
6th February 2021, 23:43 | #67 | Link | |
Registered User
Join Date: Mar 2011
Posts: 4,829
|
Quote:
http://avisynth.nl/index.php/Operators b = (a==true) ? 1 : 2 means if (a==true) then b=1 else b=2 Although you can abbreviate it further, assuming "a" is either true or false. b = a ? 1 : 2 For b = (a==false) ? 1 : 2 it'd be b = !a ? 1 : 2 " \ " is simply a line break. It can only occur at the end of a line, or before any text at the beginning of a line. So you can do this sort of thing to make long lines readable. Code:
b = a ? 1 : \ 2 b = \ a ? 1 : 2 FindRed() Code:
# =============================================================================== function FindRed(clip Vid, bool "Append", string "FileName", bool "All", bool "Write") { Append = default(Append, false) FileName = default(FileName, "") All = default(All, false) Write = default(Write, true) N = ScriptFile() LN = LCase(N) NLen = StrLen(N) ELen = FindStr(LN, ".avs") - 1 File_Name = LeftStr(N, NLen-(NLen-ELen)) FName = (FileName == "") ? File_Name : FileName File = FName + "_Red.txt" Vid = Vid.GreyScale() CombTest = BlankClip(Vid, Color=color_red) Vid = Vid.TFM(Clip2=CombTest).TDecimate() global Everything = All Out = FrameEvaluate(Vid, """ IsRed = (AverageChromaV() > 128) IsEnd = (FrameCount() == (current_frame + 1)) WriteThis = \ (!IsRed && !Everything ? "" : string(current_frame)) + \ (!IsRed ? "" : string(AverageChromaV()-128, " - %.2f")) + \ (!IsEnd ? "" : (!IsRed && !Everything ? "" : chr(10)) + string(FrameCount(), "%.0f - Frame Count")) """) Out = !Write ? Vid : \ !All ? WriteFileIf(Out, File, "IsRed || IsEnd", "WriteThis", Append=Append) : \ WriteFile(Out, File, "WriteThis", Append=Append) return Out } # =============================================================================== Code:
73 - 30.60 75 - 24.92 76 - 112.00 77 - 26.79 79 - 28.62 80 - 112.00 81 - 34.56 92 - 14.91 93 - 16.27 162 - 42.75 163 - 112.00 164 - 35.61 208 - Frame Count Code:
WriteThis = \ (!IsRed && !Everything ? "" : string(current_frame)) + \ (!IsEnd ? "" : (!IsRed && !Everything ? "" : chr(10)) + string(FrameCount(), "%.0f")) Code:
73 75 76 77 79 80 81 92 93 162 163 164 208 Last edited by hello_hello; 7th February 2021 at 00:29. |
|
29th October 2021, 15:46 | #68 | Link |
Registered User
Join Date: Apr 2013
Posts: 346
|
Something odd has happened. I had been using this function, successfully for many months. Then, haven't needed it for about 4 months. Now, I'm trying to use it again and I get the error message "LeftStr: Negative character count not allowed."
I've double-checked the code and it is as written, above. Nor can I recall any changes that might be interfering with it. Any idea as to what is causing this? |
29th October 2021, 18:56 | #69 | Link |
HeartlessS Usurer
Join Date: Dec 2009
Location: Over the rainbow
Posts: 10,980
|
Try insert this before error line,
Code:
RT_debugF("N=%s\nNLEN=%d\nELen=%d",N,NLen,ELen,name="Danette: ") # view in DebugView
__________________
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 ??? |
29th October 2021, 21:07 | #70 | Link | |
Registered User
Join Date: Apr 2013
Posts: 346
|
Well, I struggled with this all morning. Then, after I inserted your debug line, it worked normally again. Go figure. Seems to be working now.
For completeness, the log for the DebugView is below. Note that this is after it started functioning again. Quote:
|
|
29th October 2021, 21:25 | #71 | Link |
HeartlessS Usurer
Join Date: Dec 2009
Location: Over the rainbow
Posts: 10,980
|
Very strange [a bit Halloweeny].
I get same "unrecognized accel key" stuff as you from AvsPMod, maybe we got some optional script missing or something. (I usually use PsPad and VDub2)
__________________
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 ??? |
10th November 2021, 17:45 | #75 | Link |
Registered User
Join Date: Apr 2013
Posts: 346
|
Well, I'm back with the same problem. This time, inserting and removing the DebugView line did not cause that odd recovery that I mentioned, above, in post 70.
It was working fine for a while. The only change, since last running it, is that I moved to AviSynth+ 3.7 and updated a lot of filters. |
10th November 2021, 17:53 | #76 | Link |
HeartlessS Usurer
Join Date: Dec 2009
Location: Over the rainbow
Posts: 10,980
|
Yeah but,
what did the output to DebugView say Code:
RT_debugF("N=%s\nNLEN=%d\nELen=%d",N,NLen,ELen,name="Danette: ") [EDIT: Just the RT_DebugF line, not all the AvsPMod accelerator stuff. and of course the error message] EDIT: The line will begin with "Danette: " EDIT: And temp remove all non used filters from plugins. EDIT: Change to this, just incase. Code:
RT_debugF("N=%s\nNLEN=%d\nELen=%d",string(N),string(NLen),string(ELen),name="Danette: ")
__________________
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; 10th November 2021 at 18:00. |
10th November 2021, 19:08 | #77 | Link | ||||
Registered User
Join Date: Apr 2013
Posts: 346
|
I removed nearly all filters, leaving just enough to keep this particular script operating, but the same error appeared. The error, referring to line 14, is:
Quote:
Quote:
So, I ran this, again: Quote:
Quote:
|
||||
10th November 2021, 19:15 | #78 | Link |
HeartlessS Usurer
Join Date: Dec 2009
Location: Over the rainbow
Posts: 10,980
|
Oops, I changed from int (requires %d) to string() [requires %s], so should have been
Code:
RT_debugF("N=%s\nNLEN=%s\nELen=%s",string(N),string(NLen),string(ELen),name="Danette: ") I'll look again at the script [I remember it does look a bit wierd, but as it worked, I did not look further]. EDIT: Is it [hello_hello] script from post 46 ?
__________________
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; 10th November 2021 at 19:19. |
10th November 2021, 19:43 | #79 | Link | ||
HeartlessS Usurer
Join Date: Dec 2009
Location: Over the rainbow
Posts: 10,980
|
From previous post edit,
Quote:
Code:
N = ScriptFile() # Name of current script (no path) LN = LCase(N) NLen = StrLen(N) ELen = FindStr(LN, ".avs") - 1 # Length left of Extension, of current scipt File_Name = LeftStr(N, NLen-(NLen-ELen)) # Error Quote:
and this line Code:
ELen = FindStr(LN, ".avs") - 1 # Length left of Extension, of current scipt So, question is, how come you have a avs script called "New File (2)" [without .avs extension] EDIT: and this bit did my head in a bit, Code:
File_Name = LeftStr(N, NLen-(NLen-ELen)) # Error Line Code:
File_Name = LeftStr(N, ELen) # Where -ve ELen is error for LeftStr
__________________
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; 10th November 2021 at 20:59. |
||
10th November 2021, 21:49 | #80 | Link | ||
Registered User
Join Date: Apr 2013
Posts: 346
|
Yes, the script is from [hello_hello] post 46, which I renamed to MoireEffect for the avsi. Don’t remember why I didn’t use post 67 (which doesn’t work, either).
Why it’s called "New File (2)", I have no idea. It is in a file having the avsi extension. I tried replacing the Quote:
Quote:
|
||
Thread Tools | Search this Thread |
Display Modes | |
|
|