PixelData
Data structure containing video data.
This structure is used to provide lua with an optimized way to do GetPixel and SetPixel, the buffer is kept on the lua side minimizing read and write overhead.
Static Methods
PixelData.new( width number, height number, color color ) PixelData
Constructor used to create a PixelData.
width
andheight
represent its size whilecolor
defines thecolor
with which it is initialized.
Properties
Width in pixels of the buffer.
Height in pixels of the buffer.
Methods
GetPixel( x number, y number ) color
Returns the color of the pixel at the coordinate specified by
x
andy
.
SetPixel( x number, y number, color color )
Sets the
color
of the pixel at the coordinate specified byx
andy
.