getPixel method

int getPixel(
  1. int x,
  2. int y
)

Get the pixel from the given x, y coordinate. Color is encoded in a Uint32 as #AABBGGRR. No range checking is done.

Implementation

int getPixel(int x, int y) => data[y * width + x];