POV-Ray : Newsgroups : povray.general : recursion problem : Re: recursion problem Server Time
4 Aug 2024 14:28:11 EDT (-0400)
  Re: recursion problem  
From: Remco de Korte
Date: 16 Apr 2003 17:49:10
Message: <3E9DCFBF.E33F7F56@onwijs.com>
Lenx wrote:
> 
> i am quiet new to recursion, and i have some problems with it.
> now i tried to do some recursion in pov like a pyramid, what worked, but i
> want to do more.
> 
> what i want to create now is a box, with on the top corners of that box a
> new box (eg 10 times smaller than the first box).
> on top of the 4 new little boxes you have the same thing.
> i want to do this for about 4 levels with recursion. can anyone piont me to
> some tutorial or maybe has a similar macro i can learn from?
> my problem is that i don't know how to put 4 boxes on the top, and that
> while the recusion is looped once. next loop again.. and go on. I can do it
> with one box, but there it stops.
> 
> i have a similar problem for a programming task for school. maybe i can
> solve it when i understand the pov version :-]
> 
> regards, lenx

You need a level counter. 

Remco


Post a reply to this message

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