Previous Next Up Title Contents Index Top Library

1.2. OPENING A CGM WORKSTATION

GPHIGS creates a CGM (Computer Graphics Metafile) file. The name of the file is defined by the connection identifier parameter of OPEN WORKSTATION.

C syntax:

popen_ws (ws_id , "my_file" , PWS_TYPE_CGM_CLEAR_TEXT);

FORTRAN syntax:

OPEN(CONNID,FILE='my_file')

CALL POPWK(WKID,CONNID,10)

The file generated is in clear text format if type number 10 or 12 are used, or binary encoding if 11 or 13.

Integer VDC type drivers ( type 10 and 11) generates integers ranging from -32767 to 32767.

Real VDC type drivers (type 12 and 13) generates floats ranging from 0 to 2. Plotting which require metric precision can use the real VDC type to achieve full precision. In this case, 1 in VDC unit equals 1 metre. The default device coordinate represents 2 metres. The SET WORKSTATION VIEWPORT function can be used to locate the picture in the metric space. The %ds directive can be used to define precisely the DC space in metres required by the application.


Previous Next Up Title Contents Index Top Library