Purpose of software visualization is to facilitate human understanding and effective use of computer software. In order to carry out this objective, it is important to have a display that is well designed for conveying the data in way that is most meaningful, easy to interpret and easy to navigate through. A few basic principles and techniques will be discussed here, which include the use of animation, color, 3D graphics, and sound. Issues in user interface for algorithm animation also will be discussed briefly.
In designing algorithm animation displays, some basic techniques here can be used as guidelines. When and where to use these techniques still need be determined by the nature of the data and the algorithm themselves on an individual basis. One technique is to use multiple views. This can aid in viewing multiple aspects of the same algorithm for an easier comprehension. It is also often nice to have state cues where user can see a certain state of the algorithm and be able to see the static history of the algorithm.
Other principles are also worth considering. A main feature of software visualization is to show the change in data structures. These transitions can be shown incrementally or discretely depending on the type and the amount of the data sets. Input data, in some cases should also be analyzed. The amount and the spectrum of values can greatly affect the aesthetic or the comprehensiveness of the output display. In cases where there are similar algorithms, it is useful to display multiple algorithms simultaneously for comparison.
One type of software visualization is to show the procedural steps of a process or algorithm. A smooth and continuous animation illustrating the primitive operations, preferably with a smaller set of data, can benefit the users in understanding the changes. Systems such as Tango and Polka provide the building blocks for displaying such continuous animation. In these systems, programmer and/or animator can identify fundamental operations, build the animations of the operations, and then map the operations to their graphical representations. Other components then can be defined for displaying the animation. The advantage that Polka has over Tango is the ability to display concurrent animation easily through the use of an explicit animation clock (frame count). These tools, among others, really encourage the use of software visualization by providing an easy development environment.
Because of hardware limitation, early software visualization has been done in a 2D view. But now, it has emerged also into displaying information in the 3D view. So what is so good about the 3rd dimension? With an additional dimension, same information can be expressed in a different domain or new information can be displayed in the 3rd dimension for a different perspective on the data (adapted 2D views). For data that naturally has a 3D representation, 3D view is certainly a match (inherent 3D application domain views). It is also a way to display relationship or connection between multiple 2D views. Moreover, the 3rd dimension is a convenient way to capture history. If nothing else, the new dimension can add aesthetic elements to the presentation (augmented 2D views). Examples from the Zeus system demonstrate many of these aspects.
The PLUM system demonstrates some of the techniques for moving representations from 2D to 3D. The 3rd dimension can extend another property of the data or can represent time. In 3D view, multiple 2D visualizations can be integrated. The placement and organization of the objects being displayed can have a new dimension for expansion or arrangement (e.g. fish-eye view and cone tree). Example below shows the use of some of these techniques.
3D view is a nice idea. But what about some of the drawbacks or problems being faced today? Because 3D objects and animations are more complex, there are rendering delays. Second, different perspectives are being presented. As a result, assumptions based on user's view cannot be made for they may not be valid. Third problem is that more degrees of freedom for displaying data lead to having three alternatives for how to represent levels, not just rows and columns. Fourth, incorporating information in the 3rd dimension requires system to handle more properties of the displayed objects, such as the layout (i.e. adding the z coordinate).
In conclusion, designing an informative, expressive view in 3D is not an easy task. One question is that does 3D view really enhance the understanding? Some people feel that 2D representation has an advantage of being simple, less to comprehend, therefore easier to interpret. There is also the perspective issue in 3D view. There are many more different ways to look at the display. Will information be misinterpreted more easily? What about navigation? Since there are more to control, more controls are needed. How can navigation stay simple?
Another technique used in software visualization that is widely used is color. It is very good at displaying the state of data structures, highlighting certain activity, uniting multiple views, emphasizing patterns, and making history visible. But some properties of color may not make it very suitable for use in visualization. Color does not convey ordering. Moreover, humans can only successfully identify the meaning or association of about five to six colors at one time. Too many colors will just be confusing. There is also no natural mapping of color to another domain. How can legend or label be presented to the users in ways that are intuitive and non-obstructive? Bottom line is that there should be a purpose for using color, to use it to mean something, and not blindly throwing colors onto the display.
What about the use of sound? It has been used in some software visualizations since it provides another view, much like the 3rd dimension in 3D view. It can better represent certain types of data. And listening is passive so it can be done parallel with visual. As a result, it can relieve some of the burden of the visual interface by reinforcing what is being displayed or can completely replace the visual. Since humans are good at detecting and remembering patterns in sound, it can be used to convey patterns or alert users of certain events (e.g. signal exception). In addition, sound has more dimensions than colors, therefore it is a good medium to deliver large amount of data in parallel. The temporal nature of sound also makes it ideal for some representations such as program execution.
LogoMedia is an example of a system that provides program auralization. Sound can be used for annotation during execution, review (code examination), or preparation (compilation or entering program). An example is shown below.
Sound certainly enhances software visualization. But how much of it should be used? Sound is excellent to signal exception or to alert of an odd event. It also nicely conveys patterns. However, as with colors, users forget mapping if there are too many different sounds being presented. (Not to mention it can be annoying.) It is also difficult to track exact occurrences as in visual where one can see a particular state in history.
Last aspect of software visualization being discussed here is user interface, particularly issues in algorithm animation. In this case, the goal is to optimize the learning effect, and the most important guidelines are consistency, interactivity, and clarity. These can also apply generally to other types of software visualization user interface.
In summary, many techniques are very helpful in visualizing software. The use of each technique should be considered very carefully depending on the type of software visualization being utilized and what the associated data are. If there is a purpose for its use in better communicating to the users, then it can be justified.