Usually Bifrost() or LutDeRainbow() work wonders, but no matter how strong I make these 2 by altering the parameters, the rainbows just will not come out of or reduce any in this source. I have also tried both before and after TIVTC.
Here's an untouched video sample to look at.
https://mega.co.nz/#!cl4wELTS!RM43m7bUnkhu-uIVBlzKWHOiF_FfDiCqmlqzIkkAxcQ
Any suggestions on why I haven't been able to remove them?
Try StreamFab Downloader and download from Netflix, Amazon, Youtube! Or Try DVDFab and copy Blu-rays! or rip iTunes movies!
+ Reply to Thread
Results 1 to 25 of 25
Thread
-
-
Something like:
Code:MergeChroma(last, BicubicResize(width/2,height/2).BicubicResize(width,height).aWarpSharp(depth=30))
-
What you suggested seems to have helped some.
Its doing more harm than good though. Its not only losing color in some things but its also thinning lines alot and making it look worse. Several things look ruined as well like all of the background colors and lines and its extremely noticable. Its also ruining the scenes with alot more colors in them. I tried lowering the depth some but then the rainbows are visible again.
BEFORE
AFTER
I thought awarpsharp in mergechroma was a line thinner or chroma sharpener and that's what I've been using it for, why would that get rid of rainbows?
I usually use it like this for chroma sharpening when color is bleeding over lines in both directions.
MergeChroma(aWarpSharp2(depth=10))
Ive never used this before, is that the reason?
last, BicubicResize(width/2,height/2).BicubicResize(width,height)Last edited by killerteengohan; 10th Aug 2014 at 06:21.
-
The combination of downscaleing and upscaling blurs the chroma channels (as well as the luma). aWarpSharp is then used to sharpen the chroma (and luma) channels. MergeChroma then merges the modified chroma with the original luma (throwing away the blurred/sharpened luma).
If you look at the chroma channels you'll see oversharpening (?) halos.
Code:StackVertical(UtoY(), VtoY())
After filtering:
Feel free to try other resizing and sharpening filters.Last edited by jagabo; 10th Aug 2014 at 08:56.
-
Well it looks like too much detail and or colors are getting ruined with current method.
Lanczosresize usually looks better to me but not in this case, your suggestions looks better.
Do you have an alternate suggestion for the sharpening filter awarpsharp? That seems to be whats doing the things I don't like to the video.
Would another video sample from a completely different scene with alot more colors help you out more? -
-
I'd suggest the resizers used by jagabo, or try Spline36Resize. Lanczos never "looks right" to me. It's known to cause the kinds of edge artifacts we're looking at. Here's an old thread you might to look over: http://forum.doom9.org/showthread.php?t=145210.
- My sister Ann's brother -
Well here's another untouched sample from another scene then. Hopefully this helps out more as you think. You can see the rainbows and colors ALOT better in this one.
https://mega.co.nz/#!9kwQ2KYC!CRZaw_1xikaqZ3Kiw64faEm24aSa7EAhfRuo4o-BRugLast edited by killerteengohan; 11th Aug 2014 at 14:18.
-
Last edited by killerteengohan; 11th Aug 2014 at 14:19.
-
I'm having a bit of trouble getting this to work in my script.
I added in this and it works fineCode:MergeChroma(last, Spline36Resize(360,240).LanczosResize(width,height).aWarpSharp2(depth=6))
It looks like this when done.Code:LoadPlugin("C:\Program Files (x86)\MeGui\tools\dgindex\DGDecode.dll") DGDecode_mpeg2source("C:\Users\Mike\Desktop\Encodes\Batman Beyond\Season 1\Disc 2\Episode 10\VTS_01_1.d2v", info=3) LoadPlugin("C:\Program Files (x86)\MeGui\tools\avisynth_plugin\ColorMatrix.dll") ColorMatrix(hints=true, interlaced=true, threads=0) LoadPlugin("C:\Program Files (x86)\MeGui\tools\avisynth_plugin\TIVTC.dll") tfm(order=1).tdecimate(hybrid=0) crop( 4, 2, -4, 0) MergeChroma(last, Spline36Resize(360,240).LanczosResize(width,height).aWarpSharp2(depth=6)) LanczosResize(640,480) # Lanczos (Sharp) hqdering() LoadPlugin("C:\Program Files (x86)\megui\tools\avisynth_plugin\UnDot.dll") Undot() # Minimal Noise deen("c3d", 0, 5, 5) maa2(ss=3.00) LimitedSharpenFaster(ss_x=2.0, ss_y=2.0, strength=20, overshoot=0, undershoot=0, soft=0, edgemode=0)
But I have come across an episode where I wish to use different filters on different frames because the same filters aren't needed on all of the frames.
I use the script like this without the above added in and it works fine.Code:LoadPlugin("C:\Program Files (x86)\megui\tools\dgindex\DGDecode.dll") LoadPlugin("C:\Program Files (x86)\megui\tools\avisynth_plugin\ColorMatrix.dll") LoadPlugin("C:\Program Files (x86)\megui\tools\avisynth_plugin\UnDot.dll") LoadPlugin("C:\Program Files (x86)\MeGui\tools\avisynth_plugin\TIVTC.dll") source=DGDecode_mpeg2source("C:\Users\Mike\Desktop\Encodes\Batman Beyond\Season 1\Disc 2\Episode 10\VTS_01_1.d2v", info=3).ColorMatrix(hints=true, threads=0).tfm(order=1).tdecimate(hybrid=0).crop( 4, 2, -4, 0).LanczosResize(640,480) clip1=Trim(source, 0, 24699).hqdering.Undot().deen("c3d", 0, 5, 5).maa2(ss=3.00).LimitedSharpenFaster(ss_x=2.0, ss_y=2.0, strength=30, overshoot=0, undershoot=0, soft=0, edgemode=0) clip2=Trim(source, 24700, 25147).checkmate(tthr2=0).hqdering.Undot().deen("c3d", 0, 5, 5).maa2(ss=3.00).LimitedSharpenFaster(ss_x=2.0, ss_y=2.0, strength=30, overshoot=0, undershoot=0, soft=0, edgemode=0) clip3=Trim(source, 25148, 30455).hqdering.Undot().deen("c3d", 0, 5, 5).maa2(ss=3.00).LimitedSharpenFaster(ss_x=2.0, ss_y=2.0, strength=30, overshoot=0, undershoot=0, soft=0, edgemode=0) Return clip1 + clip2 + clip3
I added in the above line to the script just like this and I keep getting an error saying "Invalid arguments to function Spline36Resize"Code:LoadPlugin("C:\Program Files (x86)\megui\tools\dgindex\DGDecode.dll") LoadPlugin("C:\Program Files (x86)\megui\tools\avisynth_plugin\ColorMatrix.dll") LoadPlugin("C:\Program Files (x86)\megui\tools\avisynth_plugin\UnDot.dll") LoadPlugin("C:\Program Files (x86)\MeGui\tools\avisynth_plugin\TIVTC.dll") source=DGDecode_mpeg2source("C:\Users\Mike\Desktop\Encodes\Batman Beyond\Season 1\Disc 2\Episode 10\VTS_01_1.d2v", info=3).ColorMatrix(hints=true, threads=0).tfm(order=1).tdecimate(hybrid=0).crop( 4, 2, -4, 0).MergeChroma(last, Spline36Resize(360,240).LanczosResize(width,height).aWarpSharp2(depth=6)).LanczosResize(640,480) clip1=Trim(source, 0, 24699).hqdering.Undot().deen("c3d", 0, 5, 5).maa2(ss=3.00).LimitedSharpenFaster(ss_x=2.0, ss_y=2.0, strength=30, overshoot=0, undershoot=0, soft=0, edgemode=0) clip2=Trim(source, 24700, 25147).checkmate(tthr2=0).hqdering.Undot().deen("c3d", 0, 5, 5).maa2(ss=3.00).LimitedSharpenFaster(ss_x=2.0, ss_y=2.0, strength=30, overshoot=0, undershoot=0, soft=0, edgemode=0) clip3=Trim(source, 25148, 30455).hqdering.Undot().deen("c3d", 0, 5, 5).maa2(ss=3.00).LimitedSharpenFaster(ss_x=2.0, ss_y=2.0, strength=30, overshoot=0, undershoot=0, soft=0, edgemode=0) Return clip1 + clip2 + clip3
Why is it working in all of the other episodes but as soon as I try to use it in this one where I'm trimming and using different filters it wants to give me an error?Last edited by killerteengohan; 13th Aug 2014 at 14:31.
-
Since you piping the output of mpeg2source to the filter chain, last, width and height aren't defined at the time you are calling Spline36Resize. Run the MergeChroma sequence on a separate line using source instead of last.
-
I'm a tiny bit confused with your reply.
So I add in this as a separate line like this?
Code:source=.MergeChroma(last, Spline36Resize(360,240).LanczosResize(width,height).aWarpSharp2(depth=6))
How should I adjust it? Can you alter and paste it? -
You should understand this by now: When you don't explicitly name a stream it is given the name "last". When you don't specify a stream by name the stream named "last" is used. In your script you named all your streams so the stream "last" was never created. Width and height refer to last.width and last.height. Since there is no "last" there is no last.width and last.height. Change your line to:
Code:source = MergeChroma(source, Spline36Resize(360, 240).LanczosResize(source.width, source.height).aWarpSharp2(depth=6))
-
I did what you said to and wrote it exactly as you said and I'm still getting the same error. Invalid arguments to function "spline36resize"
Code:LoadPlugin("C:\Program Files (x86)\megui\tools\dgindex\DGDecode.dll") LoadPlugin("C:\Program Files (x86)\megui\tools\avisynth_plugin\ColorMatrix.dll") LoadPlugin("C:\Program Files (x86)\megui\tools\avisynth_plugin\UnDot.dll") LoadPlugin("C:\Program Files (x86)\MeGui\tools\avisynth_plugin\TIVTC.dll") source=DGDecode_mpeg2source("C:\Users\Mike\Desktop\Encodes\Batman Beyond\Season 1\Disc 2\Episode 10\VTS_01_1.d2v", info=3).ColorMatrix(hints=true, threads=0).tfm(order=1).tdecimate(hybrid=0).crop( 4, 2, -4, 0).LanczosResize(640,480) source=MergeChroma(source, Spline36Resize(360,240).LanczosResize(source.width,source.height).aWarpSharp2(depth=6)) clip1=Trim(source, 0, 24699).hqdering.Undot().deen("c3d", 0, 5, 5).maa2(ss=3.00).LimitedSharpenFaster(ss_x=2.0, ss_y=2.0, strength=30, overshoot=0, undershoot=0, soft=0, edgemode=0) clip2=Trim(source, 24700, 25147).checkmate(tthr2=0).hqdering.Undot().deen("c3d", 0, 5, 5).maa2(ss=3.00).LimitedSharpenFaster(ss_x=2.0, ss_y=2.0, strength=30, overshoot=0, undershoot=0, soft=0, edgemode=0) clip3=Trim(source, 25148, 30455).hqdering.Undot().deen("c3d", 0, 5, 5).maa2(ss=3.00).LimitedSharpenFaster(ss_x=2.0, ss_y=2.0, strength=30, overshoot=0, undershoot=0, soft=0, edgemode=0) Return clip1 + clip2 + clip3
I've tried it in several different places of the script and writing it in different ways as well and with no luck. its always that same error no matter what I've tried so far.
If I edit the line to this in order to get rid of the resize to see if it goes away without it and make itCode:MergeChroma(aWarpSharp2(depth=6))
Last edited by killerteengohan; 15th Aug 2014 at 15:03.
-
I could swear I did that in the script I pasted above, didnt I?
source=MergeChroma(source, Spline36Resize(360,240).LanczosResize(source.width,source.height ).aWarpSharp2(depth=6)) -
Normally what your telling me to do should work, I've never had this issue before but no matter what the hell I do, it doesn't not work with this script at all. Most of the things you've told me are pretty much common sense but its not working with this script. I even tried adding it in the named streams clips 1-3 and it wont work in those either.
I cant even use mergechroma in any way at all in this script or I get an error saying invalid function.
Try actually using the script on the sample clip yourself and see if it works for you. I don't see what your telling me as wrong, but its not working for some unknown reason to me when I try to use it in this script anywhere or anyway. -
No, you added source as the first argument to MergeChroma(). Once again, when you don't specify an stream AviSynth assumes "last". Since you didn't specify a stream for Spline36Resize(360,240) it's assuming Spline36Resize(last,360,240). Since there is no last it's giving you an error.
-
Are you telling me that this line in my script is not specifying the stream named source?
Code:source=DGDecode_mpeg2source("C:\Users\Mike\Desktop\Encodes\Batman Beyond\Season 1\Disc 2\Episode 10\VTS_01_1.d2v", info=3).ColorMatrix(hints=true, threads=0).tfm(order=1).tdecimate(hybrid=0).crop( 4, 2, -4, 0).LanczosResize(640,480)
Everything else seems to work fine in the clip streams when I tell it to use source, but the mergechroma and or the resizer in it doesn't want to. -
Eh forget it, since your not just simply correcting it and pasting the entire thing corrected for me to paste, Ill just say screw it and try something else since I cant get it working.
I rewrote the script entirely, this should have the same effect but with spline36resize actually working this time shouldnt it? It looks like its working to me so far with no error stated.
Code:LoadPlugin("C:\Program Files (x86)\MeGui\tools\dgindex\DGDecode.dll") DGDecode_mpeg2source("C:\Users\Mike\Desktop\Encodes\Batman Beyond\Season 1\Disc 2\Episode 10\VTS_01_1.d2v", info=3) LoadPlugin("C:\Program Files (x86)\MeGui\tools\avisynth_plugin\ColorMatrix.dll") ColorMatrix(hints=true, interlaced=true, threads=0) LoadPlugin("C:\Program Files (x86)\MeGui\tools\avisynth_plugin\TIVTC.dll") tfm(order=1).tdecimate(hybrid=0) crop( 4, 2, -4, 0) MergeChroma(last, Spline36Resize(360,240).LanczosResize(width,height).aWarpSharp2(depth=6)) LanczosResize(640,480) # Lanczos (Sharp) source=last clip1=Trim(source, 0, 24699).hqdering.Undot().deen("c3d", 0, 5, 5).maa2(ss=3.00).LimitedSharpenFaster(ss_x=2.0, ss_y=2.0, strength=30, overshoot=0, undershoot=0, soft=0, edgemode=0) clip2=Trim(source, 24700, 25147).checkmate(tthr2=0).hqdering.Undot().deen("c3d", 0, 5, 5).maa2(ss=3.00).LimitedSharpenFaster(ss_x=2.0, ss_y=2.0, strength=30, overshoot=0, undershoot=0, soft=0, edgemode=0) clip3=Trim(source, 25148, 30455).hqdering.Undot().deen("c3d", 0, 5, 5).maa2(ss=3.00).LimitedSharpenFaster(ss_x=2.0, ss_y=2.0, strength=30, overshoot=0, undershoot=0, soft=0, edgemode=0) Return clip1 + clip2 + clip3
Last edited by killerteengohan; 15th Aug 2014 at 18:41.
-
Do you understand what jagabo is saying about why it didn't work the 1st time ?
Code:source=MergeChroma(source, Spline36Resize(360,240).LanczosResize(source.width,source.height ).aWarpSharp2(depth=6))
MergeChroma() takes 2 arguments: MergeChroma(clipa, clipb). But you only specifed clipa as "source". clipb was never specified, and since "last" doesn't exist, you'll get an error
So if you wanted to stick to using source=... way of formatting you would need
Code:source=MergeChroma(source, source.Spline36Resize(360,240).LanczosResize(source.width,source.height ).aWarpSharp2(depth=6))
For the second script, there is a "last" defined, because a clip is actually called with DGDecode_mpeg2source . (ie. it's not in the format source=...) -
-
I've been playing around with a way to protect parts of the picture that don't have rainbow artifacts by building a mask of strong edges in the chroma channels.
Code:function VerticalEdges(clip "clip") { # find vertical edges ConvertToRGB(clip) GeneralConvolution(128, " 0 0 0 1 -1 0 0 0 0 ", 1) ConvertToYV12() # abs(Y-126) Overlay(ColorYUV(last, off_y=-126), ColorYUV(last.Invert(), off_y=-126), mode="add") ColorYUV(off_y=-15) # threshold to remove small changes ColorYUV(gain_y=25000) # blow it out } Mpeg2Source("bmandemuxed1.demuxed.d2v", CPU2="ooooxx", Info=3) src=last vmask = VerticalEdges(VtoY()) # vertical edges in the V channel umask = VerticalEdges(UtoY()) # vertical edges in the U channel emask = Overlay(umask, vmask, mode="add") # add them together emask = emask.PointResize(src.width, src.height) # make the mask the same size as the source emask = emask.mt_expand().GreyScale() # expand the mask pixels # make a very blurry verion of the image to get rid of chroma rainbows BicubicResize(width/4, height/2) # won't work with < mod 8 frame width, < mod 4 frame height BicubicResize(width*4, height*2) aWarpSharp(depth=30) # sharpen it MergeChroma(src,last) # original luma plus blurry chroma # overlay only the blurry chroma where the mask tells us Overlay(src, last, mask=emask) Interleave(src,last,emask) # show original, cleaned, and the mask we used
-
Thanks you two! showing me the second source in red and explaining clipa and clipb helped me to understand it fully now.
As for the mask, Ill give that a try when I get the chance and see if the results are more to my liking than what I used.
Thanks!!