Image.setPixel Method

Sets the color for the pixel that is specified by the x and y parameters.

Syntax

public int setPixel(
    int x, 
    int y, 
    int pixel)

Run On

Client

Parameters

  • x
    Type: int
    TheX coordinate of the pixel for which you want to set the color.
  • y
    Type: int
    TheY coordinate of the pixel for which you want to set the color.
  • pixel
    Type: int
    The ARGB value of the color that you want to use.

Return Value

Type: int
0 indicates success; otherwise, failure.

Remarks

To convert an RGB color value to an ARGB value, use the .

See Also

Reference

Image Class