ImgSetPixel |
Top Previous Next |
Prototype
ImgSetPixel(intImageHandle; intX,intY;intColor)
Description
Sets the color of a specific pixel element using x and y coordinates.
Parameters
intImageHandle: integer value corresponding to the image handle.
intX: integer value corresponding to the column.
intY: integer value corresponding to the line.
intColor: numeric value showing the color for the pixel.
Returned value
None.
Notes
None.
Example
// Store pixel color caught from a different area from background. ColorPixel:=ImgGetPixel(_CurrentImage,10,10);
// Extracting width and height width:=ImgGetWidth(_CurrentImage); height:=ImgGetHeight(_CurrentImage);
// Printing a border around current image using ColorPixel for x:=0 to width-1 do begin ImgSetPixel(_CurrentImage,x,0,color); ImgSetPixel(_CurrentImage,x,height-1,color); end; for y:=0 to height-1 do begin ImgSetPixel(_CurrentImage,0,y,color); ImgSetPixel(_CurrentImage,width-1,y,color); end;
ApplicationLog('Drawing');
|