View Full Version : ShowFrameNumbers behavior
Cyberia
20th June 2004, 22:33
Is there a way to display the frame number in the upper right corner only?
ShowFrameNumbers either fills the entire right side with the number, or scrolls annoyingly. I just want the frame number displayed in the upper right only.
Perhaps there is a way to do this via the Subtitle command?
stickboy
20th June 2004, 22:36
Method 1:ScriptClip("Subtitle(String(current_frame), align=9)")Method 2:function ShowNumber(clip c, int n)
{
return c.Subtitle(String(n), align=9)
}
Animate(0, FrameCount() - 1, "ShowNumber", 0, FrameCount() - 1)
Cyberia
20th June 2004, 22:49
Sorry for being a pain. Thanks, that works but I can't display the Version simultaneously (see this thread (http://forum.doom9.org/showthread.php?s=&threadid=78365))
Id really like to be able to do the version string and the current frame number using independent commands. I am doing this from my own GUI and want to be able to turn each one on/off without cross-checking the other option (but i'll do it if I have to).
Cyberia
20th June 2004, 22:55
Ummmmm. Did the Info() command ALWAYS display the current frame number?
After using the ScriptClip command, Info() now displays the frame number and I can't make it stop.
I am aiming to be able to display Info(), the version AND the current frame number INDEPENDENTLY and/or SIMULTANEOUSLY.
stickboy
21st June 2004, 02:46
Originally posted by Cyberia
Thanks, that works but I can't display the Version simultaneouslyHuh?
AVISource("foo.avi")
ScriptClip("Subtitle(String(current_frame), align=9)")
Subtitle(VersionString())works for me... (as in the other thread, make sure you understand how implicit last works! If you've assigned clips to variables, you will need to chain your filters together explicitly!)c = AVISource("foo.avi")
c = c.ScriptClip("Subtitle(String(current_frame), align=9)")
c = c.Subtitle(VersionString())
Ummmmm. Did the Info() command ALWAYS display the current frame number?Yes.
Cyberia
21st June 2004, 04:05
stickyboy, thanks for your help.
I just spent a minute swearing at myself. I was using this script wondering why I could only get the last line to execute:
video=aviscript("foo.avi")
video = ScriptClip("Subtitle(String(current_frame), align=9)")
video = Subtitle(VersionString())
When it should have been:
video=aviscript("foo.avi")
video = video.ScriptClip("Subtitle(String(current_frame), align=9)")
video = video.Subtitle(VersionString())
Sorry bout that, my bad.
stickboy
21st June 2004, 04:12
At least spell my name right. ;)
Cyberia
21st June 2004, 04:22
oopsie. sorry.
Cyberia
21st June 2004, 19:03
One last question:
If I wanted to issue the 'font' parameter of the Subtitle command which is inside a ScriptClip command how would I do that? (ie: How do I nest quotation marks?)
video=video.ScriptClip("Subtitle(String(current_frame), font=Courier, size=16, align=9)")
This generates an error, and so does this:
video=video.ScriptClip("Subtitle(String(current_frame), font="Courier", size=16, align=9)")
stickboy
21st June 2004, 19:16
See this thread:
did you know: string containing quotes (http://forum.doom9.org/showthread.php?s=&threadid=71597)
You also can build up a string by doing things such as:function Quote() { return Chr(34) }
MessageClip(Quote() + "Nested quotes?" + Quote() + " he asked")Or you could avoid the issue entirely and create a wrapper function for Subtitle that always uses Courier.
vBulletin® v3.8.5, Copyright ©2000-2012, Jelsoft Enterprises Ltd.