" />

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 WHITE and 1 for BLACK.

0