Image.transparent Method

Sets the transparent color for the image.

Syntax

public int transparent(
   [boolean Set, 
    int RValue, 
    int GValue, 
    int BValue])

Run On

Client

Parameters

  • Set
    Type: boolean
    If set to true, the transparent color is used when creating or displaying the image. If set to false, the transparent color is saved for later use. This parameter is optional.
  • RValue
    Type: int
    Red value of the color that you want to set; optional.
  • GValue
    Type: int
    Green value of the color that you want to set; optional.
  • BValue
    Type: int
    Blue value of the color that you want to set; optional.

Return Value

Type: int
0 to indicate success; otherwise, failure.

Remarks

If any of the input parameters are missing, the color at the point (0,0) in the image is used. If you want to specify a color, this is expressed as an RGB color by using parameters 2 to 4.

See Also

Reference

Image Class