XdWriteBitmap(3X) — Kubota Pacfic Computer Inc. (X Direct Graphics)
NAME
XdWriteBitmap − output a rectangle of 1 bit deep pixels
SYNOPSIS
void XdWriteBitmap(wh, xSrc, ySrc, xDst, yDst, w, h,
imageWidth, pImage, fg, bg)
WindowHandle ∗wh;
int xSrc, ySrc;
int xDst, yDst;
unsigned int w, h;
int imageWidth;
unsigned short ∗pImage;
unsigned long fg, bg;
wh Specifies the window to draw into
xSrc, ySrc Specifies the top left hand corner of the image data to be written to the window
xDst, yDst Specifies where the image data is to be positioned within the window
w, h Specifies the width and height of the image to be written to the window
imageWidth Specifies the width of each scanline of the source in pixels
pImage Specifies a pointer to the image data
fg, bg Specifies the foreground and background colors used to draw the image data
USAGE
Use XdWriteBitmap to output a rectangle of 1 bit deep pixels. All scanlines must be of the same width and this width must be a multiple of 32.
The XdWriteBitmap function allows some sub-rectangle of the total image specified to be written to the screen. Where in the image a 1 is specified the foreground color fg is used and where in the image a 0 is specified the background color bg is used. The format of fg and bg is the same as for other standard Xlib calls: namely in a pseudo color window it is a color index, in a direct color window it has the form 0x00rrggbb, where rr, gg and bb specify the red, green, and blue indices in the color map.
September 02, 1992