Log in

View Full Version : Avisynth2.6 to Avisynth+ (transparent lines)?


NLPguy
6th May 2022, 00:54
Hi folks,

I'm having some problems with AviSynth+.


I mean, I am using the script below that was created for AviSynth version 2.6 and I'm trying to adapt it to AviSynth +.


But I'm having a hard time trying to find: ContrastMask --- RemoveDirtMC --- RemoveSpotsMC2() that works on AviSynth +


I use MaskTools2.dll version of 09/04/2020.


note: I have attached the Avisynth image error.


SetMemoryMax(1024)
#SetFilterMTMode("MT_SERIALIZED", 3)

#LoadPlugin("D:\App\AVS\plugins64+\RemoveGrain.dll")
LoadPlugin("M:\Temp2\MaskTools2.dll")
#LoadPlugin("M:\Temp2\Depan.dll")
#LoadPlugin("M:\Temp2\DepanEstimate.dll")
#LoadPlugin("M:\Temp2\MVTools2.dll")
#LoadPlugin("M:\Temp2\LSMASHSource.dll")
#LoadPlugin("M:\Temp2\RgTools.dll")
#LoadPlugin("M:\Temp2\D2VSource.dll")
#LoadPlugin("M:\Temp2\MPEG2DecPlus64.dll")
#Import("M:\Temp2\Zs_RF_Shared.avsi")
#Import("M:\Temp2\LSFMod.avsi")
#Import("M:\Temp2\SetMTMode.avsi")
#Import("M:\Temp2\Stab.avsi")
Import("M:\Temp2\ContrastMask.avs")
Import("M:\Temp2\RemoveDirtMC.avsi")
###MPEG2Source("M:\Paulo Medeiros Junior 19-7-18\DVD\02-2.d2v")
AVISource("E:\Vinicius 7.10.21 - Fazer\02 Vinicius 3capt V17JVCES10 AVDPTL.avi") # DV AV

#v = LSMASHVideoSource("E:\Vinicius 7.10.21 - Fazer\02 Vinicius 3capt V17JVCES10.mp4", track=0, threads=0, seek_mode=0,
#\ seek_threshold=10, dr=False, fpsnum=30, fpsden=1,
#\ format="YUV420P8", decoder="", prefer_hw=0, ff_loglevel=0)
#a = LSmashAudioSource("E:\Vinicius 7.10.21 - Fazer\02 Vinicius 3capt V17JVCES10.mp4")
#AudioDub(v,a)



#SetFilterMTMode("DEFAULT_MT_MODE", 2)


#Trim(80,500)
AssumeTFF()
ConvertToYV12(interlaced=true,ChromaOutPlacement="MPEG2")
ContrastMask(enhance=6.5)
ColorYUV(off_v=4)
Levels(12,0.95,255,16,235,dither=true,coring=false)

ConvertToYV12(interlaced=true,ChromaOutPlacement="MPEG2")
SeparateFields()
e=SelectEven().RemoveDirtMC(80,false).TurnRight().RemoveSpotsMC2().TurnLeft()
o=SelectOdd().RemoveDirtMC(80,false).TurnRight().RemoveSpotsMC2().TurnLeft()
Interleave(e,o)
Weave()
#Prefetch(17)
return last #<-- Save as "Test2_Part02_A.avi" with Lagarith YV12 ---#




I've borrow this script from a guy that solved a problem of many transparent fine/thin horizontal lines in a video. He tested it in a video with many of these lines and it was a great success. However, the script was created for AviSynth Version 2.6 and I'm using AviSynth + for some time now.


It's important to mention that I've already tried to clean the VHS tape many times and tested it in 6 different VCRs. With this process the video quality improved a lot. But the fine transparent horizontal lines still remains.


Please, if some member knows how to adapt a script of version 2.6 to Avisynth+ I really appreciate.


Thank you so much in advance!

.

kedautinh12
6th May 2022, 04:31
MaskTools2 latest ver
https://github.com/pinterf/masktools/releases

RemoveDirtMC_SE
https://github.com/realfinder/AVS-Stuff/blob/Community/avs%202.5%20and%20up/RemoveDirtMC_SE.avsi

I think you need update all your plugins & scripts with avs+ to latest ver to make it's work:

https://github.com/Asd-g?tab=repositories

https://github.com/realfinder/AVS-Stuff/tree/Community

https://github.com/pinterf?tab=repositories

https://github.com/HomeOfAviSynthPlusEvolution

https://github.com/AviSynth/AviSynthPlus/issues/282#issuecomment-1102767396


And where you got RemoveSpotsMC2 and ContrastMask??? Thanks

VoodooFX
6th May 2022, 12:15
It's not AvS+ problem. You wouldn't be able to run it on v2.6 too as you don't have VariableBlur (http://avisynth.nl/index.php/VariableBlur) plugin.

kedautinh12
6th May 2022, 13:49
Lol, image visible now :D

NLPguy
8th May 2022, 14:34
MaskTools2 latest ver
https://github.com/pinterf/masktools/releases

RemoveDirtMC_SE
https://github.com/realfinder/AVS-Stuff/blob/Community/avs%202.5%20and%20up/RemoveDirtMC_SE.avsi

I think you need update all your plugins & scripts with avs+ to latest ver to make it's work:

https://github.com/Asd-g?tab=repositories

https://github.com/realfinder/AVS-Stuff/tree/Community

https://github.com/pinterf?tab=repositories

https://github.com/HomeOfAviSynthPlusEvolution

https://github.com/AviSynth/AviSynthPlus/issues/282#issuecomment-1102767396


And where you got RemoveSpotsMC2 and ContrastMask??? Thanks


Hi kedautinh12,

Thanks for your answer.

I will update Avisynth and let you know if it worked.


The RemoveSpotsMC2 I didn't get yet.


And the ContrastMask I got here:
http://www.digitalfaq.com/forum/attachments/video-restore/8464d1524179550-newbie-video-restoration-contrastmaskavs


Furthermore, only to let you know, the script that I have borrow from other person seems almost ''magical'' in my humble opinion.

I mean, it improved a lot a video with many transparent horizontal lines; dark and noisy; and sometimes shaky to a much better version. The user sanlyn did an excellent job. My goal is to use this script in my videos too.

sanlyn almost ''magical'' script I got in this thread: http://www.digitalfaq.com/forum/video-restore/9713-avisynth-transparent-lines.html


Thank you so much!
.

patul
8th May 2022, 15:04
Probably RemoveSpotMC2 can be obtained from this post (https://forum.doom9.org/showthread.php?p=1591371#post1591371).