LuaBox
Loading...
Searching...
No Matches
DisplayGetPixel.h File Reference
#include "lua_include.h"
#include "global.h"

Go to the source code of this file.

Functions

int DisplayGetPixel (lua_State *L_)
 Get the color of a pixel from the sprite buffer.

Function Documentation

◆ DisplayGetPixel()

int DisplayGetPixel ( lua_State * L_)

Get the color of a pixel from the sprite buffer.

This function reads the color of a specific pixel from the sprite buffer. The color is returned as a 16-bit RGB565 value.

Parameters
L_Lua state; expects arguments in order: 1: x (X coordinate of the pixel) 2: y (Y coordinate of the pixel)
Returns
int Returns 1 value on the Lua stack:
  • 16-bit RGB565 color of the pixel at the specified coordinates.