Generator events

<< Click to Display Table of Contents >>

Navigation:  Callbacks >

Generator events

Usage (requires global variable associated with a generator):

On GeneratorRunning:  called periodically while a generator is active.

Example:

On GeneratorRunning(x : integer, y : double) from <some generator>

   // x is linear time based on the length (or frequency) of the generator

   // y is an amplitude with a value ranging between 0.0 and 1.0

   // The actual value for y at some position x depends on the kind

   // of generator and the settings being used

End

 

Note: this function used to be called TimePassing but as of GP 4.2, that callback name is deprecated and will be removed in a future version.

 

On GeneratorEndCycle: called when a generator reaches the end of a single cycle.

Example:

On GeneratorEndCycle(x : integer) from <some generator>

   // x is linear time that hit the end of the cycle of this generator

   

End