POV-Ray : Newsgroups : povray.general : Solid meshes in CSG : Re: Solid meshes in CSG Server Time
30 Jul 2024 20:17:30 EDT (-0400)
  Re: Solid meshes in CSG  
From: clipka
Date: 11 Dec 2008 14:20:01
Message: <web.494166e27b08f33bf708085d0@news.povray.org>
Warp <war### [at] tagpovrayorg> wrote:
>   To understand how this works, the simplest case would be eg. a mesh with
> one single triangle. Let's say this triangle is on the xz-plane (with the
> y coordinates of the vertices being all 0), and an "inside_vector y".
> Basically this mesh now forms an infinite triangular prism solid (which
> extends from y=0 towards the negative y axis direction). It's just that
> this "prism" as only the "end cap" (the triangle in question) but no
> visible "walls". However, in CSG it will behave like it had them.

Quite so, yes. It should be noted though that the CSG operations will *not* make
the invisible walls visible (because PoV-ray can't make anything visible except
ray-surface intersection points, and for the purpose of *this* test the "prism
walls" don't exist). So even in CSG, it will behave like it had those
"invisible walls" *only* with respect to what can be seen of the other objects'
surfaces in the CSG construct.

- In Unions, there should be no effect at all on the other objects
- In Merges, parts of the other objects which are "inside" the "mesh prism"
should be invisible
- In Intersections, parts of the other objects which are "outside" the "mesh
prism" should be invisible

(Note that differences can be regarded as an intersection between the first
object and inverted versions of the others.)


Therefore, the visible effect of this "prism" defined by the mesh and the inside
vector will be limited to hiding (or not hiding) parts of the other object's
surface.

In addition, bounding boxes may interact with this, because a bounding box based
inside-test will definitely be "cheaper" than the test-ray based approach, so I
guess it's actually implemented.


>   (Disclaimer: No, I haven't actually tested it actually works like this.
> However, knowing the algorithm used for the insideness test, I can't think
> how it could work in any other way.)

Same goes for me.


Post a reply to this message

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