Functions

Array(header) Constructor
Array:clear() Clear the array
Array.components GETSET The number of components
Array.dim GETSET The data dimension
Array:getcell(coords) Get the values of a array cell
Array.header GETSET The array header
Array:read(coords) Read values of an interpolated array location
Array:setcell(coords, ...) Set a cell of the array with a value
Array.type GETSET The data type
Array:write(coords, values) Write values to an interpolated array location

Functions

Array(header)

Constructor

Parameters:

header Array header

Return:

  • The Array
Array:clear()

Clearing the array sets all values to 0

Array.components GETSET

Setting the number of components will reformat its memory.

Array.dim GETSET

Setting the data dimension will reformat its memory.

Array:getcell(coords)

Get the values of a array cell

Parameters:

coords The coordinates of the cell to get

Return:

  • The value
Array.header GETSET

Setting the array header will reformat its memory.

Array:read(coords)

Read values of an interpolated array location

Parameters:

coords The coordinates of the cell to get

Return:

  • The value
Array:setcell(coords, ...)

Set a cell of the array with a value

Parameters:

coords The coordinates of the cell to set
... The value to set as a table or unpacked values
Array.type GETSET

Setting the data type will reformat its memory.

Array:write(coords, values)

(values are 'spread' over neighboring cells)

Parameters:

coords The coordinates of the cell to set
values The value to set (as a table)

Return:

  • The value