POV-Ray : Newsgroups : povray.programming : #ifdef(array[index]) : #ifdef(array[index]) Server Time
29 Jul 2024 02:29:42 EDT (-0400)
  #ifdef(array[index])  
From: Mikael Carneholm
Date: 22 Oct 1998 10:16:13
Message: <362F2EA6.5AF2@ida.utb.hb.se>


#ifndef(array[index])
   ...
#end

or, alternatively, some way to convert strings to identifiers, like
this:

#declare iteration=0;
#while(iteration<10)
   #ifdef(concat("variable_",str(iteration,0,0)))
      ...
   #end
   #declare iteration=iteration+1;
#end

...which would allow me to see if variable_0, variable_1, variable_2
etc. has been declared.

- Mikael.


Post a reply to this message

Copyright 2003-2023 Persistence of Vision Raytracer Pty. Ltd.