Museum

Home

Lab Overview

Retrotechnology Articles

Online Manuals

⇒ phigswstset(3P) — PHIGS 1.1

Media Vault

Software Library

Restoration Projects

Artifacts Sought

Related Articles

TABLE(7)

WORKSTATION TYPE SET(3P)  —  SUNPHIGS LIBRARY

NAME

WORKSTATION TYPE SET − set workstation type attributes − SunPHIGS Extension

SYNOPSIS

C Syntax

Pwstype
phigs_ws_type_set ( ws_type, <attribute-value list> )
Pwstypews_type; workstation type
<attribute-value list>;

FORTRAN Syntax

SUBROUTINE phigswstset ( WST, ATTRIBUTE, VALUE1, VALUE2, VALUE3 )
INTEGERWSTworkstation type
INTEGERATTRIBUTEattribute
INTEGERVALUE1value
INTEGERVALUE2value
INTEGERVALUE3value

Required PHIGS Operating States

(PHOP, ∗, ∗, ∗)

DESCRIPTION

Purpose

WORKSTATION TYPE SET changes the values of fields in the workstation description table associated with a specified workstation type.  These values will control the characteristics of workstations of this type when they are opened.  WORKSTATION TYPE SET only operates on workstation types created by WORKSTATION TYPE CREATE.  The predefined types may not be modified, nor may types returned by INQUIRE WORKSTATION CONNECTION AND TYPE.  See OPEN WORKSTATION for a description of the predefined workstation types. 

The workstation description table contains both the PHIGS-defined fields and SunPHIGS-specific fields. All of the SunPHIGS-specific fields can be changed with this function as well as some of the PHIGS-specific fields.  The fields that can be modified are listed below in the Workstation Attributes section. 

This is a SunPHIGS addition, and is not part of the PHIGS standard. 

C Input Parameters

ws_type
The workstation type to operate on. This cannot be a bound type or one of the predefined types.

<attribute-value list>
A zero terminated list of workstation type attributes and corresponding values.  The attributes are members of the Phigs_ws_type_attr enumeration defined in phigs.h.  The data type of the values varies according to the attribute.  The list of attributes below specifies the value type required for each attribute.  The attribute fields of the workstation type are modified according to the contents of this list.

FORTRAN Input Parameters

WSTThe workstation type to operate on.  This cannot be a bound type or one of the predefined types. 

ATTRIBUTE
The workstation description table field to set.  The attributes are defined in PARAMETER statements in phigs77.h.  The data type of the values varies according to the attribute.  The list of attributes below specifies the value type required for each attribute. 

VALUE1, VALUE2, VALUE3
The value, or values, of the attribute.  The latter two are not used for most attributes.  The attribute descriptions below specify which are used for a given attribute.

Execution

WORKSTATION TYPE SET modifies the fields of the workstation description table associated with the specified workstation type.  The modifiable fields are listed below.  The changes are specified with attribute-value pairs.  The attribute specifies the field to change. The value is the value to assign to the field.  The SunPHIGS-specific fields are different for different workstation types, so the attributes are listed according to the workstation type to which they apply. 

Workstation Type Attributes

The workstation description table attributes are described here.  Both the C and FORTRAN constants are listed along with a description of each attribute, the data type required and the default value.  The C constants are members of the Phigs_ws_type_attr enumerated type defined in phigs.h.  The FORTRAN constants are defined with PARAMETER statements in phigs77.h. 

Some attributes can have values that advise SunPHIGS to make use of certain facilities if they are available.  These values are: PHIGS_USE_PREFERRED, PHIGS_USE_NONE, or PHIGS_USE_REQUIRED in C (typedef enum Phigs_usage), and PHIGSUSEPREFER, PHIGSUSEREQUIRED, or PHIGSUSENONE in FORTRAN.  Preferred means that SunPHIGS will use the object if it is available, but if it is not available a reasonable alternative will be used.  None prohibits use of an object.  Required requires use of an object. 

Common Attributes

PHIGS_COLOUR_TABLE_SIZE  (C),  PHIGSCLRTBLSIZE  (FORTRAN)
The size of the PHIGS colour table.  If the size is not a power of two, it will be rounded up to the nearest power of two.  Maximum size is 256. 

Data type: 

Pint  (C),  INTEGER  (FORTRAN)

Default: 

32

PHIGS_DEVICE_COORD_XMAX_PTR  (C),  PHIGSDCXMAX  (FORTRAN)

PHIGS_DEVICE_COORD_YMAX_PTR

  (C),  PHIGSDCYMAX  (FORTRAN)

The x and y limits of the workstation device space.  The z limit is not modifiable.  These values implicitly define the aspect ratio of the workstation device space.  The x and y limits need not be the same.  The lower limit of device space is always zero in all dimensions.  See INQUIRE DISPLAY SPACE SIZE for more information. 

Note: The data type for the C binding is a pointer to a Pfloat, not simply a Pfloat. 

Data type: 

Pfloat∗  (C),  REAL  (FORTRAN)

Default: 

1.0, 1.0

PHIGS_BASE_NAME  (C),  PHIGSBASENAME  (FORTRAN)
This argument to WORKSTATION TYPE GET retrieves the base type of the workstation type.  It can not be specified as an argument to this function. 

C enumeration: 

PHIGS_SUN_TOOL, PHIGS_SUN_CANVAS, PHIGS_CGM_OUT

FORTRAN enumeration: 

PHIGSSUNTOOL, PHIGSSUNCANVAS, PHIGSCGMOUT

Common Sun_tool and Sun_canvas Attributes

PHIGS_ACCELERATOR_USAGE  (C),  PHIGSACCUSAGE  (FORTRAN)
Specifies whether or not SunPHIGS should use hardware acceleration directly, if any exists.  None disables direct use of any existing accelerator.  Required specifies that if an accelerator is not available, OPEN WORKSTATION should fail and generate an appropriate error.  Preferred (the default) indicates that an accelerator should be used if it is available, but to perform graphics output without acceleration if not. 

Data type: 

Phigs_acc_usage  (C),  INTEGER  (FORTRAN)

Default: 

Preferred

C enumeration: 

PHIGS_USE_ACC_PREFERRED,   PHIGS_USE_ACC_REQUIRED,   PHIGS_USE_ACC_NONE

FORTRAN enumeration: 

PHIGSUSEACCPREF,   PHIGSUSEACCREQ,   PHIGSUSEACCNONE

For backwards compatibility, the older PHIGS_GP_USAGE (C)/PHIGSGPUSAGE (FORTRAN) attribute is still valid; its required, preferred, and none values are mapped to the three general accelerator values just described.  Future SunPHIGS releases may not include this support. 

More specific control over the type of accelerator to be used is available, if required.  It should be noted that this practice will destroy program portability (with respect to obtaining transparent hardware acceleration), but is available for applications where it may be desirable to be tuned to a specific hardware configuration.  The following values are available for specific accelerators: gp required, gp preferred, (GP2, GP+, GP1), cg6 required, cg6 preferred, taac required, taac preferred.  The required values indicate that if the specified accelerator is not available, OPEN WORKSTATION should fail and generate an appropriate error.  The preferred values indicate that the specified accelerator should be used if it is available, but to perform graphics output without acceleration if not. 

C enumeration: 

PHIGS_USE_GP_REQUIRED,   PHIGS_USE_GP_PREFERRED,   PHIGS_USE_CG6_REQUIRED,   PHIGS_USE_CG6_PREFERRED,   PHIGS_USE_TAAC_REQUIRED,   PHIGS_USE_TAAC_PREFERRED

FORTRAN enumeration: 

PHIGSUSEGPREQ,   PHIGSUSEGPPREF,   PHIGSUSECG6REQ,  PHIGSUSECG6PREF,  PHIGSUSETAACREQ,   PHIGSUSETAACPREF

PHIGS_WS_CATEGORY  (C),  PHIGSWSCATEGORY  (FORTRAN)
The category of the workstation.  This attribute can be used to make a workstation have category OUTPUT (i.e. output only). 

Data type: 

Pwscat (POUTPUT or POUTIN only)  (C),  INTEGER  (FORTRAN)

Default: 

OUTIN

C enumeration: 

POUTPUT, PINPUT, POUTIN, PMO, PMI

FORTRAN enumeration: 

POUTPT,   PINPUT,   POUTIN,   PMO,   PMI

PHIGS_MSG_WIN_SIZE  (C),  PHIGSMSGWINSIZE  (FORTRAN)
Indicates the number of visible lines in a SunPHIGS-created message window.  This attribute only applies to windows created by SunPHIGS. 

Data type: 

Pint  (C),  INTEGER  (FORTRAN)

Default: 

3

PHIGS_TEXTSW  (C),  PHIGSTEXTSW  (FORTRAN)
Controls creation of the message window.  When the value is a valid Textsw handle and the workstation type is sun_canvas, SunPHIGS will use that text subwindow as the message window and STRING device for the workstation.  If the value is None, messages from the MESSAGE function will be displayed in the lower left corner of the graphics area, and the STRING input device will be disabled.  Create indicates that SunPHIGS should create a message window. 

The default value differs for sun_tool and sun_canvas workstations.  A Textsw handle is only allowed for sun_canvas workstations types. 

Data type: 

Phigs_creation  (C),  INTEGER  (FORTRAN)

Default: 

Create, sun_tool; None, sun_canvas

C enumeration: 

PHIGS_NONE, PHIGS_CREATE, Textsw handle

FORTRAN enumeration: 

PHIGSNONE, PHIGSCREATE, Textsw handle

PHIGS_COLOURMAP_NAME  (C),  PHIGSCMAPNAME  (FORTRAN)
Indicates that the named colourmap segment should be used as the workstation colour table.  This allows an application to share a colourmap segment among SunPHIGS workstations and other SunView windows. 

Warning: If colourmap segments are shared among windows, setting a colour representation will affect all windows (including SunPHIGS workstations) sharing the same colourmap segment.  See COLOUR (7P) for more information. 

Data type: 

Pchar∗  (C),  CHARACTER(∗)  (FORTRAN)

Default: 

phigscmap.i.j, where i and j are random

PHIGS_DOUBLE_BUFFER  (C),  PHIGSDBLBUFFER  (FORTRAN)
Specifies the method of double buffering to use.  None indicates that SunPHIGS should not use double buffering.  Cmap indicates that colourmap double buffering should be used.  Hw indicates that hardware double buffering should be used if available.  See COLOUR (7P) for more information. 

Data type: 

Phigs_dbl_buff  (C),  INTEGER  (FORTRAN)

Default: 

None

C enumeration: 

PHIGS_DBL_NONE, PHIGS_DBL_CMAP, PHIGS_DBL_HW

FORTRAN enumeration: 

PHIGSDBLNONE,   PHIGSDBLCMAP,   PHIGSDBLHW

PHIGS_VAL_PANEL_X  (C),  PHIGSVALPANELX  (FORTRAN)

PHIGS_VAL_PANEL_Y

  (C),  PHIGSVALPANELY  (FORTRAN)

Specify the desired location, in screen coordinates, of the VALUATOR panel.  A value of -1 means to place it anywhere on the screen. 

Data type: 

Pint  (C),  INTEGER  (FORTRAN)

Default: 

-1,-1

PHIGS_NORM_CURSOR_TYPE  (C),  PHIGSNMLCURSTYPE  (FORTRAN)
The cursor type to use as the normal cursor that is displayed when no input devices are active and a traversal is not in progress.  See ESCAPE for a description of SunPHIGS cursor usage and control. 

Data type: 

Phigs_cursor_type  (C),  INTEGER  (FORTRAN)

Default: 

Not Sign

C enumeration: 

PHIGS_CURSOR_NONE, PHIGS_CURSOR_DEFAULT, PHIGS_CURSOR_CROSSHAIR, PHIGS_CURSOR_CROSS,    PHIGS_CURSOR_NOT_SIGN

FORTRAN enumeration: 

PHIGSCURSNONE, PHIGSCURSDEFAULT, PHIGSCURSCRSHAIR, PHIGSCURSCROSS,     PHIGSCURSNOTSIGN

PHIGS_NORM_CURSOR_COLOUR  (C),  PHIGSNMLCURSCLR  (FORTRAN)
The colour index of the normal cursor. The exact appearance of the cursor depends on the colour, the raster op, and the pixels under the cursor.

Data type: 

Pint  (C),  INTEGER  (FORTRAN)

Default: 

1

PHIGS_NORM_CURSOR_OP  (C),  PHIGSNRMCURSOP  (FORTRAN)
The raster op to use when drawing the normal cursor. The exact appearance of the cursor depends on the colour, the raster op, and the pixels under the cursor.

Data type: 

Phigs_drawing_op  (C),  INTEGER  (FORTRAN)

Default: 

XOR

C enumeration: 

PHIGS_OP_XOR, PHIGS_OP_SRC, PHIGS_OP_OR, PHIGS_OP_AND, PHIGS_OP_NOT_AND, PHIGS_OP_NOT

FORTRAN enumeration: 

PHIGSOPXOR, PHIGSOPSRC, PHIGSOPOR, PHIGSOPAND, PHIGSOPNOTAND, PHIGSOPNOT

PHIGS_TRAV_CURSOR_TYPE  (C),  PHIGSTRVCURSTYPE  (FORTRAN)
The cursor type to use as the traversal cursor that is displayed when a traversal is in progress.  See ESCAPE for a description of cursor usage and control. 

Data type: 

Phigs_cursor_type  (C),  INTEGER  (FORTRAN)

Default: 

None

PHIGS_TRAV_CURSOR_COLOUR  (C),  PHIGSTRVCURSCLR  (FORTRAN)
The colour of the traversal cursor. The exact appearance of the cursor depends on the colour, the raster op, and the pixels under the cursor.

Data type: 

Pint  (C),  INTEGER  (FORTRAN)

Default: 

1

PHIGS_TRAV_CURSOR_OP  (C),  PHIGSTRVCURSOP  (FORTRAN)
The raster op to use when drawing the traversal cursor. The exact appearance of the cursor depends on the colour, the raster op, and the pixels under the cursor.

Data type: 

Phigs_cursor_op  (C),  INTEGER  (FORTRAN)

Default: 

XOR

PHIGS_COLOUR_MODE  (C),  PHIGSCLRMODE  (FORTRAN)

This attribute indicates wheither SunPHIGS uses the frame buffer as an indexed or true colour device. An indexed device specifies the colour of pixels as indices into a colour table, a true colour device species the colour of pixels as red, green and blue (RGB) triplets. 

When this attribute is set to index colour, direct colour (that is specifing colours by RGB triplets) is not supported, and direct colours from SunPHIGS Extension attributes and primitive data are drawn as colour type indirect, colour index one.  Primitives that use indirect colour (including all PHIGS-standard primitives) will appear exactly as specified. 

When this attribute is set to true colour, both indirect and direct colour are supported.  This means that colour can be specified either as indices, or as RGB colours. All PHIGS-standard colour attributes are supported, and both indirect and direct specification of colour are available using SunPHIGS Extension attributes and primitives. 

In true colour mode, changes to the workstation colour table do not appear until the next traversal of the posted structures. The dynamic modifcation flag for SET COLOUR REPRESENTATION is IRG. 

The following workstation type attributes are not active when in true colour mode: colour map double buffering, colour map name, tool background colour, and tool foreground colour. Cursor colours and PET colours may look different in true colour mode. 

On 8-bit frame buffers, the hardware is index colour, and this attribute defaults to index colour.  If this attribute is set to true colour, then SunPHIGS simulates true colour on the frame buffer.  This simulation may be slower than indexed colour mode, and the colour of primitives may be slightly different. 

On 24-bit frame buffers, the hardware is true colour, and this attribute defaults to true colour.  Since true colour mode includes all of the functionality of index colour mode, index colour mode is not supported on true colour devices. 

The TAAC supports both 8-bit and 24-bit display modes, so this attribute indicates wheither the TAAC workstation will run as an 8-bit indexed or 24-bit true colour device. 

Data type: 

Phigs_colour_mode  (C),  INTEGER  (FORTRAN)

Default: 

Index colour (on 8-bit devices, see above)

C enumeration: 

PHIGS_INDEX_COLOUR, PHIGS_TRUE_COLOUR

FORTRAN enumeration: 

PHIGSINDEXCOLOUR, PHIGSTRUECOLOUR

Sun_tool Attributes

PHIGS_TOOL_WIDTH  (C),  PHIGSTOOLWIDTH  (FORTRAN)

PHIGS_TOOL_HEIGHT

  (C),  PHIGSTOOLHEIGHT  (FORTRAN)

The initial size of the graphics window in screen coordinates. 

Data type: 

Pint  (C),  INTEGER  (FORTRAN)

Default: 

600, 600

PHIGS_TOOL_X  (C),  PHIGSTOOLX  (FORTRAN)

PHIGS_TOOL_Y

  (C),  PHIGSTOOLY  (FORTRAN)

The initial position of the workstation in screen coordinates. 

Data type: 

Pint  (C),  INTEGER  (FORTRAN)

Default: 

50, 50

PHIGS_TOOL_LABEL  (C),  PHIGSTOOLLABEL  (FORTRAN)
The label to put in the workstation frame banner.

Data type: 

Pchar∗  (C),  CHARACTER(∗)  (FORTRAN)

Default: 

PHIGS Workstation

PHIGS_TOOL_SHOW_LABEL  (C),  PHIGSTOOLSHOWLBL  (FORTRAN)
Specifies whether or not to display the frame banner.

Data type: 

Pint  (C),  LOGICAL  (FORTRAN)

Default: 

1 / .true. 

PHIGS_TOOL_ICON_FILE  (C),  PHIGSTOOLICONFL  (FORTRAN)
The file that contains the icon definition to use when the frame is closed.

Data type: 

Pchar∗  (C),  CHARACTER(∗)  (FORTRAN)

Default: 

A path to shared_files/phigs.icon

The default is a full path to the run time shared file, phigs.icon.  If this file is not present, the default value will be “” (none). 

PHIGS_TOOL_ICON_LABEL  (C),  PHIGSTOOLICONLBL  (FORTRAN)
The label to put in the icon when it is displayed.

Data type: 

Pchar∗  (C),  CHARACTER(∗)  (FORTRAN)

Default: 

SunPHIGS

PHIGS_TOOL_FOREGROUND_COLOUR  (C),  PHIGSTOOLFGDCLR  (FORTRAN)
The colour of the workstation frame border, specified as a red/green/blue triple, each element of the triple in the range [0,255].  This will also be the colour of the workstation valuator panel.

Note: The C value for this attribute is a pointer to a structure. 

Data type: 

struct singlecolor ∗  (C),  INTEGER, INTEGER, INTEGER  (FORTRAN)

Default: 

from cms_mono.h, entry 0

struct singlecolor is defined in pixrect/pixrect.h as:

struct singlecolor {
u_char  red, green, blue;
};

PHIGS_TOOL_BACKGROUND_COLOUR  (C),  PHIGSTOOLBKDCLR  (FORTRAN)
The colour of the label displayed in the workstation frame border, specified as a red/green/blue triple, each element of the triple in the range [0,255].

Note: The C value for this attribute is a pointer to a structure. 

Data type: 

struct singlecolor ∗  (C),  INTEGER, INTEGER, INTEGER  (FORTRAN)

Default: 

from cms_mono.h, entry 1

struct singlecolor is defined in pixrect/pixrect.h as:

struct singlecolor {
u_char  red, green, blue;
};

CGM Output Attributes

PHIGS_CGM_ENCODING  (C),  PHIGSCGMENCODING  (FORTRAN)
The encoding to use in generating the CGM file.  SunPHIGS will generate any of the three encodings defined by the CGM Standard (ANSI X3.122-1986). 

Data type: 

Phigs_cgm_encoding  (C),  INTEGER  (FORTRAN)

Default: 

Binary

C enumeration: 

PHIGS_CGM_BINARY, PHIGS_CGM_CHARACTER, PHIGS_CGM_CLEAR_TEXT

FORTRAN enumeration: 

PHIGSCGMBINARY, PHIGSCGMCHAR, PHIGSCGMCLEAR

PHIGS_CGM_CONFORMANCE  (C),  PHIGSCGMCONFORM  (FORTRAN)
Specifies the conformance of the CGM file.  TOP conformance ensures that all CGM elements generated will be in the permissible set defined by the Technical and Office Protocols (TOP).  TOP Basic conformance ensures that all elements will be in the basic set defined by TOP.  None will not ensure conformance to any special standard, other than CGM of course. 

Data type: 

Phigs_cgm_conformance  (C),  INTEGER  (FORTRAN)

Default: 

TOP

C enumeration: 

PHIGS_CGM_CONFORM_NONE, PHIGS_CGM_CONFORM_TOP, PHIGS_CGM_CONFORM_-
TOP_BASIC

FORTRAN enumeration: 

PCGMCNFRMNONE,   PCGMCNFRMTOP,   PCGMCNFRMTOPBASI

PHIGS_CGM_METRIC_HEIGHT_PTR  (C),  PHIGSCGMMTHEIGHT  (FORTRAN)

PHIGS_CGM_METRIC_WIDTH_PTR  (C),  PHIGSCGMMTWIDTH  (FORTRAN)
The physical drawing size in meters. By default, SunPHIGS generates a metafile that is dimensionless and is correctly displayed at any size.  If the height or width is set to a positive floating point value, then SunPHIGS generates a metafile with implied measure, and the picture is correctly displayed at the indicated drawing size only. 

Note: The data type for the C binding is a pointer to a Pfloat, not simply a Pfloat. 

Data type: 

Pfloat∗  (C),  REAL  (FORTRAN)

Default: 

-1.0, -1.0 (Dimensionless)

PHIGS_CGM_METRIC_LINE_WIDTH_PTR  (C),  PHIGSCGMMTLW  (FORTRAN)
The absolute nominal line width in millimeters. If this attribute is not specified, a device-dependent nominal line width will be applied at metafile interpretation time.

Note: The data type for the C binding is a pointer to a Pfloat, not simply a Pfloat. 

Data type: 

Pfloat∗  (C),  REAL  (FORTRAN)

Default: 

-1.0 (Dimensionless)

ERRORS

No Error

SEE ALSO

WORKSTATION TYPE CREATE (3P)
WORKSTATION TYPE DESTROY (3P)
WORKSTATION TYPE GET (3P)
OPEN WORKSTATION (3P)
INQUIRE LIST OF AVAILABLE WORKSTATION TYPES (3P)
INQUIRE WORKSTATION CONNECTION AND TYPE (3P)
PHIGS WORKSTATION DESCRIPTION TABLE(7)

Sun Release 4.0  —  Last change: 2 August 1989

Typewritten Software • bear@typewritten.org • Edmonds, WA 98026