|
|
POV 3.5 b 10, win
I am trying to do some math with 4D vectors, and it leads to a variety of
problems, including abnormal termination of PovRay. I have not yet pinned
down most of the problems, here is a simple one:
When I run :
#macro test()
<1, 1, 1, 1>
#end
#declare aa = array[2] {<1, 1, 1, 1>, <1, 0, 1, 1>}
#declare bb = array[2] {test(), <1, 0, 1, 1>}
there is a parsing error on 'bb', 'insufficient number of initialisers'.
More generally, I never managed to initialise an array with a macro
returning a 4D vector.
If the order is changed :
#declare bb = array[2] {<1, 0, 1, 1>, test()}
the parsing error is then 'Attempted to redefine 4d-vector identifier as
object identifier'.
On the other hand
#declare vv = test();
#declare bb = array[2] {vv, <1, 0, 1, 1>}
is OK.
Michel Mouly
Post a reply to this message
|
|