Log in

View Full Version : Where to get VD_SmartSmoothIQ()?


ZiGGi
8th February 2008, 19:05
I need VD_SmartSmoothIQ() to use the SmartSSIQ script to try to remove a rainbow effect. I can't seem to find it anywhere.

Do you have a copy?

Thanks.

Wilbert
8th February 2008, 19:54
http://avisynth.org/mediawiki/Shared_functions/VirtualDub_II

ZiGGi
8th February 2008, 21:33
Now I get this message:

http://img338.imageshack.us/img338/7417/crapua4.png

I have VirtualDub on my computer, but I see there's no filters in the filter directory. Is there supposed to be to get this thing working?

:(

Leak
9th February 2008, 03:16
Now I get this message:

http://img338.imageshack.us/img338/7417/crapua4.png
Like it says here (http://avisynth.org/mediawiki/Shared_functions/VirtualDub_I)...


########################################################
# Change VirtualDub_plugin_directory below to point to #
# the directory containing your VirtualDub plugins. #
########################################################

ZiGGi
9th February 2008, 11:04
I did what you said, and I have this in my script

#################################################################################
# This is a script which works with SSIQ. The basic problem with SSIQ is that
# it can alter the color on the entire picture, which is a very very bad thing.
# All we want to do is remove rainbows, while leaving everything else alone.
# This filter first applies SSIQ to the entire picture. Then it locates the edges.
# Finally, it layers ONLY the de-rainbowed edges onto the orig video.
#
#
# Filter Requirements: VD_SmartSmoothIQ()
#################################################################################
function SmartSSIQ(clip input, int "strength")
{

strength = Default(strength, 255) #processing strength, 0-255

inputrgb = input.ConvertToRGB32()

# apply rainbow remover to the entire video
derainbow = input.ConvertToRGB().VD_SmartSmoothIQ(11, 200, false).ConvertToRGB32()

# create an edge mask from the rainbow video
edgemask = input.Unsharpmask(100).edgemask(0, 255, 255, 255, "sobel").Inflate().GreyScale().Levels(0, 5, 255, 0, 255).ConvertToRGB32()

# create mask
maskedrainbow = mask(derainbow, edgemask)

# now layer the mask onto the input
result = layer(inputrgb, maskedrainbow, "add", strength)

return result
}

SmartSSIQ()

But now I'm stuck with this

http://img525.imageshack.us/img525/6663/54018983wv7.png

Line 54: mode = (mode=="average") ? 0 : (mode=="weighted") ? 1 : -1

Line 68: # # (from below)

###########################################
# Smart Smoother IQ by Tim Park, v0.5 #
# #
# diameter (3-11, odd), threshold (1-200) #
# #
# For some reason the results in VDub and #
# AviSynth are very different. The latter #
# is blurred a lot more. #
###########################################

Line 79: return clip._VD_SmartSmoothIQ(default(diameter,5), default(threshold,25), default(interlaced,false)?1:0)