POV-Ray : Newsgroups : povray.pov4.discussion.general : POV-Ray is "PIEware" : Re: POV-Ray is "PIEware" Server Time
21 Jun 2024 09:49:32 EDT (-0400)
  Re: POV-Ray is "PIEware"  
From: Bald Eagle
Date: 17 Apr 2024 17:20:00
Message: <web.66203c9418d596021f9dae3025979125@news.povray.org>
"ingo" <nomail@nomail> wrote:

> During rendering POV-Ray has to know with what
> object a ray intersects. Can these data somehow be saved? Primary intersection,
> secondary intersection?

Damned good idea(s) and something I've thought about and suggested in the past,
however not to the extent of saving the data to a file!

So consider this:

We take my idea of having an object registry, so we can store all of the objects
in an array, and loop through them.
Next, we loop through all the y and x of the camera view frustum, and use trace
()  to cycle through every object in the registry for every pixel.
Using that <x, y, z> data, we have a map of the image with a sort of z-buffer.
Now we write image data perhaps using a format like:
<x, y, object1_z, . . . , objectN_z>

What do you think?

Also, I've wanted a custom version of trace () that would return ALL of the
intersections with an object, not just the first one, so we could do something
like custom inside/outside tests using crossing numbers.
Any idea on how to approach that via SDL that doesn't involve testing dozens of
thin slices of the object perpendicular to the camera ray?

- BE


Post a reply to this message

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