setGreen method

void setGreen(
  1. int x,
  2. int y,
  3. num c
)

Set the value of the green channel at the given pixel coordinates x, y.

Implementation

void setGreen(int x, int y, num c) {
  if (green != null) {
    if (red!.isFloat) {
      green!.setFloat(x, y, c);
    } else {
      green!.setInt(x, y, c as int);
    }
  }
}