| Contents |
|
|
One idea that has become very popular in VST GUI design is to have a central display area that shows the readings of whatever control is currently active.
The first level, which can be done using the DH_ControlMerger
and other modules from the DH_Sub-ControlPak, updates the central display
whenever a control's value is changed.
The idea behind the DH_ControlMerger is simple. The Ctrl Value pin outputs the value of the connected control that last changed, while the Ctrl Index pin outputs a number that identifies which control that was. Controls are numbered from 0, in the order in which they are connected (top down).
With this information, a DH_TextArray, and a DH_Format, the
basic text strings for a central display can be built. The format strings for the DH_Format are stored in the DH_TextArray, which is loaded from a text file. For this simple, 2-control example, the file looks like this:
Thus, the Ctrl Index from the DH_ControlMerger selects the control's format string, the format string contains the control name, the number format for the value, and units of measure, if any, and the value is supplied by the DH_ControlMerger's Ctrl Value.
It has 2 modes: Layout and Run. In Layout mode, you draw rectangles to define the area for each control. Rectangles can be moved, resized, and deleted as necessary.
In Run mode, the rectangles are invisible. Mouse movements are tracked, and the Control Name, Description, and formatted numeric value or list selection of the control currently under the mouse are updated whenever the mouse moves. The DH_ControlOverlay User's Guide covers this and more in much more detail. |