itay2222
22nd January 2007, 15:52
hi all,
just wanted to share a script to blink text on screen...
if avisynth had loops it was easier, but i did it using recursion (inspired by some post from here, think it's stickboy )
here it is:
#
# n- is number of blinks, the +10 and +20 consts can be
# changed, they represent on-off for text, frame count
#
function blinkText (clip c, int startframe, int n, string txt)
{
#Assert(n >= 0)
return (n == 1) ? c : \
Subtitle(blinkText (c, startframe+20, n-1, txt), \
txt, \
size=48, align=9, \
first_frame=startframe, \
last_frame=startframe+10)
}
enjoy?
just wanted to share a script to blink text on screen...
if avisynth had loops it was easier, but i did it using recursion (inspired by some post from here, think it's stickboy )
here it is:
#
# n- is number of blinks, the +10 and +20 consts can be
# changed, they represent on-off for text, frame count
#
function blinkText (clip c, int startframe, int n, string txt)
{
#Assert(n >= 0)
return (n == 1) ? c : \
Subtitle(blinkText (c, startframe+20, n-1, txt), \
txt, \
size=48, align=9, \
first_frame=startframe, \
last_frame=startframe+10)
}
enjoy?