readRGB() — Silicon Graphics
NAME
readRGB - returns values of specific pixels
SPECIFICATION
C
long readRGB(n, red, green, blue)
short n;
RGBvalue red[], green[], blue[];
FORTRAN
integer*4 function readRG(n, red, green, blue)
integer*4 n
character*(*) red, green, blue
Pascal
function readRGB(n: Short; var red, green, blue:
.B "RGBvalue): longint;"
DESCRIPTION
readRGB attempts to read up to n pixel values from the bitplanes. They are read into the red, green, and blue arrays starting from the current character position along a single scan line (constant y) in the direction of increasing x. readRGB returns the number of pixels actually read, which is only guaranteed to be the number requested if the starting point is at least that many away from the edge of the current viewport. The values of pixels read outside the current viewport are undefined. The current character position is updated to be one pixel to the right of the last one read, or is undefined if the new position is outside the viewport. The IRIS must be in RGB mode for this command to work.
SEE ALSO
readpixels, writeRGB
NOTE
This command can be used only in immediate mode.
Version 2.4 — May 08, 1986