GINO Graphics Suite - GINO v9.0  

gSetSegMode

Syntax

[C/C++:]
void gSetSegMode(int sw);
[F90:]
subroutine gSetSegMode(sw)
integer, intent(in) :: sw

Arguments

sw
Software Display File switch

= GHARDWARE, Segmentation by hardware (if available)
= GMIXWARE, Segmentation by hardware (if available) with software backup
= GSOFTWARE, Segmentation by software emulation

Description

The routine gSetSegMode() sets or changes the segmentation mode. Where an application program is using segment facilities the correct operation of such a program depends on the existence of a Software Display File for storing the segment information. There are not many  devices that have such facilities built into their hardware, so in order to make such a program device independent GINO provides software emulation of a segmented display file by storing the segment information either in a scratch file or program memory.

Because of the overheads of storing a Software Display File, the default operation is to rely on hardware segment facilities (sw=GHARDWARE). The storing of a Software Display File is activated by setting sw to GMIXWARE or GSOFTWARE in the call to gSetSegMode() and the selection of storage in memory or on a disk file is made by gDefineSegWorkspace(). If gDefineSegWorkspace() is not called the display file will be held on a scratch file.

When sw=GMIXWARE the display file is stored by GINO and the hardware (if possible) and all segment operations will be performed by the hardware if it is able to do so. If an operation is not successful, GINO will emulate the operation from the Software Display File.

When sw=GSOFTWARE the display file is stored by GINO and no segment operations are passed through to the hardware.

GINO's Software Display File is maintained across device nominations, and therefore segments can be used on devices other than those on which they were created.

Software emulation of segment facilities relies on the facility to remove a segment from the display using background erase (ie. use of gSetLineColour(0)).

Unpredictable results can occur when changing segmentation mode while a segment is open. In most cases the change is delayed until the close of that segment.

See Also

gSetSegMode Usage
gDefineSegWorkspace