vcm


frequency domain fnctions example scripts



example test code for F1Quiver.Top left freq spectrum with gamma scaling, filter used. Left lower half unscaled specrtrum. Right top half filtered output. Right lower half unfiltered input.
core.vcm.F1Quiver(ret,custom = 1,morph = 0,strow=50,nrows=200, test = 1,filter = [50,100,80,1,100,100], gamma = 0.091)



Example for F2Quiver. Left input, middle filtered output (test = 0), right freq spectrum and right extreme filters used(test = 1 mode).
core.vcm.F2Quiver(ret,test = 0,fspec=[3,4,70,80,12,5,4,75,40,12, 5,4,75,-220,12,3,4,70,80,12],gamma=0.05)





#blurred image .
core.vcm.F2QBlur(ret,line = 1,x = 4, y = 4)
#Sharpened image
core.vcm.F2QSharp(ret,line = 1,x = 4, y = 4, fr = 10,wn = 0.1, scale = 0.45)
ret=core.std.StackVertical(clips=[ret1,ret2])
ret.set_output()



#  Original image sharpening.
ret = core.imwri.Read([ "c:\----\Redeyebird.jpg"])
rets = core.vcm.F2QSharp(ret,line = 0,x = 3, fr = 20,wn = 0.2,rgb =[1,1], yuv=[1,0], scale = 0.4)
ret=core.std.StackHorizontal(clips=[ret,rets])
ret.set_output()







#Bokeh effect .
 script used to arrve at value of thresh:-
import vapoursynth as vs
import functools
import math
core = vs.get_core()

core.std.LoadPlugin(path=r'c:\....vcm.dll')
# image to get accentuated Bokeh Effect
ret = core.imwri.Read([ "c:\.....jpg"])
# Heavily blurred version of image
blr = core.vcm.F2QBlur(ret,line = 0, x = 20)
ret = core.std.Loop(ret,100)
blr = core.std.Loop(blr,100)
#
def animator(n,clipa, clipb):
	
	return core.vcm.F2QBokeh(clipa,clipb,grid = 24, thresh = 0.55 + n * 0.01)
#
b2k = core.std.FrameEval(ret,functools.partial(animator,clipa=ret, clipb = blr))
#b2k=core.vcm.F2QBokeh(ret,clipb = blr,thresh = 0.505645, grid = 16)
#
ret=core.std.StackHorizontal(clips=[b2k,blr])
ret.set_output()
image with similar process in avisynth+
1. F2QBokeh:

2. Bokeh: