POV-Ray : Newsgroups : povray.general : Still making newbie mistakes : Re: Still making newbie mistakes Server Time
29 Jul 2024 10:28:41 EDT (-0400)
  Re: Still making newbie mistakes  
From: Christian Froeschlin
Date: 25 Mar 2013 14:13:23
Message: <515093c3$1@news.povray.org>
BTW I never really thought much about this but I think I exclusively
use macros to return complete entities (union, texture, function,...).

In this case it would be something like (untested online code snippet)

#macro Basic_shape (Rpipe, Rsaddle)
function
{
   1 - sqrt(...)
}
#end

#declare f_basic_shape = Basic_shape(0.4,0.4)

isosurface
{
   function { max (f_basic_shape(x,y,z), -f_basic_shape(x,y,z) ) }
   ...
}

Probably avoids a whole lot of trouble ;)


Post a reply to this message

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