bitmap_print(3G)
NAME
bitmap_print, dcbitmap_print, intbitmap_print − print bitmap contents on a raster printer
SYNOPSIS
C Syntax:
void bitmap_print(fildes,formatter,config,print_mode,full,xstart,
ystart,xlen,ylen,rotate,foreground,background,noback)
int fildes;
char *formatter,*config;
int print_mode,full;
float xstart,ystart;
int xlen,ylen;
int rotate,foreground,background,noback;
void intbitmap_print(fildes,formatter,config,print_mode,full,xstart,
ystart,xlen,ylen,rotate,foreground,background,noback)
int fildes;
char *formatter,*config;
int print_mode,full,xstart,ystart,xlen,ylen,rotate,foreground,
background,noback;
void dcbitmap_print(fildes,formatter,config,print_mode,full,xstart,
ystart,xlen,ylen,rotate,foreground,background,noback)
int fildes;
char *formatter,*config;
int print_mode,full,xstart,ystart,xlen,ylen,
rotate,foreground,background,noback;
FORTRAN77 Syntax:
subroutine bitmap_print(fildes,formatter,config,
print_mode,full,xstart,ystart,xlen,ylen,rotate,
foreground,background,noback)
integer*4 fildes
character*(*) formatter,config
integer*4 print_mode,full
real xstart,ystart
integer*4 xlen,ylen
integer*4 rotate,foreground,background,noback
subroutine intbitmap_print(fildes,formatter,config,
print_mode,full,xstart,ystart,xlen,ylen,rotate,
foreground,background,noback)
integer*4 fildes
character*(*) formatter,config
integer*4 print_mode,full,xstart,ystart,xlen,ylen
integer*4 rotate,foreground,background,noback
subroutine dcbitmap_print(fildes,formatter,config,
print_mode,full,xstart,ystart,xlen,ylen,
rotate,foreground,background,noback)
integer*4 fildes
character*(*) formatter,config
integer*4 print_mode,full,xstart,ystart,xlen,ylen
integer*4 rotate,foreground,background,noback
Pascal Syntax:
procedure bitmap_print(fildes:integer;formatter,config:string255;print_mode,
full:integer;xstart,ystart:real; xlen,ylen,rotate,
foreground,background,noback:integer);
procedure intbitmap_print(fildes:integer;formatter,config:string255;
print_mode,full,xstart,ystart,xlen,ylen,rotate,foreground,
background,noback:integer);
procedure dcbitmap_print(fildes:integer;formatter,config:string255;
print_mode,full,xstart,ystart,xlen,ylen,rotate,foreground,
background,noback:integer);
DESCRIPTION
Input Parameters
fildes Integer file descriptor returned by gopen when the I/O path of a bitmap device is opened.
formatter Character representation of the formatter to be selected. The only formatter supported by Starbase is the pcl ("pcl"). See Starbase Device Drivers Library (formatter sections) for details. If non-supported formatters are used, see the documentation supplied with them.
config Pathname of a configuration file where information pertaining to the raster formatter and output device will be found. The contents of this file are formatter-dependent.
print_mode Integer value indicating how the data is to be read. If print_mode is non-negative, it specifies a single plane to be printed; if it exceeds the number of planes available, a failure indication is returned. If print_mode is negative or equals ALL_PLANES (-1), all display-enabled planes are printed.
full If TRUE (1), indicates that the full extent of the bitmap is to be printed. The parameters xstart, ystart, xlen, and ylen are ignored. If FALSE (0), the rectangle specified by the next four parameters is printed.
xstart, ystart Specifies the upper-left corner of the source rectangle in virtual device coordinates (bitmap_print, intbitmap_print) or device coordinates (dcbitmap_print).
xlen, ylen Lengths (in pixels) of the sides of the rectangle to be printed.
rotate If TRUE (1), indicates that the formatter should rotate the rectangle 90 degrees for output (the direction of rotation is formatter-dependent). If FALSE (0), the formatter-dependent default orientation is used.
foreground, background
Specify color map indices to be used when printing a single plane. The color corresponding to foreground is printed for ones in the source, and the color corresponding to background is printed for zeroes (however, see the noback parameter, below).
noback If TRUE (1), the color map index specified by background is mapped to no color; that is, it is not printed. This parameter applies, whether a single plane or all planes are being printed. If FALSE (0), the background color in the bitmap (or the specified background color if a single plane) is printed just as any other color.
Discussion
Pixel data is considered to be an xlen by ylen pixel rectangle for the following discussion. The pixel data from the source is read, beginning at upper-left corner xstart,ystart for the entire rectangle defined by xlen,ylen; however, if the full parameter is TRUE, the rectangle is determined by the bitmap extent. The source is clipped against the current clip rectangle.
RGB information is converted by the formatter (through dithering) according to the capabilities of the output device. Actual data written is controlled by the formatter and the configuration file. The formatter may clip the data as necessary to fit the output medium.
Only currently displayed planes are printed. Non-displayed planes are interpreted as zeroes. If double-buffering is enabled, the currently displayed buffer is printed.
For all-planes operation with multi-bank graphics devices, the currently selected bank (as set by bank_switch) is printed. If the current shade mode is CMAP_FULL, all appropriate banks are printed.
Conditions under which the operation fails include specification of an invalid formatter string (one not found in the formatter table linked with the program); and conditions under which the formatter itself returns a failure indication. Inquire_gerror(3G) can be used to determine the error.
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.
SEE ALSO
file_print(3G), Starbase Device Drivers Library Manual.
Hewlett-Packard Company — HP-UX Release 9.03: April 1994