POV-Ray : Newsgroups : povray.pov4.discussion.general : POV-Ray is "PIEware" : Re: POV-Ray is "PIEware" Server Time
21 Jun 2024 09:28:20 EDT (-0400)
  Re: POV-Ray is "PIEware"  
From: ingo
Date: 19 Apr 2024 03:50:00
Message: <web.662220ac18d5960217bac71e8ffb8ce3@news.povray.org>
"Bald Eagle" <cre### [at] netscapenet> wrote:

>
> What I'm thinking is that you:
> 1. shoot a ray with trace () from the camera to the World Coordinates that are
> back calculated from the screen pixel position.
> 2. in the event that you get a Hit, you increment the position farther along the
> ray by Epsilon, and initiate a subsequent trace () call.
> 3. repeat until you get <0, 0, 0> for the normal vector.
>

Unfinished thought:

Get min-, max_extent of object.
1. trace() a corner, lets assume it's a hit.
2. At the hit point create a virtual box with the point as center.
3. Use the inside() function to test the four corners of the box.
[*]
Assume one point is inside the object
4. Trace from the other corners to the one inside the object to find points on
thesurface.
5.Move the box and repeat. Scan the whole bounding box using cubes.

[*] Ok it's simplistic and it may require some subdivision of the box before
using trace() or create 4 boxes with the inside point as common corner straight
away.
It may be more efficient to first scan one face of the bounding box with trace()
and start with the cubes from there.

ingo


Post a reply to this message

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