One component of the refactoring plan is to provide a high level "control executive". By this is meant an API to control most of the operations that are currently under the control of the VAPOR GUI, while avoiding any actual GUI code. Here are some thoughts about what should be doable from the Control Executive:
Load and Save Session \ [currently in the Session class\] Wiki Markup Create and destroy visualizers \ [ currently performed by the VizWinMgr class\]. Note: In the absence of the GUI or windows, a visualizer should be replaced by something that encapsulates a rendering context Wiki Markup Create and destroy renderer instances \ [currently performed in the event routers in the GUI\] Wiki Markup Wiki Markup
- Create and destroy Params instances \ [currently performed in the Params class\]
- Get and set the state of any Params instance.
- Perform a rendering
- Play and record an animation sequence
The following items are not currently addressed by the ControlExecutive class:
- ErrorHandling: All of the ControlExecutive methods return a success or failure status. However, no methods have been provided for returning an error code or error message. ## (AN) I propose an ErrorHandler class be defined, which UI's can use to be notified when the Control Executive has an error condition.
- OpenGL state mgt: In the proposed API the UI is responsible for establishing the OpenGL drawing context (e.g. creating a drawing window) on behalf of the ControlExecutive. We need to flesh out what other OpenGL responsibilities/expectations the UI and ControlExecutive have wrt OpenGL. Not sure what you are asking. Does this require an implementation?
- Timestep specification: How are time steps specified?## The timestep is specified in the AnimationParams class
- Key framing:## This is also specified in the AnimationParams class
- Manipulators## (AN) I propose a ManipParams class that will include all the settings associated with the current mouse mode. UI's can translate mouse events into changes in the ManipParams that applies to that window.
- Image capture## (AN) I added an "EnableCapture" method to the API doc
- Probing: How does the UI query data values selected by the probe?## (AN) The UI can convert the probe mouse coordinates into user coordinates (using Extents etc. obtained from DataMgr). Then it can use the RegularGrid to evaluate a variable at the specified position.
Example Use Cases
// A single visualization window with a single renderer, single instance