View Full Version : Anime clean up
gavo
25th December 2005, 21:53
Hey, I recently filtered a anime music video for a friend. He only had the actual mpeg and not the project or the raw which made it difficult. I so how pulled of a decent encode, however know I lost the script in a reformat :angry: . Anyways I tryed to remodel the script and no luck.
ConvertToYV12()
Tweak(bright=5, cont=.95, sat=1.4, hue=0, coring=false)
Levels(0, 1.1, 255, 0, 255)
hqdn3d(2)
awarpsharp
crop(8,0,-4,0)
sharpResize(720,480)
Here is a sample of the video (http://d55.yousendit.com/F/1EB31S0VS1P1V2C8E90JOW7O5V/test.mpg) , if someone could remodel or do the script that would be so much appericated. :script:
gavo
27th December 2005, 19:43
Can someone please give me a hand.
DryFire
27th December 2005, 20:03
you're resizing a 352x240 video to 720x480?
Why?
Chainmax
27th December 2005, 20:07
I'll try to give it a go soon. What can you tell me in advance about it?
gavo
29th December 2005, 02:08
Will sorry, I not trying to resize back i'm leaveing it as is. It was dvd source, then he used mjpeg to edit and exported as mjpeg and then used vdub to cut of the mjpeg logo. :mad: He not a codec guy :sly:. If you got any other questions feel free to post thanx again Chainmax it very much appericated.
DryFire
29th December 2005, 02:34
I wasn't trying to be mean or anything just wondering.
I got something that was remotely watchable useing the following:
# apparently I forgot to decimate the source down to 23.976 fps, I'd
#suggest:
#tdecimate(mode=1)
DirectShowSource("C:\Documents and Settings\Marc\Desktop\test.mpg")
converttoyv12()
degrainmedian(mode=1)
removegrain(mode=17)
fluxsmoothst()
hqdn3d(2)
ffdshow("default") #spp deblocking about %28-%36 strength
crop(8,0,-4,0)
lanczos4resize(720,480)
awarpsharp(depth=24, blurlevel=4)
removegrain(mode=18)
fluxsmoothst()
It's still kind of blurry and a good amount of detail was lost. It's the first filterset that came to mind really. I'm sure there's a better way to do it, but I don't do a lot of upsizing.
Here's the sample recompressed w/ x264 revision 389 at 700kbps:
http://www.badongo.com/vid.php?file=AMV+cleanup__2005-12-28_CleanupTest.mp4
gavo
29th December 2005, 08:56
No no, I totually apperciated your help Dryfire that was a error ( the resizeing) on my part. Sorry, Seems very blurring ya but clean :) , that script was so prefect I wish I never lost it, :mad: O well, Maybe I make something better, going to keep playing around, If you could Do another try on the script Dryfire that would be most appericated. thanx again
-Gavin
Chainmax
31st December 2005, 00:24
I think I managed to remove pretty much all blocking. I'll post an encode soon.
gavo
31st December 2005, 00:37
thanx appericated, If you could possibley post the whole encode, or send the encode to me or show the scirpt that would be most appericated thanx again.
-Gavo
*.mp4 guy
31st December 2005, 13:54
Heres my script:
LoadPlugin("D:\Media\Plugins\SmoothD.dll")
LoadPlugin("D:\Media\Plugins\WarpSharp.dll")
LoadPlugin("D:\Media\Plugins\MipSmooth.dll")
Import("D:\Media\Plugins\LimitedSharpen().avs")
AviSource("D:\Cleanup\Uncompressed.avi")
FFdshow("Deblock2")#SPP Deblocking at strength 15 with soft threshold
FFdshow("resize")#spline resize to 720*480
smoothd(2)
MipSmooth()
FFdshow("Deblock")#SPP Deblocking at strength 25 with soft threshold
Warpsharp()
LimitedSharpen()
WarpSharp()
LimitedSharpen(lmode=2)#this is optional and adds a bit of sharpness in the background
#LimitedSharpen(lmode=2)#this is optional and adds a bit of sharpness in the background
Heres an encoded sample:Test (http://rapidshare.de/files/10151644/test.mp4.html)
the raw script output is imo a lot better then that.
MOmonster
31st December 2005, 17:21
And another script from me. :) deblock()
eedi2().turnleft().eedi2().turnright()
a = repair(last.deen("a2d",1,9,11), last.deen("a2d",1,9,11).unfilter(-60,-60),2,1,1)
mask = YV12lUTxy(last, a, yexpr="y x < 0 255 ?", uexpr="x", vexpr="x")
maskedmerge(a,last,mask)
deen("a2d",4,5,7)
ttempSmooth()
repair(last, last.unfilter(-44,-44),1,1,1)
deen("a3d",2,3,7)
#sharping + cropping + second resizing Slow, not so optimized and a bit washed, but the result looks not so bad.
gavo
31st December 2005, 23:54
There all are for very smooth, I not to concerned about the artifacts I just want the sharpness to see be there. It hard to do I know. It just seems whatever you do you oversmooth it. Hmmm Still very nice job but I dont know what to do about this oversmoothness
*.mp4 guy
1st January 2006, 02:16
So you just want it to be sharp. Ok, then try these scripts.
A bit sharper:
LoadPlugin("D:\Media\Plugins\SmoothD.dll")
LoadPlugin("D:\Media\Plugins\WarpSharp.dll")
LoadPlugin("D:\Media\Plugins\MipSmooth.dll")
Import("D:\Media\Plugins\LimitedSharpen().avs")
AviSource("D:\Cleanup\Uncompressed.avi")
smoothd(1)
FFdshow("resize")#spline resize to 720*480
smoothd(1)
MipSmooth()
Warpsharp()
smoothd(1)
LimitedSharpen()
WarpSharp()
LimitedSharpen(lmode=2)
MipSmooth()
Warpsharp()
WarpSharp()
LimitedSharpen(lmode=2)
A lot Sharper:
LoadPlugin("D:\Media\Plugins\SmoothD.dll")
LoadPlugin("D:\Media\Plugins\WarpSharp.dll")
LoadPlugin("D:\Media\Plugins\MipSmooth.dll")
Import("D:\Media\Plugins\LimitedSharpen().avs")
AviSource("D:\Cleanup\Uncompressed.avi")
FFdshow("resize")#spline resize to 720*480
smoothd(1)
MipSmooth()
Warpsharp()
smoothd(1)
LimitedSharpen()
WarpSharp()
LimitedSharpen(lmode=2)
MipSmooth()
Warpsharp()
LimitedSharpen()
WarpSharp()
LimitedSharpen(lmode=2)
MOmonster
1st January 2006, 12:49
Just a small change gives the output a good sharpnessdeblock()
eedi2().turnleft().eedi2().turnright()
a = repair(last.deen("a2d",1,9,11), last.deen("a2d",1,9,11).unfilter(-60,-60),2,1,1)
mask = YV12lUTxy(last, a, yexpr="y x < 0 255 ?", uexpr="x", vexpr="x")
maskedmerge(a,last,mask)
deen("a2d",2,5,7)
ttempSmooth()
repair(last, last.unfilter(-33,-33),1,1,1)
deen("a3d",2,3,7)
LimitedSharpen()
#maybe also fastlinedarken + cropping + resizing
Chainmax
1st January 2006, 20:17
How about this ( http://www8.rapidupload.com/d.php?file=dl&filepath=11107)?
foxyshadis
2nd January 2006, 03:00
(OT) Momonster, thanks for the idea. I just used:
deblock()
eedi2().turnleft().eedi2().turnright()
lanczosresize(width/2,height/2)
on this horrific Cinepak (gag) music video, and it looks amazing! Slooooooooooow but awesome. I still have to throw random other filters on top but it's a great base. I'm going to have to get the others off my ozzy CDs now!
Chainmax
2nd January 2006, 13:40
Here's my script:
SetMemoryMax(Yourmem/2)
LoadPlugin("X:\wherever\CNR2.dll")
LoadPlugin("X:\wherever\MaskTools.dll")
LoadPlugin("X:\wherever\DCTFilter.dll")
LoadPlugin("X:\wherever\DGDecode.dll")
Import("X:\wherever\DeBlock_QED.avs")
LoadPlugin("X:\wherever\SSETools.dll")
LoadPlugin("X:\wherever\RemoveGrain.dll")
LoadPlugin("X:\wherever\Repair.dll")
Import("X:\wherever\LRemoveDust.avs")
LoadPlugin("X:\wherever\EEDI2.dll")
LoadPlugin("X:\wherever\aWarpSharp.dll")
Import("X:\wherever\LimitedSharpen_(modded-27Nov2005).avs")
DirectShowSource("X:\wherever\test.mpg",fps=29.97,audio=false)
ConvertToYV12()
Cnr2("xxx",4,5,255)
Levels(0,1.1,255,16,235)
DeBlock_QED()
LRemoveDust_YV12(17,2)
Crop(8,0,-4,0)
TurnRight().EEDI2().TurnLeft()
EEDI2()
Lanczos4Resize(720,480)
ffdshow("default") <-- go to "video decoder configuration", enable postprocessing, check "SPP deblocking" and set processing strength at 60%
aWarpSharp(depth=16,cm=1)
LimitedSharpen(SMode=4,LMode=3,Strength=300,wide=true)
If you want more sharpness, you can add an extra sharpening step (MSharpen, WarpSharp like it's been recommended here) right after the cropping, and/or substitute Lanczos4Resize for GaussResize(720,480,p) with p set to something between 80 and 100. If you do that, you might also want to change DeBlock_QED from default settings to (quant1=30,quant2=60) or higher, and/or increase SPP's strength by steps of 10%.
As an alternative to LRemoveDust_YV12(17,2), you should try DeGrainMedian(limitY=5,limitUV=7,mode=0), as it might remove more artifacting without taking away so much detail.
vBulletin® v3.8.11, Copyright ©2000-2026, vBulletin Solutions Inc.