image functions - continued

XgrDrawImageScaled  ( grid, imageGrid, startX, startY, endX, endY, dx, dy )

XgrDrawImageScaled() draws imageGrid in grid at dx, dy.

(startX,startY:endX,endY) are pixel offsets into the image.  The left and/or upper portion of an image is skipped if startX and/or startY is non-zero.  The right and/or lower portion of an image is not drawn if endX and/or endY is reached before the imageGrid is exhausted.  If endX and/or endY is zero, endX and/or endY are set to the x and/or y limits of the image.

Drawing is not performed outside the grid-box.

XgrDrawImageScaled() interprets image data as scaled coordinates, therefore it will zoom (enlarge and compress) images of drawings, icons, and video images.

XgrDrawImageScaled() is a slow operation.

XgrGetImage  ( grid, @image[] )

XgrGetImage() returns the image[] array from grid . This copy of the image in grid is in 24-bits per pixel DIB format, with 8-bits each for red,green,blue . 

XgrGetImageArrayInfo  (@image[], @bitsPerPixel, @width, @height )

XgrGetImageArrayInfo() returns information about the image in XLONG array image[] . The contents of image[] must be in valid DIB format.

XgrGetImageArrayInfo() returns the number of bitsPerPixel, and the image (width,height) in pixels.