AT&T UNIX™PC Unix System V Users Manual - tenox

AT&T UNIX™PC Unix System V Users Manual - tenox AT&T UNIX™PC Unix System V Users Manual - tenox

01.01.2013 Views

WIND (3T) (AT&T UNIX PC only ) WIND (3T) BUGS number. A negative number indicates an error, as defined in wind.h. Pjont is currently ignored. - 2-

WRASTOP ( 3T ) ( AT&T UNIX PC only ) WRASTOP ( 3T ) NAME wrastop - pixel raster operations for bitmap displays SYNOPSIS #include int wrastop(w, srcbase, srcwidth, dstbase, dstwidth, srcx, srcy, dstx, dsty, width, height, srcop, dstop, pattern) int w; unsigned short *srcbase, *dstbase, *pattern; unsigned short srcwidth, dstwidth; unsigned short srcx, srcy, dstx, dsty; char srcop, dstop; DESCRIPTION The wrastop routine provides user programs with direct access to a window 's pixel data. This "raster operation" is controlled by the arguments which include both source and destination operators: /* rastop source operators * / #define SRCSRC 0 /* source * / #define SRCPAT 1 /* pattern */ #define SRCAND 2 /* source and pattern * / #define SRCOR 3 /* source or pattern * / #define SRCXOR 4 /* source xor pattern * / /* rastop destination operators * / #define DSTSRC 0 /* srcop(src) * / #define DSTAND 1 /* srcop(src) and dst * J #define DSTOR 2 /* srcop( src) or dst * / #define DSTXOR 3 /* srcop(src) xor dst * / #define DSTCAM 4 /* not(srcop) and dst */ W is the window identifier for the window to be accessed (see tam(3T) for more information on window identifiers). The srcbase and dstbase arguments determine the memory addresses of the source and destination planes. Srcbase and dstbase may point to the address of the first short of an arbitrarily-sized array of shorts. Each row of pixels consists of srcwidth (or dstwidth ) number of bytes from this array. Thus, the first pixel row exists from srcbase to ((char *)srcbase) + srcwidth . Within each short, the least significant bit is the left-most when displayed on the screen. Alternatively, srcbase and/or dstbase may contain 0, in which case the source or destination is assumed to be the window specified by the first arg to the call. The caller need not supply any value for the srcwidth if srcbase is 0, nor dstwidth if dstbase is zero. It is therefore possible to perform raster operations from user space to user space, user space to screen, screen to user space, or screen to screen. The srcx, srcy, dstx , and dsty parameters contain pixel addresses within the specified pixel plane. 0,0 is always the upper-left-hand corner of the display. Note that raster operations are completely - 1 -

WRASTOP ( 3T ) ( AT&T UNIX PC only ) WRASTOP ( 3T )<br />

NAME<br />

wrastop - pixel raster operations for bitmap displays<br />

SYNOPSIS<br />

#include <br />

int wrastop(w, srcbase, srcwidth, dstbase, dstwidth,<br />

srcx, srcy, dstx, dsty, width, height,<br />

srcop, dstop, pattern)<br />

int w;<br />

unsigned short *srcbase, *dstbase, *pattern;<br />

unsigned short srcwidth, dstwidth;<br />

unsigned short srcx, srcy, dstx, dsty;<br />

char srcop, dstop;<br />

DESCRIPTION<br />

The wrastop routine provides user programs with direct access to<br />

a window 's pixel data. This "raster operation" is controlled by<br />

the arguments which include both source and destination operators:<br />

/* rastop source operators * /<br />

#define SRCSRC 0 /* source * /<br />

#define SRCPAT 1 /* pattern */<br />

#define SRCAND 2 /* source and pattern * /<br />

#define SRCOR 3 /* source or pattern * /<br />

#define SRCXOR 4 /* source xor pattern * /<br />

/* rastop destination operators * /<br />

#define DSTSRC 0 /* srcop(src) * /<br />

#define DSTAND 1 /* srcop(src) and dst * J<br />

#define DSTOR 2 /* srcop( src) or dst * /<br />

#define DSTXOR 3 /* srcop(src) xor dst * /<br />

#define DSTCAM 4 /* not(srcop) and dst */<br />

W is the window identifier for the window to be accessed (see<br />

tam(3T) for more information on window identifiers). The<br />

srcbase and dstbase arguments determine the memory addresses<br />

of the source and destination planes. Srcbase and dstbase may<br />

point to the address of the first short of an arbitrarily-sized array<br />

of shorts. Each row of pixels consists of srcwidth (or dstwidth )<br />

number of bytes from this array. Thus, the first pixel row exists<br />

from srcbase to ((char *)srcbase) + srcwidth . Within each short,<br />

the least significant bit is the left-most when displayed on the<br />

screen.<br />

Alternatively, srcbase and/or dstbase may contain 0, in which<br />

case the source or destination is assumed to be the window<br />

specified by the first arg to the call. The caller need not supply<br />

any value for the srcwidth if srcbase is 0, nor dstwidth if dstbase<br />

is zero. It is therefore possible to perform raster operations from<br />

user space to user space, user space to screen, screen to user space,<br />

or screen to screen.<br />

The srcx, srcy, dstx , and dsty parameters contain pixel addresses<br />

within the specified pixel plane. 0,0 is always the upper-left-hand<br />

corner of the display. Note that raster operations are completely<br />

- 1 -

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!