|
|
In article <3c4d9de5@news.povray.org>, Warp <war### [at] tagpovrayorg>
wrote:
> However, I understand that removing this inversion could actually break
> something else which currently works. One case could perhaps be CSG
> illumination and inverted object illumination.
Any case where you can see both sides of a surface...any object that's
clipped, triangles, bezier patches, height fields, discs, polygons,
isosurfaces...
The only fix would be to detect for a hit from the "outside" of the
object that still gives a normal that points away from the ray. This
only happens with smooth triangles as far as I can tell, so the test
could be restricted to that case if possible. As for what you do when
you identify this case...that's a different problem, and I don't think
it's been solved. Artificially limit the normal to be at 90 degrees to
the ray? I think that will just make black areas. Ignore the
intersection entirely?
If the intersection is ignored, you have to worry about the triangles
behind it...maybe meshes/smooth_triangles should have a "front_only" or
"cull_backsides" option, but that would break transparent meshes. Maybe
just ignore the intersection and the first intersection with the same
mesh that follows it...that should work for all well-behaved meshes, but
might be complex to code.
--
--
Christopher James Huff <chr### [at] maccom>
Post a reply to this message
|
|