Next: External library descriptions
Up: Program Structure
Previous: Program component descriptions
After the program starts up and initializes all global objects as well as processing any startup data files, an execution loop is entered which continues until the user requests to quit VMD
. This loop is mainly contained in the routine VMDupdate (in the file Global.C), which is called continuously by the main routine of VMD
. The algorithm for this loop is:
- The UIList
object requests each UIObject
to check for any events such as mouse button presses or GUI button/slider/browser/whatever presses. These events are entered into the CommandQueue
objects queue as Command
object instances.
- All commands in the CommandQueue
are processed until the queue is empty. Typically, the processing of an event will result in one or more new Command
object being created and placed at the end of the CommandQueue
. The CommandQueue
will just continue processing each command until the queue is complete empty, which will deal with all the events found in the previous step, as well as any other commands generated while processing the events.
- The UIList
object is told to have each registered UIObject
do any update that needs to be done each cycle through the execution loop. This accomplishes such things as updating the current frame in the form used for molecule trajectory animation.
- The current Scene
is rendered to the current DisplayDevice
.
Andrew Dalke
Wed May 15 02:25:03 CDT 1996