NAME
line_repeat_Iength, intline_repeaLlength - specify line pattern length for line primitives SYNOPSIS
C Syntax:
void line_repeaClength(fildes,length);
int fildes;
float length;
void intline_repeaClength(fildes,length);
int fildes,length;
FORTRAN77 Syntax:
subroutine line_repeat_Iength(fildes,length) integer*4 fildes
real length
subroutine intline_repeat_Iength(fildes,length) integer*4 fildes,length
Pascal Syntax:
procedure line_repeaClength(fildes:integer;length:real);
procedure intline_repeaLlength(flldes,length:integer);
DESCRIPTION Input Parameters
fildes length Discussion
Integer file descriptor returned by gopen when an I/O path to a graphics device is opened.
Repeat length of the line-type pattern measured in virtual device units along the x-direction.
This procedure sets the repeat length for polyline and draw output primitives.
There are some device-dependent limitations for setting repeat length. Some raster devices round to the nearest multiple of 16 pixels.
Integer operations are only available when using the INT _XFORM gopen mode. When in INT _XFORM mode, floating point operations are not available for that fildes. Floating point operations are the default, or can be specified with FLOAT _XFORM mode. For a list of integer operations, floating point operations and common operations see the starbase.3g manual page.
DEFAULT
Repeat length is 1/32 of the default vdc_extent x-axis.
SEE ALSO
line_type(3G), perimetecrepeaUength(3G).
142 (Section 3) - 1 - HP-UX Release 7.0: September 1989
LINE_ TYPE(3G)
NAME
line_type - select line type for all subsequent line primitives SYNOPSIS
Predefined line types are described below:
~i~4~~=~========~~~~========~===~PJ;~~~~~=~;!~e!;===:
1 ___ 'Z-___ L~g~Ig~=Q~~!i~QA~Ij_j_~~_.:.!...:!~L·l_}_J~
______ _'
Negative style values are device-dependent. For example, -1 is a point plot on a terminal.
Continuity between separate, but graphically connected, polyline or line segments is not guaranteed.
The pattern is restarted each time this procedure is executed.
Wide lines do not support line types.
Some devices do not support this procedure.
DEFAULTS Solid Lines.
SEE ALSO
line_repeaUength(3G), perimetectype(3G), Starbase Device Drivers Library.
HP-UX Release 7.0: September 1989 - 1 - (Section 3) 143
LINE_ WIDTH(3G) LINE_ WIDTH(3G)
NAME
intline_ width, line_width - set line width.
SYNOPSIS
integer file descriptor returned by gopen when an I/O path to a graphics device is opened.
is width of a line in units specified by mode.
a value specifying the units of width:
MC_UNITS modelling coordinates VDC_UNITS = virtual device coordinates
Intline_width and line_width set the line width for subsequent polyline2d, intpolyline2d, intdraw2d, and draw2d calls.
If mode is MC_UNITS, width should be given in modelling coordinate units.
If mode is VDC_UNITS, width should be given in virtual device coordinate units.
Line width is measured by aligning a wide line with its ideal default-width defining line such that the distance between the defining line and either edge is half the line width.
Integer operations are only available when using the INT _XFORM gop en mode. When in INT _XFORM mode, floating point operations are not available for that file descriptor. Floating point operations are the default, or can be specified explicitly with FLOAT_XFORM mode.
Device cannot be gopened with the THREE_D mode for line_width to work; it is intended for 20 usage only. For a list of integer operations, floating point operations, and common operations, see the starbase(3G) manual page.
Note: Line_type does not apply to wide lines (width greater than zero). It is ignored. When the mapping of the VDC space to device is anisotropic because of a vdc_extent call, the rendered width of a line will change with the direction of the line segment.
DEFAULTS
width
=
0.0; 1 pixel width.SEE ALSO
draw(3G), line_endpoint(3G), polyline(3G), Starbase Graphics Techniques.
144 (Section 3) - 1 - HP-UX Release 7.0: September 1989
NAME
make_Xl Lgopen_string - create a path string associated with an existing X window SYNOPSIS
C Syntax:
#inc1ude <Xll/Xlib.h>
char *make_X1Lgopen_string(display, drawable);
Display *display;
Drawable drawable;
FORTRAN77 SYNTAX
subroutine make_Xll_gopen_string(display, drawable, dey _string) integer*4 display
integer*4 drawable character*(*) dey _string DESCRIPTION
Input Parameters display drawable
The display where the drawable exists.
The drawable that is to be gopened.
Output Parameters
dey_string The string, associated with an existing XlI window, that can be passed as the path parameter to gopen(3G).
Returned Value
If successful, make_XILgopen_string returns the address of a string. If unsuccessful, make_XILgopen_string returns NULL. For FORTRAN77 programs, the memory for the display string must be provided as a third parameter.
Discussion
This routine provides support for associating an existing XII Window with a string that can be passed as the path parameter to gopen(3G).
The display argument specifies the XII display that the drawable was created on. The drawable argument specifies the id of the Window that gopen should access. The memory for the string is obtained, by the routine, using malloc(3C), malloc(3X), and can be released using free(3C). This is not necessary for programs using the FORTRAN77 entry point.
Note that no Pascal syntax is shown above. This is because there are Xlib bindings for C and FORTRAN77 only, so a Pascal program would need to use the C bindings in order to call this routine. Refer to the appendixes of Programming With Xlib for more information.
SEE ALSO
gopen(3G), malloc(3C), malloc(3X), Starbase Programming with X11.
HP-UX Release 7.0: September 1989 - 1 - (Section 3) 145
MAKE_PICTURE_ CURRENT (3G) MAKE_PICTURE_ CURRENT (3G)
NAME
make_picture_current - output buffered primitives to display and wait for display hardware to finish
SYNOPSIS C Syntax:
void make_picture_current(fildes);
int fildes;
FORTRAN77 Syntax:
subroutine make_picture3urrent(fildes) integer*4 fildes
Pascal Syntax:
procedure make_picture_current(fildes:integer);
DESCRIPTION Input Parameters
fildes Integer file descriptor returned by gopen when an I/O path to a graphics device is opened.
Discussion
Make_picture_current outputs any previous primitives that may still be in the device or driver buffers to the display device fildes. Next, the command waits for the display hardware to finish its processing in order to guarantee that when the subroutine returns, all pixels will be displayed.
It is commonly used:
in interactive graphics sessions at points where the operator must see the entire image in order to proceed,
or in hard-copy graphics at the end of the picture generation process such as when transferring an image from the raster buffer to the printed page in a buffered raster printer.
Gelose also performs a make_picture_current operation before closing the device.
Note that make_picture_current will degrade performance, especially on accelerated devices, since the CPU will wait for the graphics device to finish all of its processing. Therefore this procedure should be used with caution. For better performance, use flush_buffer which causes all output buffers to be flushed, but does not wait for the device to finish before returning. This allows more parallel processing with accelerated devices, while still bringing the picture up to date just as fast as make_picture_current.
SEE ALSO
buffecmode(3G), flush_buffer(3G), gclose(3G).
146 (Section 3) - 1 - HP-UX Release 7.0: September 1989
MAPPING_MODE (3G) MAPPING_MODE (3G)
NAME
mapping_mode - define vdc extent mapping to viewport as isotropic or anisotropic SYNOPSIS
C Syntax:
void mapping_mode(fildes,distort);
int fildes,distort;
FORTRAN77 Syntax:
subroutine mapping_mode(fildes,distort) integer*4 fildes,distort
Pascal Syntax:
procedure mapping_mode(fildes,distort:integer);
DESCRIPTION Input Parameters
fildes Integer file descriptor returned by gopen when an I/O path to a graphic device is opened.
distort
Discussion
If TRUE (1), distorted mapping from virtual device coordinates to device coordi-nates is performed.
If FALSE (0), the mapping is not distorted.
When mapping mode is distorted (anisotropic), the viewport occupies the full physical region of interest (set by set_pLp2), with no space left unused in the region. This is referred to as a 2-point scaling or "rubbering" and does not preserve aspect ratio. The numbers corresponding to vdcextent span the entire physical region of interest.
When mapping mode is not distorted (isotropic), the viewport is calculated as the largest rectan-gle within the physical region of interest that preserves the aspect ratio of the vdc_extent. Unless this matches the aspect ratio of the physical region of interest, some "white space" will be left unused outside the physical region of interest. By default, this white space is distributed equally on the two sides of the viewport unless modified by the vdc_justification procedure.
This procedure updates the current vdc-to-device units transformation matrix. If no matrices have been placed on the matrix stack and no viewing transformations have been defined, the new vdc matrix becomes the current viewing transformation. Otherwise, no other transforma-tion matrices are affected.
To ensure correct handling of text size and tracking relationships, mapping_mode should be called prior to setting text size and tracking. This procedure also may change the number of passes required for hidden surface removal, so hidden surface removal should be disabled while setting the mapping mode.
DEFAULTS