POV-Ray : Newsgroups : povray.general : Mesh to solid : Re: Mesh to solid Server Time
16 Nov 2024 01:18:31 EST (-0500)
  Re: Mesh to solid  
From: Ron Parker
Date: 28 Oct 1998 15:24:40
Message: <36377d88.0@news.povray.org>
On Wed, 28 Oct 1998 14:59:59 -0500, Nathan Kopp <Nat### [at] Koppcom> wrote:
>Bezier patches are also infinitely thin.  It MIGHT be possible to create a
>patched version of POV that treats triangle meshes as solid.  The main
>problem that currently exists is that POV doesn't know if a point is inside
>an object or not.  The simple (but not always effective) solution is to
>shoot an arbitrary ray from the point and if it intersects an even number
>of triangles, you are outside the object, and if it intersects an odd
>number than you are inside.  Maybe I'll try it.  (here I go again talking
>about stuff here that should be in the povray.programming newsgroup.)

Welcome to the club, Nathan.  I'm guilty of posting about programming stuff
here as well.  Something you'll want to keep in mind is that if you 
intersect at a vertex or edge, you'll have to either shoot a new ray or use 
some heuristics to determine whether the edge or vertex counts as an 
intersection or not.  That is, if you shoot a ray "tangent" to a vertex or 
edge, you don't want to count the intersection.  If you shoot it "through" 
a vertex or edge, you want to count it, but only once (more than one 
triangle could be hit at such a point, but you only want to count one.)

Followups set to povray.programming.


Post a reply to this message

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