Archive of the Gamebuino Classic wiki, recovered from the Wayback Machine (capture 2021-10-21). Read-only.
gb.display.getPixel
Description
Read the color of the pixel stored in the display buffer at the given coordinates.
Syntax
gb.display.getPixel(x, y);
Parameters
- x: horizontal coordinate. Should be between 0 (left of the display) and LCDWIDTH (right of the display)
- y: vertical coordinate. Should be between 0 (top of the display) and LCDHEIGHT (bottom of the display)
Returns
- color of the pixel. 0 for
WHITEand 1 forBLACK.