VideoHelp Forum

Try DVDFab and download streaming video, copy, convert or make Blu-rays,DVDs! Download free trial !
+ Reply to Thread
Page 1 of 2
1 2 LastLast
Results 1 to 30 of 35
Thread
  1. Member
    Join Date
    Jan 2014
    Location
    london england
    Search Comp PM
    Can anyone help me with a plug-in for removing dirt from video taken from film, which works in Virtual Dub?
    Quote Quote  
  2. I use AviSynth dirt removal filters in VDub all the time. One such good one is RemoveDirtMC but there are others. But I don't guess that's what you want. You're looking for a VDub-specific filter. Temporal filters do some dirt removal but the VDub ones aren't all that good, I don't believe. Your best bet is to learn enough AviSynth to be able to use the AviSynth ones.

    Maybe if you posted a short sample from your source we could provide more informed help.
    Quote Quote  
  3. If you are looking for a native VirtualDub filter, I am unaware of anything that works as well as what manono has suggested. AVISynth is a much better tool for this sort of thing. You can still use VirtualDub to read the output of the AVISynth dirt removal script.
    Quote Quote  
  4. One thing you need to be aware of: dirt removal removes spots that appear for only a single frame. Since the video frame rate is usually higher than the film frame rate you typically have to remove duplicate frames before you can remove dirt. For Hollywood movies that's usually pretty easy, a standard inverse telecine. But for home movies, with unknown frame rates, duplicate frames, blended frames, etc. it can be difficult. You'll probably need to use AviSynth with those.
    Quote Quote  
  5. Member PuzZLeR's Avatar
    Join Date
    Oct 2006
    Location
    Toronto Canada
    Search Comp PM
    Again, use AviSynth for this. Yes, you can run it through VirtualDub.

    I too would like to see a sample, but maybe some blind advice would be to also check out RemoveSpotsMC3x(), from this Forum. I outline it here, with all auxilliary files you'd need:

    https://forum.videohelp.com/threads/342111-RemoveDirtMC?p=2409705&viewfull=1#post2409705
    I hate VHS. I always did.
    Quote Quote  
  6. Member
    Join Date
    Jan 2014
    Location
    london england
    Search Comp PM
    This is a clip. I've already removed most of the dirt and scratches by hand which took months. I just want to clear up the remainder. The video is in 24 fps progressive so there should be no need for frame duplication.
    Image Attached Files
    Quote Quote  
  7. Here is the result of using the motion-compensated RemoveDirtMC, which depends on the AVISynth RemoveDirt filter. I have interleaved each original frame with the resulting cleaned frame. I actually did some additional processing, using my version of VideoFred's AVISynth script. This also reduces grain and removes gate weave, among other things. I toned down all the other settings, and then used moderate dirt removal. All of the removal of your film negatives spots were done entirely by the RemoveDirtMC filter and not the other things.

    Here is a link to that file, saved using the Lagarith codec, the same codec you used for your original. I have no idea why your original was so large: this is about 1/10 the size.

    tal 32 cor masked dirt removal interleaved before & after.avi

    The best way to view this file is to load it into VirtualDub, or something similar, and then rock back and forth between each pair of "before/after" frames.
    Quote Quote  
  8. AviSynth script with very moderate dirt removal:
    Code:
    import("C:\Program Files (x86)\AviSynth\plugins\RemoveDirtMC.avs") 
    
    AviSource("tal 32 cor masked dirt.avi") 
    ConvertToYV12(matrix="rec709")
    RemoveDirtMC(20, false)
    A few scratches are left but detail isn't harmed much.
    Image Attached Files
    Quote Quote  
  9. It would be interesting to see the video before the manual dirt removal. To compare your manual results to fully automated results.

    By the way, I think there's a frame missing between frames 64 and 65, and the lower 2/3 of frame 67 is a duplicate of frame 65. Maybe that was some of your earlier cleanup.
    Last edited by jagabo; 25th May 2016 at 20:44.
    Quote Quote  
  10. Originally Posted by jagabo View Post
    By the way, I think there's a frame missing between frames 64 and 65, and the lower 2/3 of frame 67 is a duplicate of frame 65. Maybe that was some of your earlier cleanup.
    Wow, you are correct. Sharp eyes.
    Quote Quote  
  11. Member
    Join Date
    Jan 2014
    Location
    london england
    Search Comp PM
    Thanks to all. I've lost the uncleaned version of that clip, but here's another clip, uncleaned and manualy cleaned. It seems I definitely need RemoveDirtMC. Yes the missing frame etc was the result of my manual cleaning. I've already done Deshaker on it, and I will later do degraining and sharpen. I'l have to do tests to see if its best to sharpen then degrain, or degrain then sharpen.
    Last edited by timsky; 26th May 2016 at 15:50.
    Quote Quote  
  12. Member
    Join Date
    Jan 2014
    Location
    london england
    Search Comp PM
    rr
    Last edited by timsky; 26th May 2016 at 16:55.
    Quote Quote  
  13. Member
    Join Date
    Jan 2014
    Location
    london england
    Search Comp PM
    ss
    Last edited by timsky; 26th May 2016 at 16:54.
    Quote Quote  
  14. Member
    Join Date
    Jan 2014
    Location
    london england
    Search Comp PM
    hhh
    Image Attached Files
    Quote Quote  
  15. Member
    Join Date
    Jan 2014
    Location
    london england
    Search Comp PM
    gggg
    Image Attached Files
    Quote Quote  
  16. None of the links is working. Try removing the percent sign from the name before uploading.
    Quote Quote  
  17. Member
    Join Date
    Jan 2014
    Location
    london england
    Search Comp PM
    dirty clip
    Image Attached Files
    Quote Quote  
  18. Member
    Join Date
    Jan 2014
    Location
    london england
    Search Comp PM
    manually cleaned clip
    Image Attached Files
    Quote Quote  
  19. A few of the blemishes are left but this cleans it up pretty well without damaging the picture.

    Code:
    AviSource("tal M h200 v1000 cropped.avi") 
    ConvertToYV12(matrix="rec709")
    Crop(238,0,-242,-0)
    BilinearResize(width/2, height/2)
    RemoveDirtMC(25, false)
    UnsharpMask(strength=50, radius=2, threshold=0)
    nnedi3_rpow2(2, cshift="Spline36Resize")
    Since the underlying sharpness of the video is barely half the pixel resolution I downscaled before removing dirt, then sharpened and upscaled back to the original frame size. One can crank the dirt removal up but then you start getting other motion artifacts and you lose more detail. Already some of the dots in the glass are disappearing.
    Image Attached Files
    Quote Quote  
  20. Member
    Join Date
    Jan 2014
    Location
    london england
    Search Comp PM
    Looks good to me. I've downloaded AVISYNTH and put the AVISYNTH plugin into Virtual Dub. What do I do now?
    Quote Quote  
  21. That's not how it's done. Read up:

    http://avisynth.nl/index.php/First_script

    http://avisynth.nl/index.php/Getting_started

    Several of the filters jagabo used aren't built into AviSynth and they'll also have to be tracked down. These include RemoveDirtMC (which itself needs another filter to work), UnsharpMask, and NNEDI3.
    Quote Quote  
  22. Member
    Join Date
    Jan 2014
    Location
    london england
    Search Comp PM
    I'm trying to learn avisynth. If I make a document with "version()" typed in it, it works fine. But if I make a document with "AviSource(C:\Users\Tim 2\Desktop\Tal stabilised clips\tal 31 test.avi)" then Virtual dub says Unknown or unsupported file type. This is the same whether the clip is Lagarith avi or microsoft uncompressed avi.

    The same clip plays fine if you just drop it into VD.

    What is wrong?
    Last edited by timsky; 21st Jun 2016 at 19:08. Reason: added more
    Quote Quote  
  23. DECEASED
    Join Date
    Jun 2009
    Location
    Heaven
    Search Comp PM
    Originally Posted by timsky View Post
    "AviSource(C:\Users\Tim 2\Desktop\Tal stabilised clips\tal 31 test.avi)"
    Should be AviSource("C:\Users\Tim 2\Desktop\Tal stabilised clips\tal 31 test.avi").
    Quote Quote  
  24. Member
    Join Date
    Jan 2014
    Location
    london england
    Search Comp PM
    OK I've just tried that (adding the quotation marks) but it still says Unknown or unsupported file type.

    I'm typing

    AviSource("C:\Users\Tim 2\Desktop\Tal stabilised clips\tal 31 test.avi")
    Quote Quote  
  25. DECEASED
    Join Date
    Jun 2009
    Location
    Heaven
    Search Comp PM
    That's weird, to say the least

    Just a wild guess... what do you mean by
    Originally Posted by timsky View Post
    .....

    put the AVISYNTH plugin into Virtual Dub.


    I don't remember whether there exists a 'VirtualDub plugin' option during the Avisynth setup, but I'm pretty sure I've never used it.
    Perhaps that's what's interfering with your Avisynth environment?
    Quote Quote  
  26. By "document", did you mean a plain text file e.g. in notepad ?

    Did you save it? Did you rename the extension to .avs from .txt ?

    eg.

    file.txt

    becomes

    file.avs
    Quote Quote  
  27. Member
    Join Date
    Jan 2014
    Location
    london england
    Search Comp PM
    I typed and saved the document in Wordpad and it's stored in Documents library. In Documents library it's listed as

    myclip.avs 22/06/2016 01:29 TXT File 1KB
    Quote Quote  
  28. DECEASED
    Join Date
    Jun 2009
    Location
    Heaven
    Search Comp PM
    Originally Posted by timsky View Post
    I typed and saved the document in Wordpad and it's stored in Documents library. In Documents library it's listed as

    myclip.avs 22/06/2016 01:29 TXT File 1KB
    If that's true, then the ACTUAL name of that file is "myclip.avs.TXT"

    Is your Windows Explorer configured to hide file extensions
    Quote Quote  
  29. Member
    Join Date
    Jan 2014
    Location
    london england
    Search Comp PM
    Is your Windows Explorer configured to hide file extensions [/QUOTE]


    I have no idea. How would I fix that?
    Quote Quote  
  30. DECEASED
    Join Date
    Jun 2009
    Location
    Heaven
    Search Comp PM
    Originally Posted by timsky View Post
    I have no idea.
    Then it is.

    How would I fix that?
    Hold the Windows key, press "E", then in the menu bar goto "Tools", then select "Folder options".
    Last edited by El Heggunte; 22nd Jun 2016 at 15:51. Reason: clarity
    Quote Quote  



Similar Threads