POV-Ray : Newsgroups : povray.advanced-users : user defined function : Re: user defined function Server Time
28 Jul 2024 12:22:45 EDT (-0400)
  Re: user defined function  
From: Warp
Date: 11 Jan 2006 07:43:21
Message: <43c4fd69@news.povray.org>
Leo80s <nomail@nomail> wrote:
> I need to understand exactly how can I specify in POV-RAY a
> user-defined-function...I read many guide and tutorial and I have not
> understand if it's possible or not...for example: I need to define a
> function that take 3 parameters (a,b,c) and give in output sqrt
> (a^2+b^2+c^2)...Can somebody send me an example and tell me exactly where I
> have to put this function's code in a povray source file?

#declare MyFunction = function(a,b,c) { sqrt(a*a+b*b+c*c) };

-- 
                                                          - Warp


Post a reply to this message

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