theraindew
15th July 2004, 21:08
Hello
i've encoded a movie using gordianknot, and everything is fine.
now i want to add a watermark text to the avi file, that would appear only for a few seconds, and at a particulat time i choose, as the DivX logo appears.
Thank u
naveen
jggimi
15th July 2004, 21:48
You could add the Subtitle() filter to the AviSynth scripts (.avs files) that GKnot generates. Merely use the Edit button while in the "Save & Encode" process within Gknot.
For example, adding this line:Subtitle("Text")will show the text in all frames. To show the text in only a selection of frames, the more complete syntax must be used. The following line uses all defaults (yellow, Arial, etc.) except the start and end frame numbers, which I've placed in bold:Subtitle("Text",8,18,100,299,"Arial",18,$FFFF00,0,4,0)The text will appear in 200 frames: frame 100 through 299. For more information, see http://www.avisynth.org/Subtitle.
The DivX logo is produced by the DivX decoder, and is not actually part of your video.
{EDIT: There are also tools that can insert bitmaps into the video, but you've requested text.}
chilledoutuk
16th July 2004, 06:06
is there a way to fade the subtitle in and back out again?
gircobain
16th July 2004, 10:15
function SubZoomInOut(clip "clip", int "frames", string "text", int "x", int "y", int "first_frame", int "last_frame",
\ string "font", int "size", int "text_color", int "halo_color", int "align", int "spc")
{
clip = default(clip, last)
tmp = default(x, 8)
align = tmp == -1 ? default(align, 5) : default(align, 4)
x = (align == 1) || (align == 4) || (align == 7) ? default(x, 8) :
\ (align == 2) || (align == 5) || (align == 8) ? default(x, -1) :
\ (align == 3) || (align == 6) || (align == 9) ? default(x, width(clip)-8) : 0
size = default(size, 18)
y = (align == 4) || (align == 5) || (align == 6) ? default(y, size) :
\ (align == 7) || (align == 8) || (align == 9) ? default(y, 0) :
\ (align == 1) || (align == 2) || (align == 3) ? default(y, height(clip)-1) : 0
frames = default(frames, 1)
first_frame = default(first_frame, 0)
last_frame = default(last_frame, framecount(clip)-1)
font = default(font, "Arial")
size = default(size, 18)
text_color = default(text_color, $FFFF00)
halo_color = default(halo_color, 0)
spc = default(spc, 0)
Subtitle(clip, text, x, y, first_frame+frames, last_frame-frames, font, size, text_color, halo_color, align, spc)
Animate(first_frame, first_frame+frames-1, "subtitle",
\ last, text, x, y, first_frame, first_frame+frames-1, font, 0, text_color, halo_color, align, spc,
\ last, text, x, y, first_frame, first_frame+frames-1, font, size, text_color, halo_color, align, spc)
Animate(last_frame-frames+1, last_frame, "subtitle",
\ last, text, x, y, last_frame-frames+1, last_frame, font, size, text_color, halo_color, align, spc,
\ last, text, x, y, last_frame-frames+1, last_frame, font, 0, text_color, halo_color, align, spc)
}
Parameters are the same as for Subtitle(), except for "frames", which is the number of frames for the text to zoom in/out
A usage example:
SubZoomInOut(20, "Hello, World", 150, 50, 100, 299, size=30, align=2)
I'd write a "real" subtitle fade in/out script, using overlay and what not, but it's too late, too sleepy :)
theraindew
16th July 2004, 14:54
Thanks for the reply.
Plz let me know about how to add bitmap to an avi video.
Adding text is OK.
jggimi
17th July 2004, 18:55
You'll find plenty of threads in the AviSynth forum that cover such things. You can start with this thread if you like; searching will uncover more.
http://forum.doom9.org/showthread.php?s=&threadid=77045
vBulletin® v3.8.11, Copyright ©2000-2026, vBulletin Solutions Inc.