setClear method

dynamic setClear(
  1. double r,
  2. double g,
  3. double b,
  4. double a,
  5. bool premultipliedAlpha,
)

Implementation

setClear(double r, double g, double b, double a, bool premultipliedAlpha) {
  if (premultipliedAlpha == true) {
    r *= a;
    g *= a;
    b *= a;
  }

  color.set(r, g, b, a);

  if (currentColorClear.equals(color) == false) {
    gl.clearColor(r, g, b, a);
    currentColorClear.copy(color);
  }
}