picture home | art | events | music | rack extensions | downloads | pixel blog

omino pixel blog

pixels, motion, and scripting
david van brink // Mon 2023.09.4 23:22 // {after effects}

OminoLuaNote[2]: Naming Controls

omino lua presents a grab-bag of controls that your script can use. Here they are:

Here’s a short script which shows omino lua‘s text drawing, and uses controls to set the font size, color, and location.

function render(ca, cv)
  ca:textPrint(sprintf('frame %d',cv.frame))

And a screen shot of it in action.

Only four of the controls do anything; the rest are unused. And the names color0 and float1 are not helpful either. So you can a second function to your script to help with this.

function updateControls(cn, cv)
  cn.float0 = 'text size'
  cn.float1 = 'text angle'
  cn.color0 = 'text color'
  cn.point0 = 'text location'

It starts by disabling and hiding all the controls, and then naming just the several we’d like to see. (They cannot be reordered.) And it looks like this:

Now the controls make sense! This is valuable for whoever is using that script, whether it’s yourself or another team member.

oh, i dont know. what do you think?

(c) 2003-2023 omino.com / contact poly@omino.com