POV-Ray : Newsgroups : povray.advanced-users : "user-defined" isosurface : Re: "user-defined" isosurface Server Time
28 Jul 2024 10:15:16 EDT (-0400)
  Re: "user-defined" isosurface  
From: Leo80s
Date: 23 Jan 2006 10:25:00
Message: <web.43d4f4b03f7154a3f20c7750@news.povray.org>
>   User-defined functions in povray are a bit tricky because their syntax,
> while similar to the SDL syntax, is actually separate and different.
> You can use SDL constructs to build up a function body, but it's just
> that. The function body will be parsed with a completely separate parser
> (which will then internally compile it to bytecode etc) *after* the SDL
> constructs have been evaluated. Again, you can think about the difference
> between the C preprocessor and the C compiler. It's the same kind of
> difference.

What do you mean with "SDL constructs"?

>
>   What you are apparently trying to do is to create a user-defined
> function with a loop. That's not directly possible because the function
> syntax does not contain loop constructs.
>
>   Not all hope is lost, though, because user-defined functions support
> recursion. You can use the select() function (to stop the recursion) and
> recursive calls in order to create loops. If you have ever coded in a
> functional language such as Lisp, that should be a piece of cake.
>
>   I actually once (re)created the Mandelbrot set using recursive
> user-defined functions, so it's perfectly possible.

Sorry for my insistence but...
1) where can I find documentation about this select construct
2) Can you send me the code where you use recursive
> user-defined functions (if it's not a problem) ?

Very very thanks
Leo


Post a reply to this message

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