POV-Ray : Newsgroups : povray.general : POV crash with functions : Re: POV crash with functions Server Time
3 Aug 2024 20:14:14 EDT (-0400)
  Re: POV crash with functions  
From: Thorsten Froehlich
Date: 10 Nov 2003 19:21:13
Message: <3fb02b79$1@news.povray.org>
In article <3fafe73e@news.povray.org> , "JC (Exether)" <no### [at] spamfr> wrote:

> #macro F_Plane ()
>    #local fn_p=function (x,y,z) { y };
>    fn_p
> //  function (x,y,z) { fn_p (x,y,z) }
> #end

This isn't legal syntax and POV-Ray cannot currently detect this properly.

To do what you want, use #declare instead of #local like this:

#macro F_Plane ()
   #undef fn_p
   #declare fn_p=function (x,y,z) { y };
   fn_p
#end

    Thorsten

____________________________________________________
Thorsten Froehlich, Duisburg, Germany
e-mail: tho### [at] trfde

Visit POV-Ray on the web: http://mac.povray.org


Post a reply to this message

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