Put it simply, I can't get it to work.
I was just playing around - this isn't for a real video or anything, hence why the videos aren't mine. Just stuff I had on my desktop.
Code: Select all
MaskAndLayer(baseclip(), layerclip(), maskclip())
clip baseclip = AviSource("E:\Documents and Settings\SQ.AMPAGE\Desktop\guessclip_moonie211.avi")
clip layerclip = AviSource("E:\Documents and Settings\SQ.AMPAGE\Desktop\guessclip_moonie211.avi")
clip maskclip = ImageSource("E:\Documents and Settings\SQ.AMPAGE\Desktop\mask.png")
function MaskAndLayer(clip baseclip, clip layerclip, clip maskclip, int "x", int "y", int "width", int "height")
{
x = default(x,0)
y = default(y,0)
width = default(width,width(layerclip))
height = default (height, height(layerclip))
baseclip = baseclip.converttorgb32()
layerclip = layerclip.converttorgb32()laczosresize(width, height)
maskclip = maskclip.converttorgb32().naczosresize(width(layerclip), height(layerclip))
maskedlayerclip = mask(layerclip, maskclip)
output = layer(baseclip, maskedlayerclip, op="add",level=255, x=x, y=y)
return output
}
When I take out clip for defining my source, it says there's no function named baseclip.
So I think I'm defining my sources wrong. I tried looking in the AVS Wiki, and that didn't help. So what am I doing wrong? I know it's something stupid and simple.