Previous page Next page

Arrays Added

Added multi-dimension arrays

  #declare MyArray=array[20]

or

  #local PrivateArray=array[30]

or

  #declare Rows=5; #declare Cols=4;

  #declare Table=array[Rows][Cols]

Added optional initializer syntax for arrays.

 #declare MyArray=array[2][3]{{1,2,3},{4,5,6}}

Subscripts start at 0. Anything that can be declared may be in an array. Arrays are initialized as null. You must later fill each element with values.

Added float functions for arrays. Given #declare MyArray = array[4][5] then dimensions(MyArray) is 2 and dimension_size(MyArray,2) is 5.

Previous page Next page