A final timing consideration is synchronization with data acquisition
or other hardware. A common paradigm is to trigger data acquisition
hardware from the Vision Egg. There are several ways to do this with
the Vision Egg.
Perhaps the simplest is to control a digital output on the computer's
parallel port so that this value goes from low to high when the first
frame of a stimulus is drawn. Support for this is provided for linux
and win32. Unfortunately, the parallel port is can only be updated
when OpenGL is instructed to swap buffers, not when the monitor
actually refreshes. If you need timing accuracy better than your
inter-frame interval, the best solution is to ''arm'' the trigger of
your data aquisition device (with the parallel port output or a
network command) immediately before the stimulus begins and trigger
with the vertical sync pulse from the VGA cable itself.
Alternatively, you could begin data acquisition less precisely,
digitize the vertical sync pulse going to the monitor along with your
usual data, and align the data after the experiment is complete.
Another method, or a method to validate timing, is to use a photo
detector on a patch of screen whose brightness might go from dark to
light at the onset of the experiment.