The “Formula” feature can both greatly simplify a fixture's Macro window and add more controls at the same time.
Three main variable families are available:
NOTES:
Basic math operators can be used in Formulas:
Formulas are written in standard programming syntax. Computations on the right side of the “=” are assigned to the variable on the left side.
NOTES:
Example 1:
CH01=48
Action: This assigns the value “48” to the fixture's Channel 1.
Example 2:
CH01=GI01*16
Action: This takes the index value of Gobo Channel 1, multiplies it by 16, and assigns it to the fixture's Channel 1.
If the fixture has 4 gobos, then GI01 will range in values 1, 2, 3, or 4; and the results of this formula will assign the values 16, 32, 48, or 64 to Channel 1.
Example 3:
CH01=16*(GI01-1)
Action: This subtracts 1 from the index value of Gobo Channel 1, multiplies the result by 16, and assigns it to the fixture's Channel 1.
If the fixture has 4 gobos, then GI01 will range in values 1, 2, 3, or 4; and the results of this formula will assign the values 0, 16, 32, or 48 to Channel 1.
Example 4:
CH01=16*(GI01-1)+4
Action: This subtracts 1 from the index value of Gobo Channel 1, multiplies the result by 16, adds 4, and assigns it to the fixture's Channel 1.
If the fixture has 4 gobos, then GI01 will range in values 1, 2, 3, or 4; and the results of this formula will assign the values 4, 20, 38, or 52 to Channel 1.
Example 5:
CH2=CH1
Action: This assigns the value in Channel 1 to the fixture's Channel 2. (Programming syntax reads from right to left.)
Example 6:
CH2=2^3
Action: Assign 2^3 (=8) to CH2
Example 7:
CH2=(15 MOD 10)
Action: Assign results of 14 Modulo 10 (=4)to CH2
The new “Formula” feature in Fixture Creator and FreeStyler helps to both simplify macros and add more control. Formulas must be written following strict syntax rules, otherwise they do not work.