|
![](/i/fill.gif) |
On Sun, 02 Aug 1998 16:31:07 -0500, Lothar Esser
<ess### [at] chop swmed edu> wrote:
>Can anyone tell me where the code for Normal () is ?
>( Normal has been defined in frame.h as :
>#define Normal(x,y,z) ((*((y)->Methods->Normal_Method)) (x,y,z))
>so the argument y ( here Ray_Intersection->Object ) is a struct that
>contains the information
>I need i.e. Ray_Intersection->Object->Methods->Normal_Method - the
>address of a function.
>But again I somehow lost track. Can anyone tell me where to find the
>code that calculates
>whatever it is that Normal does ?
It depends on what object type you're using. If you're using a sphere,
for example, you'd look in spheres.c. For a Height Field, look in hfield.c.
Each of the object types initializes an array of pointers to point to their
individual implementations of a number of common functions, including
Normal(). This is the object-oriented part of POV-Ray.
>Even better, can any experienced povray programmer look into that
>problem himself ?
I'd be happy to take a look at it, but you don't seem to mention the type
of object you're working with.
Post a reply to this message
|
![](/i/fill.gif) |