View Full Version : Soothe() - small helper function for sharpening with less temporal jitter
foxyshadis
12th April 2006, 15:12
See Mug Funky's last post, on this page. Also consider using the version I posted. ;)
Oline 61
15th April 2006, 23:37
The output of this script is awesome, but it is extraordinarily slow. Like running pixiedust on a 4096x1920 image. Huffyuv can encode it at ~1.5 fps. Can anyone recommend a way to speed it up?
MPEG2Source("VTS_06_1.d2v",cpu2="ooooxx")
Telecide(guide=1,post=1,back=1)
Decimate()
Crop(2,56,716,362)
LanczosResize(1280,544)
RemoveGrain(mode=1)
dull=fft3dfilter(sigma=1.5)
sharp=LimitedSharpen(dull,
\ ss_x=1.5, ss_y=1.5,
\ dest_x=1280, dest_y=544,
\ Smode=3, strength=115,
\ Lmode=3, edgemode=1)
Soothe(sharp,dull)
krieger2005
16th April 2006, 19:46
@Oline 61: Don't use fft3dfilter. If the speed-improvement is not enought don't use limitedsharpen... and so on ;)
Oline 61
16th April 2006, 20:59
Without fft3dfilter there is no denoising. The output looks horrible because half of what is being sharpened is film grain.
I have tried putting fft3dfilter before the resize, and I think it might just be fast enough that way.
height=1280
width=544
MPEG2Source("VTS_06_1.d2v",cpu2="ooooxx")
Telecide(guide=1,post=1,back=1)
Decimate()
Crop(2,56,716,362)
in=fft3dfilter(sigma=1.5)
dull=LanczosResize(in,height,width)
sharp=LimitedSharpen(in,
\ ss_x=1.5, ss_y=1.5,
\ dest_x=height, dest_y=width,
\ Smode=3, strength=115,
\ Lmode=1, edgemode=1)
Soothe(sharp,dull,32)
foxyshadis
17th April 2006, 02:53
Well, ft3d isn't the only denoiser; for similar results you might try a degrainmedian (or two). Or possibly mipsmooth, but that's harder to control.
Oline 61
17th April 2006, 04:58
DegrainMedian doesn't do all of the things I need. Removing grain is great, but it doesn't clean up the compression artifacts from the DVD like fft3dfilter does. I've got it up to about 2.6 fps for a turbo first pass. That is acceptable. Here is the script:
SetMemoryMax(768)
width=1280
height=544
MPEG2Source("VTS_06_1.d2v",cpu2="ooooxx")
Telecide(guide=1,post=1,back=1)
Decimate()
Crop(2,56,716,362)
in=fft3dfilter(sigma=1.5)
dull=BicubicResize(in,width,height)
sharp=LimitedSharpen(in,
\ ss_x=1.5, ss_y=1.5,
\ dest_x=width, dest_y=height,
\ Smode=3, strength=100,
\ Lmode=1, edgemode=1)
Soothe(sharp,dull)
EDIT: I'ma give LimitedSharpenFaster() a shot too.
audioslave
5th June 2006, 23:59
I'm getting an error when using Soothe(). VDub says:
Script error: There is no function named "yv12lutxy".
What am I missing?
My script
LoadPlugin("C:\Program Files\AviSynth 2.5\plugins\LimitedSupport_09Jan06B.dll")
LoadPlugin("C:\Program Files\AviSynth 2.5\plugins\mt_masktools.dll")
Import("C:\Program Files\AviSynth 2.5\plugins\LRemoveDust.avsi")
Import("C:\Program Files\AviSynth 2.5\plugins\LimitedSharpenFaster.avsi")
Import("C:\Program Files\AviSynth 2.5\plugins\Soothe.avsi")
Mpeg2Source("D:\Hea\Video\DVD\Temp\Temp.d2v")
LRemoveDust_YV12(17,2)
Crop(6,78,710,420)
dull = last.LanczosResize(704,416)
sharp = dull.LimitedSharpenFaster(dest_x=704,dest_y=416)
Soothe(sharp,dull,20)
Addborders(0,80,0,80)
audioslave
6th June 2006, 00:12
I solved it. I didn't have MaskTools in my plugin directory...
HeadBangeR77
20th January 2007, 06:47
I'm just thinking while writing ;) If we resize, we can't write like e.g.:
dull = last
sharp = dull.LimitedSharpenFaster(dest_x=720,dest_y=304)
provided we haven't resized (to our destination resolution) before. That's the mistake iceborne made above in his first script. Then the comparison clip /background (dull) would have a different resolution than the sharpened clip, and the whole function didn't make sense. However, if we write ...
dull = last.LanczosResize(720,304)
than we don't have to specify the resolution arguments in LSF, do we?! I mean sharp = dull + LSF, and dull has already been resized just one line above. So we can write afterwards ...
sharp = dull.LimitedSharpenFaster() ?
How blind & stupid have I been! (bangs his head against the wall :o) If the above is right, then LSF has the destination resolution, instead of the source resolution, as an input. That changes the supersampling effect, though the function's arguments don't change, and thus the sharpening strength too. Could anyone confirm /deny the above? :confused:
If that's true, I've spent all my day just in vain, encoding samples I didn't actually want to encode. :mad: It would rather not matter, if I was downsizing a bit, like in the above examples, but I'm upsizing atm, and that changes a lot ...
Didée
20th January 2007, 07:31
# how to soothe LimitedSharpen when LS is set up to change resolution
dx = your_target_width
dy = your_target_height
base = last.LanczosResize( dx, dy )
shrp = last.LimitedSharpen( dest_x = dx, dest_y = dy )
shrp.Soothe(base)
foxyshadis
20th January 2007, 07:32
sharp = dull.LimitedSharpenFaster(dest_x=720,dest_y=304)
is just a convenience. If you're going to go about resizing everything, you might use
sharp = LimitedSharpenFaster(dest_x=720,dest_y=304)
using implicit Last, or explicitly define an original. Or feed it the resize, LSF doesn't care - it'll work on anything. The worst you'll do is introduce a tiny bit of ringing and slow it down a bit.
HeadBangeR77
20th January 2007, 15:04
# how to soothe LimitedSharpen when LS is set up to change resolution
dx = your_target_width
dy = your_target_height
base = last.LanczosResize( dx, dy )
shrp = last.LimitedSharpen( dest_x = dx, dest_y = dy )
shrp.Soothe(base)
Thank you! :)
That's exactly what I wanted to achieve, but I lacked some basic knowledge about syntax :o The problem was I was going through some "standard" chain of
denoising -> sharpening with LSF -> denoising /another PP
like, for instance:
fft3dgpu(...) -> LSF(... dest_x=target_width, dest_y=target_height ...) -> BlindDeHalo3(PPmode=-3)
Both the first denoiser and LSF worked then with the original DVD resolution (after cropping black bars only), and LSF took care of resizing, as I intented. Supersampling was actually stronger than default, because I was downsizing:
712x360 anamorph -> LSF (supersampling & final resizing) -> 720x304 square pixels
After that, foxyshadis pointed Soothe to me, so I decided to give it a try, and I messed up with resolutions, more or less intentionally ;)
dull = last.LanczosResize(720,304)
sharp = dull.LimitedSharpenFaster(... dest_x=720, dest_y=304 ...)
Soothe(sharp,dull,XX)
Hence LSF was working with resized material already (what I didn't intend), and the SS was a bit different (weaker, but at the actual default *1.5) than in my former samples /clips, and thus the sharpening strength was different too (stronger). In this way I've lost the appropriate comparison, 'cause I had wanted to compare different pre-procesing and post-procesing methods, not the LSF itself. Now, at least the above is clear to me. :) Thanks once again!
HeadBangeR77
20th January 2007, 15:18
sharp = dull.LimitedSharpenFaster(dest_x=720,dest_y=304)
is just a convenience.
As I thought - thanks for clarifying :)
If you're going to go about resizing everything, you might use
sharp = LimitedSharpenFaster(dest_x=720,dest_y=304)
using implicit Last, or explicitly define an original.
That was & is my goal, exactly.
Or feed it the resize, LSF doesn't care - it'll work on anything. The worst you'll do is introduce a tiny bit of ringing and slow it down a bit.
I've already gone through almost all the possibilities, but that wasn't my intend - I wanted the LSF to do exactly the same supersampling, sharpening, and resizing, because I was comparing different pre- and postprocesing methods (see above) ;) I'm upsizing atm, but I won't bother you, until the final script is ready & tested ;) You've been both very helpful, thanks a lot!
HeadBangeR77
22nd January 2007, 02:41
At last I've managed to figure things out, while using LSF and Soothe with different resolutions. Hope someone might find this useful, and if not, I don't think I will bother anyone with this post. ;)
1) Anomorphic encode
There's not much to say really, 'cause this is the easiest case. We always work with unchanged resolution, using the simpliest Soothe like in the opening post:
dull = last
sharp = dull.LimitedSharpenFaster(...)
Soothe(sharp,dull,XX)
Supersampling between 1.25 and the default 1.5 seems to do the best job for me.
2) Downsizing
IMHO we should try to work and process the untouched (with the exception of cropping) material as long as it is possible. In this way LSF can enhance some details, that could potentially disappear due to resizing, and might be preserved after beeing sharpened properly. Hence my questions a few posts above. LSF takes care of resizing then, e.g.:
base = last.LanczosResize(720,304)
sharp = last.LimitedSharpenFaster(... dest_x=720,dest_y=304 ...)
sharp.Soothe(base,XX)
SS between 1.25 and 1.5 works best for me, though while downsizing one could lower the SS-factor. LSF works with higher resolution, and downsizes at the end, so the real SS is actually bigger than defined (or left at default).
3) Upsizing
I've been upsizing recently, achieving some decent results. Using the 2nd method and letting LSF take care of final resizing was my first guess. I had to use SS 2.0 in such a case, 'cause the default x1.5 wouldn't suffice, e.g.:
base = last.LanczosResize(1024,432)
sharp = last.LimitedSharpenFaster(ss_x=2.0,ss_y=2.0,dest_x=1024,dest_y=432,strength=100)
sharp.Soothe(base,80)
I decided later to try the basic way (the one I didn't want to use once, 'cause I was comparing samples that had to be done the same way) and resize before sharpening:
dull = last.LanczosResize(1024,432)
sharp = dull.LimitedSharpenFaster(ss_x=1.5,ss_y=1.5,dest_x=1024,dest_y=432,strength=100)
Soothe(sharp,dull,80)
The resulting clip was not only a bit sharper, but also had more "stability" (less nervous sharpening, no jittering or whatever it's called in this barbarian language ;)), though I used exactly the same Soothe settings. Having encoded and compared many samples I would recommend the last method, if someone is upsizing. In terms of speed it's the same (higher resolution to work with, but lower supersampling needed), in terms of quality it's imho better, "unless my eyes are cheated by some spell". ;)
PS. Don't worry, I'm not gonna post guides like J.D. :D
Didée
22nd January 2007, 03:29
though while downsizing [...] the real SS is actually bigger than defined
... and vice versa for upsizing.
In all the time LimitedSharpen has been around, I've been waiting for a suggestion like "make the ss factors relative to the _output_ resolution instead of input res." to come up.
Well, I'm patient. :)
HeadBangeR77
22nd January 2007, 03:46
(...)
In all the time LimitedSharpen has been around, I've been waiting for a suggestion like "make the ss factors relative to the _output_ resolution instead of input res." to come up.
Well, I'm patient. :)
Having very limited knowledge as to AviSynth, I've lernt all of that on my own errors (+ some helpful suggestions from some folks around here, but I can't recall their names so late at night ;)).
In case you're still waiting for suggestions, let me be the first to say:
Please, could you make the ss factors relative to the output instead of input resolution? Because the way it is now it's causing noobs like me a hard time, while working with different resolutions. :)
Didée
22nd January 2007, 03:57
In case you're still waiting for suggestions, let me be the first to say:
Please, could you make the ss factors relative to the output instead of input resolution? Because the way it is now it's causing noobs like me a hard time, while working with different resolutions. :)
Hey hey - that's a small but brilliant idea! I really should've thought of that myself! :D
It'll be included in the next version - whenever that might be.
Soulhunter
22nd January 2007, 14:38
In all the time LimitedSharpen has been around, I've been waiting for a suggestion like "make the ss factors relative to the _output_ resolution instead of input res." to come up.
I always thought it would be like this... ss factor = ss of the filtering... which is done on the upsized image... isnt it? If not 2x ss + 200% upsize = no ss... >.>
Bye
HeadBangeR77
22nd January 2007, 15:03
I always thought it would be like this... ss factor = ss of the filtering... which is done on the upsized image... isnt it?
As I undestand the matter, and finally I think I do understand, you're quite right. You feed LS(F) with input clip of certain input resolution, it upsizes the input resolution * supersampling factor, shapens the upsized image, downsizes to the output resolution, when specified.
If input resolution = output resolution, then the SS factor always works as specified (e.g. 1.5x, 2x).
In case of different input and output resolutions, well, just see my posts above: while downsizing or upsizing the real SS factor changes, and so the strength of sharpening. When Soothe is used, it gets things even more complicated (at least for me, though it's the past already ;)).
@ Didée
You are truely a gentleman and a scholar - may Freyja (http://en.wikipedia.org/wiki/Freya) and Freyr (http://en.wikipedia.org/wiki/Freyr) bless you! :D ;)
Didée
22nd January 2007, 15:18
I always thought it would be like this... ss factor = ss of the filtering... which is done on the upsized image... isnt it? If not 2x ss + 200% upsize = no ss... >.>
If things always would be like they should be, then I'd be a rich man. ;) - Alas, the world isn't perfect.
Looking into the LS script, there is
xxs = round(ox*ss_x/8)*8
yys = round(oy*ss_y/8)*8
where ox,oy are the original input resolution, ss_x,ss_y the factors, and xxs,yys are the resolution of the supersampled image. Obviously, the base is the original resolution ...
In english: when you're working with ss factors of 1.5, but you tell LS to make the output resolution 2x that of the input, then LS actually is doing the sharpening on a smaller framesize than that of the output. :)
It has ever been like that.
Soulhunter
22nd January 2007, 20:49
Oh, never noticed this... ^^;
Then I gonna replace "ox*ss" n' "oy*ss" with "dest_x*ss" n' "dest_y*ss" or what it was!
Thx n' Bye
R3Z
24th January 2007, 08:10
Pictures
Basic (http://www.slibe.com/fullimage/7e1b9c01-Basic.png)
Seesaw using Soothe (http://www.slibe.com/fullimage/7b1c7714-Deluxe_Seesaw.png)
Are you comparing the original to seesaw ? or the seesaw to the limited sharpen+soothe ?
:o
Jeremy Duncan
24th January 2007, 23:59
Didée,
If you made a version of Soothe that uses MT_Masktools instead of Masktools.Would it be faster ? :)
Didée
25th January 2007, 00:39
With Soothe at 100, it's the same as not using Soothe.
This is using FFDshow.
http://img253.imageshack.us/img253/7917/sootheresults3tn.png (http://imageshack.us)
This is Avisynth -> Vdub -> Xvid(q2) of "Soothe(sharp,orig,X)".
Didée
25th January 2007, 00:41
If you made a version of Soothe that uses MT_Masktools instead of Masktools.Would it be faster ? :)
It's already out there, somewhere ... IIRC foxyshadis once did the major effort of replacing all "XXX()" with "mt_XXX()". Search.
Adub
25th January 2007, 03:04
The version is on page 3 of this thread.
Hear is the direct link if you are lazy.
http://forum.doom9.org/showthread.php?p=784366&highlight=Soothe+Masktools+2.0#post784366
foxyshadis
25th January 2007, 03:50
I think he's wondering if Didée's magic touch will make it faster than the bad results he got with the existing version.
HeadBangeR77
25th January 2007, 04:10
@ Jeremy D.
Maybe I've written too much about LimitedSharpen(Faster) in this thread, but that was connected with Soothe, and because of Soothe I had come across all the above resizing & supersampling differences. Could you stop posting your various settings, which tend to change few times a day, in every thread connected with Didee's functions? You've got your own thread(s) already, and you're making many others non-transparent in this way, not to mention it's slowly getting irritating ... Savvy?
Boulder
25th January 2007, 10:19
Didée, and Foxyshadis, might want to see what people have done with their work.
I know what it's like to see a new post in my thread, so I like to add nice stuff, what I think is nice, to other peoples threads.I think Didée has asked you quite a few times to stop messing around with his functions. OK, it's nice to let people know what you've achieved with them but IMHO you are creating confusion among those who might not understand what's going on. Besides, you don't seem to understand that the optimal settings depend entirely on the source - and that's probably one reason why you post a new version every day or so.
Note that I don't mean to hurt your (or anybody else's) feelings, I'm just getting a bit tired of cluttered threads.
Jeremy Duncan
25th January 2007, 16:19
I think Didée has asked you quite a few times to stop messing around with his functions.
I can only remember the time I chopped up his Spresso code.
After I deleted the changed code he was not angry anymore.
:search: :thanks:
Boulder
25th January 2007, 17:03
I can only remember the time I chopped up his Spresso code.
After I deleted the changed code he was not angry anymore.
:search: :thanks:http://forum.doom9.org/showthread.php?p=934080#post934080
What I mean is that people are encouraged to do quite the incorrect things with the functions. I know Didée doesn't like that much, and considering the fact that he's done a lot for the Avisynth community, I'd really listen to his advice:)
EDIT: I hope that "casting pearls before the swine" isn't directed at me :p
Jeremy Duncan
25th January 2007, 21:48
Merlin7777,
No, I googled it and found it myself.
foxyshadis,
The version you made is nice.
HeadBangeR77,
You must understand.
Didée, and Foxyshadis, might want to see what people have done with their work.
I know what it's like to see a new post in my thread, so I like to add nice stuff, what I think is nice, to other peoples threads.
I'm sorry I'm aggravating you.
Here's what I've done with Seesaw, LSF, and Soothe.
I made one with Soothe and LSF, just so you know in case you wanted to see that.
Just download the folder, look at the FFDshow configurations and compare the pictures;
Pictures showing the Detail quality of the different configurations. Updated January 25, 2007 (http://rapidshare.com/files/13370518/Detail_Tests.zip.html)
The rules say there is no best, Boulder.
What you linked to in no way makes my work with Didée's stuff ant less important than the fine stuff anybody else has done with it.
Because there is no best according to the rules.
Didée is happy that I'm happy with the results.
That's all that's important.
In case your wondering why I keep deleting my posts. I'm scared I'm going to get the lash if I have more than one post in this thread.
HeadBangeR77
26th January 2007, 01:32
In case your wondering why I keep deleting my posts. I'm scared I'm going to get the lash if I have more than one post in this thread.
Fine for me, 'cause I've read through this thread several times, but from an objective point of view you're making it even less transparent now. If I was to search for some important info for the first time, I would get a headache, seriously :D
Could someone soothe (;)) this thread, so it does make sense again?
foxyshadis
26th January 2007, 17:49
No, mods don't sweep up threads, except to clean up flamewars or occasionally to update a badly out-of-date first post. The best route is to create an entirely new thread with as much pertinant information in the post as possible. I'm beginning to warm to the idea of a FAQs forum, at least as long as the wiki is down/readonly. (Although the soothe entry is live.)
HeadBangeR77
27th January 2007, 14:54
With Soothe at 100, it's the same as not using Soothe.
This is using FFDshow.
http://img253.imageshack.us/img253/7917/sootheresults3tn.png (http://imageshack.us)
This is Avisynth -> Vdub -> Xvid(q2) of "Soothe(sharp,orig,X)".
If I'm becoming a real pain in the ass, then just tell me straight. :D
Although I must admit that using Soothe(s,d,100) isn't the same as not using Soothe at all (yes, I've made some samples), one thing here troubles my mind: Since
"keep" is an integer, range 0 - 100, that tells how much percent of the original sharpening will be kept at least,
then
orig.avi < soothe(-100) < soothe(100) < sharp.avi
is correct. Soothe always soothes, even if we tell her to stop. ;) On the other hand, even with negative values, the function will never fully undo the sharpening effect. Why then soothe(15) > soothe(100) ??? This is too much for my exhauste humanistic brain. :confused:
Didée
29th January 2007, 13:13
Oh, oh-oh ... that's because I used the Soothe function of SeeSaw, which has the parameters inversed (in SeeSaw the meaning is not "keep", but rather "strength") ... Standalone Soothe doesn't even use "negative" values.
In this respect, it's all a big mess with Soothe. Agreed. :D
Worse is, that I shouted at Jeremy without a reason: When using the Standalone function of Soothe, then Soothe(100) in fact IS THE SAME as not using Soothe ... Jeremy was right, and I stumbled in my own trap. :devil:
HeadBangeR77
29th January 2007, 14:32
Thanks for clearing, now I get it. ;) A true genious is always a bit absent-minded, isn't he? :D
OT: Is Soothe (function) he/ she/ or it in english? The problem with this simplified-long-forgotten-anglo-saxon-bad-pronounced-latin-distorted-french-language is, that almost noone teaches grammatical genders, so I don't have the flexibility I've got in german or in polish. :p
McCauley
27th March 2007, 01:53
Hi,
at first i have to thank you for your great filters Didée!
I played with Soothe and asked myself how it would be possible to use use soothe in combination with the inbuild resizer of LSF.
I after hours of thinking how it could work, i came up with this idea:
MPEG2Source("whatever.d2v")tfm()tdecimate().removegrain().crop(whatever)
dull = last
sharp = dull.LimitedSharpenfaster(ss_x=1.0,ss_y=1.0,Smode=3,strength=XXX)
Soothe( sharp, dull, 30 )
Lanczos4Resize(1280,720)
After that thought why not reading the entire Soothe-Thread and found your suggestion for resizing:
# how to soothe LimitedSharpen when LS is set up to change resolution
dx = your_target_width
dy = your_target_height
base = last.LanczosResize( dx, dy )
shrp = last.LimitedSharpen( dest_x = dx, dest_y = dy )
shrp.Soothe(base)
My question is now, if my script delivers (theoretically) better quality, because im soothing at the full resolution (source is 1920x1080) and lanczos resize it at the end to the destined resolution (which is the same, because i just externalized the last resizing step of LS(F), or not?), or is it just a waste of cpu cycles?
Regards
McCauley
EDIT:After some addititonal toying with it, i realized that i make sharpening a bit useless with the first one and found these settings satisfiing:
MPEG2Source("whatever.d2v")tfm()tdecimate().removegrain().removegrain().crop(whatever)
dull = last.Lanczos4resize(1280,720)
sharp = dull.LimitedSharpenfaster(ss_x=1.0,ss_y=1.0,Smode=3,strength=XXX,dest_x=1280, dest_y=720)
Soothe( sharp, dull, 30 )
My thoughts to that are that using supersampling with 1.5 at a full HD makes the sharpening obsolete, if you resize it down to 1280x720.
251121
14th July 2007, 03:46
can some give me direct link to download what exactly needs to have in avisynth plugins folder in order to work with this filter. many thanks.......
TheRyuu
14th July 2007, 05:51
can some give me direct link to download what exactly needs to have in avisynth plugins folder in order to work with this filter. many thanks.......
Sure.
function Soothe(clip sharp, clip orig, int "keep")
{
Assert(sharp.width == orig.width && sharp.height == orig.height,
\ "Soothe: clip dimentions must match!")
keep = default(keep, 24)
keep = (keep>100) ? 100 : (keep<0) ? 0 : keep
KP = string(keep)
diff = mt_makediff(orig,sharp)
diff2 = diff.temporalsoften(1,255,0,32,2)
diff3 = mt_lutxy(diff,diff2, "x 128 - y 128 - * 0 < x 128 - 100 / " + KP
\ + " * 128 + x 128 - abs y 128 - abs > x " + KP
\ + " * y 100 " + KP + " - * + 100 / x ? ?")
return( mt_makediff(orig,diff3,chroma="copy first") )
}
Copy and paste into text file, save as Soothe.avsi, put that in plugins folder.
Get mt_masktools v2 here. (http://manao4.free.fr/) (latest one is this one. (http://manao4.free.fr/masktools-v2.0a30.zip)) Throw that in plugins folder too.
Not sure if this one needs removegrain. :p (don't think so, anyone?)
Boulder
14th July 2007, 08:46
Yes, MaskTools v2 should be the only external dll that is needed.
251121
14th July 2007, 17:09
Sure.
function Soothe(clip sharp, clip orig, int "keep")
{
Assert(sharp.width == orig.width && sharp.height == orig.height,
\ "Soothe: clip dimentions must match!")
keep = default(keep, 24)
keep = (keep>100) ? 100 : (keep<0) ? 0 : keep
KP = string(keep)
diff = mt_makediff(orig,sharp)
diff2 = diff.temporalsoften(1,255,0,32,2)
diff3 = mt_lutxy(diff,diff2, "x 128 - y 128 - * 0 < x 128 - 100 / " + KP
\ + " * 128 + x 128 - abs y 128 - abs > x " + KP
\ + " * y 100 " + KP + " - * + 100 / x ? ?")
return( mt_makediff(orig,diff3,chroma="copy first") )
}
Copy and paste into text file, save as Soothe.avsi, put that in plugins folder.
Get mt_masktools v2 here. (http://manao4.free.fr/) (latest one is this one. (http://manao4.free.fr/masktools-v2.0a30.zip)) Throw that in plugins folder too.
Not sure if this one needs removegrain. :p (don't think so, anyone?)
first of all thanks, can u tell what version? i need to download because there are so many v2 versions :confused: Thanks...
Thanks to Boulder as well.
Boulder
14th July 2007, 18:06
Just download the latest MaskTools v2 version and you're fine.
Prim3
15th July 2007, 02:19
Very nice function Didée. I've got an extraordinary output using it. Great job.
Vesi
23rd October 2007, 12:04
Any help, how i have to use soothe and LSF with this script?
i'm using megui to make my script.
@ should i call soothe avs or avsi in my plugin dir?
DGDecode_mpeg2source("C:\Documents and Settings\Vesi\Desktop\HDDCS-Test\Test.d2v",info=3)
ColorMatrix(hints=true,interlaced=true)
#Not doing anything because the source is progressive
crop( 2, 92, -2, -72)
BicubicResize(640,272,0,0.5) # Bicubic (Neutral)
salehin
23rd October 2007, 14:50
Any help, how i have to use soothe and LSF with this script?
i'm using megui to make my script.
@ should i call soothe avs or avsi in my plugin dir?
DGDecode_mpeg2source("C:\Documents and Settings\Vesi\Desktop\HDDCS-Test\Test.d2v",info=3)
ColorMatrix(hints=true,interlaced=true)
#Not doing anything because the source is progressive
crop( 2, 92, -2, -72)
BicubicResize(640,272,0,0.5) # Bicubic (Neutral)
Just rename the soothe.avs to soothe.avsi and drop it in your avisynth plungins directory. That would allow your avs script to access and work soothe.
Also check here (http://forum.doom9.org/showpost.php?p=1056555&postcount=3) whether you actually require colorcorrection or not (i doubt it is required)
Vesi
23rd October 2007, 22:28
Thanks alot salehin, i have few questions.
1.how do i know that my source is rec 709, and i don't need colorcorection?
2.o Resolution: Always use mod16 resolution for your output?
please make it a bit clear, coz i'm new:)
o Always start off with using the least powerful sharpening filters. The idea is bring out background details slightly clear without introducing artificial sharpening. LSF (the customised one), Soothe comes my mind - see intro and an example of settings
the links you provided for some details here is not working.
foxyshadis
23rd October 2007, 22:56
DGIndex and the d2v has that information. If it doesn't, colormatrix won't do anything with hints=true, don't worry. (Never use it if you're making a DVD from a DVD, though, unless you change the colormatrix in your encoder's advanced settings.) Mod16 isn't required, but it's preferred unless you have to really go out of your way to get it.
salehin
23rd October 2007, 23:56
Thanks alot salehin, i have few questions.
1.how do i know that my source is rec 709, and i don't need colorcorection?
2.o Resolution: Always use mod16 resolution for your output?
please make it a bit clear, coz i'm new:)
the links you provided for some details here is not working.
o Colorimetry:
Load the source file onto DGIndex (version 1.4.9+) and do a preview. You'll find the colorimetry (http://forum.doom9.org/showpost.php?p=1056555&postcount=3) info there. Always use AvsP (http://forum.doom9.org/showthread.php?t=129385) for previews to be more certain (with and without CM). It gives a very good preview- impacts of using various filters.
o Detailed reason behind mod16 (quoting check):
Encoders work in blocks of 16x16. They can subdivide into smaller blocks below this (16x8, 8x8 and 4x4), but the encoder requires 16x16 blocks. If the size is not mod16, the encoder will simply duplicate the edge pixels, encode those instead and the decoder will not display them on playback.
Instead of encoding non-mod16, resize to mod16 and set the correct AR in the matroska file. Then you have the correct AR and a more compressible movie
o LSF and Soothe:
I have updated the links (http://forum.doom9.org/showpost.php?p=1032304&postcount=623) (re: LSF and soothe eg)
o Resize filter:
May I also suggest you try Spline36neutral or Lanczos (Sharp). I tend to prefer spline36neutral as it gives as good results as lancsoz sharp, in some cases, slightly better than Lanczos (Sharp)
Vesi
24th October 2007, 10:34
foxyshadis and salehin thank you guys for the replays.
- I did open my source with DGIndex and found it BT.470-2 B,G, so in this case i don't need colorcorection, am i right?
@ salehin please don't get angry on me :), i releay don't get this mod16, should i change this in megui before i start my rip?
please explain it in some simple words as i'm noob and bad english :o.
is this the right way to make script soothe with LSF?
dull = last
sharp = dull.LimitedSharpenfaster( ss_x=1.25, ss_y=1.25,smode=4, strength=150, overshoot=1 )
Soothe( sharp, dull, 20 )
Tweak(sat=1.2,bright=-8,cont=1.3)
Or any other ways too?
vBulletin® v3.8.11, Copyright ©2000-2026, vBulletin Solutions Inc.