View Full Version : MSmooth for Avisynth 2.5
Guest
25th January 2003, 02:51
Here is MSmooth 2.0 beta 1 for Avisynth 2.5. It is a detail-constrained spatial smoother as described in the original discussion thread:
http://forum.doom9.org/showthread.php?s=&threadid=31679
Of course it is not yet optimized for speed as I am just now resurrecting its development. It does however support both RGB32 and YV12. Please see the help file for usage details and the original thread for discussion.
MrBunny
26th January 2003, 05:59
Hi Donald,
Just a quick question or possible bug. When I'm using the strength parameter the speed drops a lot. I know in the readme, you state that it would, but what I'm finding is that there's a large difference (13 vs 3fps) when I do:
Msmooth(threshold=11) -> 13fps
vs
Msmooth(threshold=11,strength=3) -> 3fps
Since strength=3 is the default (according to the readme), I would assume they should be the same speeds. I can only get the same speeds while including the strength parameter when using strength=0. Do you have any ideas on this?
Thanks,
Mr. B
Guest
26th January 2003, 07:14
My testing shows identical timings and the code is definitely defaulted to strength=3. I can think of only two possibilities: 1) you have an msmooth.def that overrides the defaults, or 2) you just did things late at night and got confused. :-)
But seriously, are you sure??? When you leave off the strength parameter are you getting smoothing (strength=0 passes the video through untouched)?
MrBunny
27th January 2003, 07:13
Thanks for the reply Donald. I still can't explain it's behavior, and I don't see a msmooth.def anywhere, nor have i tried to modify the defaults. I can confirm that it is doing strength=0 by default. However, I have checked with some other people and it seems just to be something in my setup as you had said :) I guess I can deal with manually typing in the strength until I figure it out.
Thanks again,
Mr. B
FuPP
28th January 2003, 23:54
@Neuron
2 things about latest msmooth :
- high value for strength seem to strangely affect chroma
- high threshold seem to show a problem with borders
3 pictures (see attached file)
pic0 : strenghth = 2, threshold = 2
pic1 : strenghth = 25, threshold = 2
pic2 : strenghth = 25, threshold = 200
my script :
-----------
LoadPlugin("C:\video\avsfilters\yv12\MPEG2Dec3.dll")
LoadPlugin("C:\video\avsfilters\yv12\Msmooth.dll")
mpeg2source("F:\test\vts_01.d2v",cpu=0,idct=2)
Crop(20,72,680,432)
msmooth(strength=25,threshold=200)
bicubicresize(448,320,0,0.6)
AddBorders(16,128,16,128)
Regards,
FuPP
Guest
29th January 2003, 01:19
@FuPP
Thank you for your feedback.
A blur cannot be applied at the edges because neighboring pixels are unavailable, so I copy them over from the source. For reasonable strengths (not 25!), you don't notice it.
I don't get your chroma point.
But anyway, suppose I said:
"Noticed problems with my car. With high RPM (20000 rpm) the engine gets real hot. With watered down gas, the engine runs rough." :)
Why in heaven's name would you want to run MSmooth with a strength of 25 and/or a threshold of 2 (or 200)?
FuPP
29th January 2003, 09:53
I allways do that kind of tests in order to accentuate consequences of a possible bug, which are sometimes less noticeable with default or soft settings.
These settings are therefore only for testing purpose.
about chroma :
I've just realised that pictures I attached are in the wrong order compared to the description I gave :
pic0 (=msmooth0.jpg) : strenghth = 2, threshold = 2
pic1 (=msmooth2.jpg): strenghth = 25, threshold = 2
pic2 (=msmooth1.jpg): strenghth = 25, threshold = 200
if you compare msmooth0 and msmooth2, you should see that picture msmooth2 is more "green"
Regards,
FuPP.
lamer_de
29th January 2003, 13:00
I notice the "green-shift", but I notice aswell that these are two pictures with different horizontal resolutions. And they show a different content aswell :P
IMHO you can make decisions easier when you use the same source/picture.
Haven't made tests for myself yet, so I can't confirm nor deny anything.
CU,
lamer_de
Guest
29th January 2003, 13:57
I can't duplicate your chroma result. Please provide a one-frame HUFYUV clip that demonstrates the alleged problem.
I think my car has a bug. When I drove it into a wall (just to test for possible bugs), it stopped working! :)
FuPP
29th January 2003, 14:24
ok, forget it; I'm going to drive another car. :)
Best regards,
FuPP.
digitize
20th February 2003, 01:24
When I used msmooth the video had a small green tint to it (anime). But it did clean up the raw well.
Guest
20th February 2003, 01:39
Maybe you can provide a one-frame clip for me to download that I can use to see the problem? FuPP gave up on me. :(
Was your source RGB or YV12?
Also please post the script.
Thank you.
digitize
20th February 2003, 02:07
Actually, now that i look at it, it was the source with the greenish tint and not caused by msmooth. Also neuron2, i was wondering if there was going to be more developement on this filter, specifcally with speed.
Guest
20th February 2003, 02:22
@digitize
Thank you for the clarification. One thing people need to realize is that with high strengths the radius of the smoothing kernel is large. So if the edge masking doesn't catch all of the edges, the parts of the edges not masked can bleed quite far into the smoothed areas. It is not a bug, just something to be aware of if you want to use high strengths. Generally, strength of 5-7 or below should be more than enough. And if you really want higher strengths, then be a little more conservative with the edge masking (lower threshold).
I do plan to work more on MSmooth but I am just about to leave for a month-long vacation to Pondicherry, India, so not much will happen until the end of March.
digitize
20th February 2003, 02:25
@neuron2
I hope you enjoy your vacation. And yeah, i don't use too high of a threshold/strength, too much detail is lost when doing so.
droolian01
20th February 2003, 03:06
@ neuron2
I've only just 'gone over' to avisynth 2.5, vdubmod and yv12 colourspace - and am impressed with the speed increase
But.... i was wondering if you had any plans to make msharpen handle yv12 colourspace natively (i use converttoyuv().mssharpen(xxxx).convertbacktoyuv() )
Thanks again for your filters and enjoy your trip
droolian
Guest
20th February 2003, 03:10
Yes, but that really belongs in the MSharpen thread. :)
ObiKenobi
2nd September 2004, 21:30
Any idea when a speed optimized version will be coming out? It's been a while since you released the 2.0 beta1 and was just curious if you were still working on it. Thanks.
PhillipWyllie
14th May 2005, 20:00
When "mask" is set to true, what do the colours mean? I assume the darker green means not preserved.
Oh and thanks for the filter(s).
Guest
15th May 2005, 00:53
The different colors are an artifact of YV12 space. The background green color is the smoothed area. Any other color is preserved from smoothing. Typically, it is the edges in the picture that are preserved. If you convert to RGB, the map will be all black and white.
vBulletin® v3.8.11, Copyright ©2000-2026, vBulletin Solutions Inc.