This function obtains an arbitrary line of pixels from the DIB image bitmap of the image referenced by hIGear.
Copy Code
|
|
---|---|
AT_ERRCOUNT ACCUAPI IG_DIB_line_get (
HIGEAR hIGear,
AT_PIXPOS nX1,
AT_PIXPOS nY1,
AT_PIXPOS nX2,
AT_PIXPOS nY2,
LPAT_PIXEL lpPixel,
const AT_DIMENSION nlenOfArray,
LPAT_DIMENSION lpNumPixels
);
|
Name | Type | Description |
---|---|---|
hIGear | HIGEAR | HIGEAR handle of image. |
nX1 | AT_PIXPOS | X coordinate of the first endpoint of line to get. |
nY1 | AT_PIXPOS | Y coordinate of the first endpoint. |
nX2 | AT_PIXPOS | X coordinate of the second endpoint of line. |
nY2 | AT_PIXPOS | Y coordinate of the second endpoint. |
lpPixel | LPAT_PIXEL | Far pointer to your data area to which the pixels should be returned. |
nLenOfArray | const AT_DIMENSION | Length, in bytes, of lpPixel block. |
lpNumPixels | LPAT_DIMENSION | Far pointer to an AT_DIMENSION variable in which the number of pixels (not bytes) transferred is returned. |
Returns the number of ImageGear errors that occurred during the function call. If there are no errors, the return value is IGE_SUCCESS.
All pixel formats supported by ImageGear for C and C++.
See the example for function IG_DIB_line_set().
The line of pixels does not have to be horizontal or vertical. nX1,nY1 are the coordinates of one endpoint of the line and nX2,nY2 are of the other.
If the pixel data would overflow your area (nLenOfArray), the transfer will be truncated; your data area will not be overflowed. The actual number of pixels returned will be stored in your variable pointed to by lpNumPixels.
1-bit and 4-bit pixels are returned one to a byte, right justified. 24-bit pixels are returned 3 bytes per pixel, in Blue-Green-Red order.