SansGUI 1.2 Features and Enhancements

This section describes new features and enhancements, which have been introduced since the official release of SansGUI version 1.1. Please tour through Point of Attraction 5: Solid in the SansGUI Getting Started guide to explore the new and exciting interactive 3D graphics features. A demonstration of the new graphics features can be found in ProtoDesign's web site.

Interactive 3D Graphics Programming Using OpenGL

The primary enhancement to SansGUI since its version 1.1 has been the support of interactive 3D graphics programming, using Silicon Graphics' OpenGL® Application Programming Interface (API) in Microsoft Visual C++ and Compaq Visual Fortran development environments. SansGUI provides simulation developers with all the ground work needed to incorporate OpenGL programming in the Windows environment; therefore, integrating animated OpenGL 3D graphics with your own simulation code is never easier. The new graphics features include the following:

New Class <Reference>Graphics for 3D Graphics Integration

A new intrinsic class, Graphics, is introduced for simulation developers to implement 3D graphical displays using the OpenGL API. Similar to the Collection intrinsic class, the Graphics class can be extended to include new attributes the simulation developers need. Four DLL function entry points of the class are specially mapped to OpenGL related tasks, such as setting up rendering context, responding to window resizing, rendering 3D graphical scene, and handling user selections, to make OpenGL programming in Windows a very simple job. Class Graphics is implemented as a reference class, which means objects derived from it can be referred to and updated by other objects or parts for dynamic 3D scene rendering at simulation run time.

Programming OpenGL 3D Graphics without Learning Windows Details

Incorporating OpenGL 3D graphics into a Windows application requires the knowledge of the intricacies within the Windows environment and between Windows and the OpenGL graphics engine. SansGUI hides all Win32 programming details from the developers and works around a major bug, Microsoft Knowledge Base 272222, in Microsoft OpenGL generic implementation so that the simulation routines that utilize OpenGL API can be kept as simple and clean as possible.

Displaying Animated 3D Graphics

Managed by the SansGUI in-process simulation control, 3D graphical objects can be displayed according to their dynamic properties during a simulation run. The Graphics Window can be updated at each screen refresh cycle, giving the users realistic, animated 3D images based upon the simulation results.

Fully Integrated Graphical Operations

Interactive operations supported in the SansGUI Run-Time Environment, such as pausing a simulation run, running with single stepping, fast forwarding, and modifying intermediate values, are available to the user to control the display of 3D Graphics objects.

Low or No Performance Penalties

The four graphics-related DLL functions are called only when the Graphics Window that is associated with a Graphics object is opened by the user. The user can also adjust the screen refresh interval to control graphics screen updates. This translates into very low or no run-time performance penalty for computation-intensive applications.

User Interface Integration without GUI Programming

A default set of user interface controls, for 3D object rotation, zooming, and panning, is included with the Graphics class. The details in handling user interactivity are covered by SansGUI. The simulator receives all the UI control data from SansGUI via SansGUI data objects as before.

User Selection Support

The SansGUI Run-Time Environment provides users with a point-and-click facility to select rectangular areas in Graphics Windows. The simulation developers can specify how SansGUI should give visual cues to the users, 0) None, 1) Point, 2) Line, and 3) Rectangle, when the user clicks on a point in the graphics display and drags the pointer. The user interface operations are handled automatically by SansGUI. The simulator receives the beginning and ending points from SansGUI via the SansGUI data object every time the user makes a selection.

Customizable Behavior in User Interface Controls

Although the user interface controls in the Graphics class are tied, by default, to rotating about X and Y axes, zooming, and panning, the interpretations of these values can be changed by the simulation developer to implement other UI features. For example, a scope can be drawn in the Graphics Window with the horizontal and vertical scrollbars controlling the user input or adjustment values.

Interactive User Control during a Simulation Run

All of the interactive operations in the Graphics class are available to the user while a simulation is running. This means that the simulation developer can program the Graphics objects in such a way that the intermediate results from a simulation can be "disturbed," or fine-tuned, by the user during the simulation run.

Print Support

The contents of all Graphics Windows can be printed directly to any printers or files supported by Windows. SansGUI sets a SG_STAT_PRINT bit in the status member of the Graphics objects to notify the simulator routines that they are called during a printing process. An example of using this feature is to switch to a light background color for printing.

3D Images and Windows Clipboard Support

The images in the Graphics Windows can be copied to Windows clipboard and then pasted to other Windows programs, such as Microsoft Word, CorelDraw, etc., for documentation and publishing purposes.

Exporting 3D Graphics Images to Bitmap or JPEG Image Files

The 3D images in the Graphics Windows can be saved to external picture files in either Microsoft Bitmap (.BMP) or JPEG (.JPG) format. The latter is good for web publishing.

Saving Canvas Views as Bitmap or JPEG Image Files

In addition to exporting Canvas Views to Enhanced Metafiles (.EMF) supported in SansGUI version 1.1, this version allows users to save Canvas Views to Microsoft Bitmap (.BMP) or JPEG (.JPG) picture files.

Dialog Persistence

The positions and sizes of Properties (Class, Object, Part, or Link) and Execution (Graphics or Plot Results) dialogs are made persistent; they will be restored to the same positions and sizes when closed and then reopened. When a document is loaded back into SansGUI, the Execution dialogs opened in the previous session will be restored. Users can take advantage of this new feature in conjunction with the Workspace Persistence mechanism for faster loading of working projects across sessions.

Accessing Reference Objects When Simulation Is Not Running

In previous versions, the only SansGUI data objects reliable in a DLL function call during the model construction time, or when the simulation is not running, are the object itself (self) and the simulation control object (simCtrl). Starting from version 1.2, SansGUI tries to resolve the object references as complete as possible and passes the reference objects via the API to the DLL functions.

Expanded Number of Classes in the Student Edition

The Student Edition is expanded to maximum 20 classes instead of 10 in the previous versions.

Accessing Simulator's On-Line Document

The on-line document of any installed simulator can be accessed by selecting the What's this? menu item from the right-click context menu, whenever a list of installed simulators is displayed.


C:\FH_Suite\htmlgifs\home.gif Version 1.2 Addenda SansGUI 1.1 Features and Enhancements

SansGUI Modeling and Simulation Environment Version 1.2

Copyright © 2000-2003 ProtoDesign, Inc. All rights reserved.