POV-Ray : Newsgroups : povray.newusers : giving varying object names to macros?? : Re: giving varying object names to macros?? Server Time
2 Nov 2024 03:15:07 EDT (-0400)
  Re: giving varying object names to macros??  
From: Florian Brucker
Date: 19 Sep 2004 14:57:10
Message: <414dd686$1@news.povray.org>
> but this does not work in povray, does it?

If I understand you correctly, you want to do something like this (code 
from shapes.inc):

#macro Isect(Pt, Dir, Obj, OPt)
    #local Norm = <0,0,0>;
    #local IPt = trace(Obj, Pt, Dir, Norm);
    #if (vlength(Norm) > 0)
       #declare OPt = IPt;
       #local Return=true;
    #else
       #local Return=false;
    #end
    (Return)
#end

HTH,
Florian
-- 
$ping http://www.real-life.org
ping: unknown host
[------------ http://www.torfbold.com - POV-Ray gallery ------------]


Post a reply to this message

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