index method Null safety
Get the buffer index for the x
, y
pixel coordinates.
No range checking is done.
Implementation
int index(int x, int y) => y * width + x;
Get the buffer index for the x
, y
pixel coordinates.
No range checking is done.
int index(int x, int y) => y * width + x;