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 Usage

Reply
 
Thread Tools Search this Thread Display Modes
Old 14th September 2016, 18:04   #1  |  Link
color
Registered User
 
color's Avatar
 
Join Date: May 2016
Posts: 155
Color flickering - Need help.

Hello.

I got some old vhs that has color flickering, every second frame has another color to it, so it works with dropping every second frame but it does not run smooth. Is there a way to fix this.

Also I need help with some older vhs that looks like this, I can not find his avisynth-script when searching if anyone know how this was made?

https://www.youtube.com/watch?v=agxQ3zpXOww
color is offline   Reply With Quote
Old 14th September 2016, 19:19   #2  |  Link
StainlessS
HeartlessS Usurer
 
StainlessS's Avatar
 
Join Date: Dec 2009
Location: Over the rainbow
Posts: 10,228
Maybe take a look here (CNR2), http://avisynth.nl/index.php/Externa...oral_Denoisers

Also take a peek at all other filters on that wiki page.

EDIT: Dont forget to do page search for 'VHS', (there may be other filters that dont mention VHS).
__________________
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; 14th September 2016 at 19:21.
StainlessS is offline   Reply With Quote
Old 14th September 2016, 19:34   #3  |  Link
johnmeyer
Registered User
 
Join Date: Feb 2002
Location: California
Posts: 2,577
You have two separate issues.

The YouTube video is relatively straightforward to fix (at least to the extent shown in that video), and a combination of CNR2 and MDegrain2 should work. I've posted a script many times that handles this. Just search on my name and "CNR2" and "MDegrain2."

I've never seen color that is different on even frames than it is on odd frames. You most definitely need to post a sample of that because it sounds quite unique.
johnmeyer is offline   Reply With Quote
Old 14th September 2016, 19:58   #4  |  Link
color
Registered User
 
color's Avatar
 
Join Date: May 2016
Posts: 155
StainlessS, Oh thank you. That did the job for the movie. I do have only one problem, but its no big deal, I just tried it on two movies that has that problem with color flickering. In the begining there is a title that flashes green and blue, but rest looks good. Don't know how to fix that.

I did edit so it worked good for me:

DirectShowSource("my movie")
Cnr2(mode="oxx", scdthr=10.0, lm=192, un=255, um=255, vn=194, vm=255, log=false, sceneChroma=true)

I don't know how I missed that plugin.
color is offline   Reply With Quote
Old 14th September 2016, 20:38   #5  |  Link
color
Registered User
 
color's Avatar
 
Join Date: May 2016
Posts: 155
johnmeyer, i did not find the plugin "MDegrain2" when searching, I tried some other tools and did not got it to work.

This is how the image looks like:
http://forumbilder.se/FB28T/did-not-fix-color010956.bmp

I know, the color is also horrible!
color is offline   Reply With Quote
Old 14th September 2016, 20:41   #6  |  Link
StainlessS
HeartlessS Usurer
 
StainlessS's Avatar
 
Join Date: Dec 2009
Location: Over the rainbow
Posts: 10,228
Have a look at deflicker filters, also note what JohnMeyer said, (site expert for such dodgy stuff), and post a sample as requested.

EDIT: There is a SEARCH button at top of every forum page.
And a pic is nice, but not much use in fixing video, need video sample (see SendSpace or MediaFire).

EDIT: I use MCDegrain() rather MDegrain2() [MCDegrain(frames=2) is a wrapper for MDegrain, but more convenient].
http://forum.doom9.org/showthread.ph...89#post1508289
__________________
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; 14th September 2016 at 20:52.
StainlessS is offline   Reply With Quote
Old 14th September 2016, 22:35   #7  |  Link
johnmeyer
Registered User
 
Join Date: Feb 2002
Location: California
Posts: 2,577
Quote:
Originally Posted by color View Post
johnmeyer, i did not find the plugin "MDegrain2" when searching, I tried some other tools and did not got it to work.

This is how the image looks like:
http://forumbilder.se/FB28T/did-not-fix-color010956.bmp

I know, the color is also horrible!
I can't help you without a video sample. You only need to post 10 seconds or so. Use Medifire or similar free sharing service.

It looks like you may have some ghosting due to this possibly being a 2nd gen video (i.e., a copy of a VHS tape onto another VHS tape). There is code to deal with that separate problem as well.

You really need to learn to use the forum search feature. I just searched on this subforum, limiting results to my user name, with the search terms "mdegrain2" and "cnr2". As expected, it turned up dozens of threads where I've posted desnoising scripts, such as this one:

Dealing with a big amount of VHS noise

You will find code in one of the functions that can be enabled in order to shift the chroma ghosts to the left.

Last edited by johnmeyer; 14th September 2016 at 22:36. Reason: Revised URL
johnmeyer is offline   Reply With Quote
Old 1st April 2018, 17:52   #8  |  Link
color
Registered User
 
color's Avatar
 
Join Date: May 2016
Posts: 155
I have almost forgotten this. I have now cut 10 seconds, I hope someone can help me with a good script in avisynth.

https://fil.email/4hW4UBEz

PS. It will be deleted in 7 days.

And thank you johnmeyer. My english and "technical terms" is not the best so I have some problem, I did try a few but I can not get good resault.
__________________
Automatic Colorization

Last edited by color; 1st April 2018 at 17:54.
color is offline   Reply With Quote
Old 1st April 2018, 21:53   #9  |  Link
Mounir
Registered User
 
Join Date: Nov 2006
Posts: 758
Try this:

Quote:
LWLibavVideoSource(source="title00 (1)-026.mkv")
assumetff()
ConverttoRGB32(matrix="rec601",interlaced=true)
separatefields()
LoadVirtualDubPlugin("C:\Program Files (x86)\virtualdubmod1.5\plugins\Camcorder_Color_Denoise_sse2.vdf", "CCD", 0)
CCD(10,1) # 0 to 100 (maximum strength)
weave()
ConvertToYV16(interlaced=true)
orig=last
ev=orig.assumetff().separatefields().selecteven()
od=orig.assumetff().separatefields().selectodd()
ev
ue_chroma = UToY(ev).blur(0,1.5).binomialblur(5).ttempsmooth(maxr=6,lthresh=150, strength=6)
ve_chroma = VToY(ev).blur(0,1.5).binomialblur(5).ttempsmooth(maxr=6,lthresh=150, strength=6)
YToUV(ue_chroma, ve_chroma)
MergeLuma(ev)
ev_filtered=last
od
uo_chroma = UToY(od).blur(0,1.5).binomialblur(5).ttempsmooth(maxr=6,lthresh=150, strength=6)
vo_chroma = VToY(od).blur(0,1.5).binomialblur(5).ttempsmooth(maxr=6,lthresh=150, strength=6)
YToUV(uo_chroma, vo_chroma)
MergeLuma(od)
od_filtered=last
interleave(ev_filtered,od_filtered)
assumefieldbased().assumetff().weave()
# Edit: some awarpsharp2 can help aswell:
ConvertToYV12(interlaced=true)
a=last
luma=last
SeparateFields()
aWarpSharp2(depth=30)
Weave()
MergeChroma(a,last)
result (frame 413)

Last edited by Mounir; 1st April 2018 at 22:26.
Mounir is offline   Reply With Quote
Old 1st April 2018, 22:12   #10  |  Link
color
Registered User
 
color's Avatar
 
Join Date: May 2016
Posts: 155
I will give it a try tomorrow. It's a bit late now. On the frame it looks mutch better. Even if there is some color bleading on his arm.
__________________
Automatic Colorization
color is offline   Reply With Quote
Old 1st April 2018, 22:17   #11  |  Link
johnmeyer
Registered User
 
Join Date: Feb 2002
Location: California
Posts: 2,577
This person PM'd me. I wish people wouldn't do that.

I downloaded the zip file. The clip of the singer (the one shown above by Mounir) looks like a 2nd generation VHS copy, recorded at EP speed, captured from a deck without a TBC. In other words, it is really bad.

There is no way you can do anything to improve the detail. The best you can hope for is to average out the flickering in the red channel. I don't have any time to do this now, but CNR2, which is in the script I posted a year and a half ago when this thread first started, may be able to do some good. Also simply reducing the saturation of the red channel may help. That's all I have time for now.
johnmeyer is offline   Reply With Quote
Old 2nd April 2018, 07:21   #12  |  Link
color
Registered User
 
color's Avatar
 
Join Date: May 2016
Posts: 155
Thank you Mounir, I did use this, but added ghostbuster and did try deflicker in VD, It did make the red color also better a bit.

Johnmeyer, It has been fixed and I'm happy with the resault. And I'm sorry for sending you a PM to notify you that I've posted an update, I've seen your job and you do an amazing job with avisynthscript.
__________________
Automatic Colorization
color is offline   Reply With Quote
Old 2nd April 2018, 13:35   #13  |  Link
GMJCZP
Registered User
 
GMJCZP's Avatar
 
Join Date: Apr 2010
Location: I have a statue in Hakodate, Japan
Posts: 738
Try with small_deflicker, the link is in my signature.
__________________
By law and justice!

GMJCZP's Arsenal
GMJCZP is offline   Reply With Quote
Old 2nd April 2018, 13:49   #14  |  Link
color
Registered User
 
color's Avatar
 
Join Date: May 2016
Posts: 155
GMJCZP, I did try small_deflicker, but I get error "cache_getchild_cache_mode. 178010200" on the line "35":

o2=o.mt_makediff(mt_makediff(sm,smm,u=3,v=3).bicubicresize(width(o),height(o),0,0),u=3,v=3)

I did try the other versions on masktools2.dll but can't get it to work.
__________________
Automatic Colorization
color is offline   Reply With Quote
Old 2nd April 2018, 15:07   #15  |  Link
GMJCZP
Registered User
 
GMJCZP's Avatar
 
Join Date: Apr 2010
Location: I have a statue in Hakodate, Japan
Posts: 738
Masktools2 last version:

Here

You must use the version according to your OS.
__________________
By law and justice!

GMJCZP's Arsenal
GMJCZP is offline   Reply With Quote
Old 2nd April 2018, 16:10   #16  |  Link
Mounir
Registered User
 
Join Date: Nov 2006
Posts: 758
I'm tryin small deflicker out of curiosity, it returns the video should be Mod16. So for a video of 720x480 what that gives me ? Pardon my ignorance on this subject
Mounir is offline   Reply With Quote
Old 2nd April 2018, 16:36   #17  |  Link
color
Registered User
 
color's Avatar
 
Join Date: May 2016
Posts: 155
I do have Masktools2 2.2.14, updated a week ago. I do have Masktool also, can that make a problem?
__________________
Automatic Colorization
color is offline   Reply With Quote
Old 2nd April 2018, 19:36   #18  |  Link
GMJCZP
Registered User
 
GMJCZP's Avatar
 
Join Date: Apr 2010
Location: I have a statue in Hakodate, Japan
Posts: 738
@ Mounir:
I do not understand very well, for 720 * 480 it should work without problems, because it is mod 16.

@ color:
Try leaving only version masktools2 2.2.14 in your plugins folder.
__________________
By law and justice!

GMJCZP's Arsenal
GMJCZP is offline   Reply With Quote
Old 2nd April 2018, 19:51   #19  |  Link
color
Registered User
 
color's Avatar
 
Join Date: May 2016
Posts: 155
I have another plugin using masktools, but It worked when removing masktools and leaving the masktools2 in the folder. Thank you.
__________________
Automatic Colorization
color is offline   Reply With Quote
Old 3rd April 2018, 11:22   #20  |  Link
GMJCZP
Registered User
 
GMJCZP's Avatar
 
Join Date: Apr 2010
Location: I have a statue in Hakodate, Japan
Posts: 738
Quote:
Originally Posted by color View Post
I have another plugin using masktools, but It worked when removing masktools and leaving the masktools2 in the folder.
I suggest using LoadPlugin for call the old version of masktools, placing it in a different folder from the plugins directory.

Edit: How did you do with small_deflicker?

Edit2: It seems that the guy of the youtube video used Median, but he has not shared the script, so he does not know for sure how he did it.
__________________
By law and justice!

GMJCZP's Arsenal

Last edited by GMJCZP; 3rd April 2018 at 11:33.
GMJCZP is offline   Reply With Quote
Reply

Tags
color restoration

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 07:17.


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