POV-Ray : Newsgroups : povray.general : Nested #switch...#end blocks - strange behaviour! : Re: Nested #switch...#end blocks - strange behaviour! Server Time
1 Aug 2024 02:15:53 EDT (-0400)
  Re: Nested #switch...#end blocks - strange behaviour!  
From: John VanSickle
Date: 15 May 2006 22:40:35
Message: <44693ba3$1@news.povray.org>


> High!
> 
> To differentiate multiple camera views according to the clock variable, 
> I set up a logical structure consisting of nested #switch...#end blocks 
> - only two levels deep, but a strange effect always occurred: when the 
> inner #switch block is reached, only either the first or the last 
> alternative is chosen, but not the ones in between. With this test 
> script, this means if I start with +k1.1 or +k1.2, I always only got 
> "One point ????" as #warning output... and, strangely, obviously line 2 
> is interpreted correctly (see output in line 4)! Is this a bug actually?

It could be floating point round-off error.  If you absolutely, 
positively expect it to be an integer, you really need to put floor() 
around any fraction multiplied by anything else.

Regards,
John


Post a reply to this message

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