POV-Ray : Newsgroups : povray.general : intersection points..... Server Time
7 Nov 2024 04:55:10 EST (-0500)
  intersection points..... (Message 1 to 8 of 8)  
From: Tanju Gurel
Subject: intersection points.....
Date: 16 Apr 2002 15:41:53
Message: <3cbc7e81@news.povray.org>
hi...
I have 14 planes with their normal vectors and distances from origin...
Using intersection{} i had intersected them.
then my object has constructed....
but i need the intersection points of the planes....
because i want to put spheres at that locations
Is there any variable or method to get them from povray?
thanks.
Tanju


Post a reply to this message

From: Jan Walzer
Subject: Re: intersection points.....
Date: 16 Apr 2002 15:56:11
Message: <3cbc81db@news.povray.org>
maybe it's a chance, if you insect 3 planes, and then use the
min/max_extend-functions... it could be, that one of the ext-
ends gives you the point, you're looking for ...

... but you'd have to do this for every corner of your obj.

don't count on this, to work at all, as this is probably only
a silly idea, that flashed through my mind, when I read your
post ...


Post a reply to this message

From: Christoph Hormann
Subject: Re: intersection points.....
Date: 16 Apr 2002 16:11:36
Message: <3CBC8578.548F0ED0@gmx.de>
Jan Walzer wrote:
> 
> maybe it's a chance, if you insect 3 planes, and then use the
> min/max_extend-functions... it could be, that one of the ext-
> ends gives you the point, you're looking for ...
> 

Won't work, min/max_extend only gives the extents of the bounding box, if
you don't bound the intersection manually this won't even give a usable
result.

But of course it should not very difficult to calculate the intersection
of the planes with some basic math.

http://mathworld.wolfram.com/Plane-PlaneIntersection.html


Christoph

-- 
POV-Ray tutorials, IsoWood include,                 
TransSkin and more: http://www.tu-bs.de/~y0013390/  
Last updated 14 Apr. 2002 _____./\/^>_*_<^\/\.______


Post a reply to this message

From: Tanju Gurel
Subject: Re: intersection points.....
Date: 16 Apr 2002 16:32:09
Message: <3cbc8a49@news.povray.org>
"Christoph Hormann" <chr### [at] gmxde> wrote in message
news:3CBC8578.548F0ED0@gmx.de...
>
>
> Jan Walzer wrote:
> >
> > maybe it's a chance, if you insect 3 planes, and then use the
> > min/max_extend-functions... it could be, that one of the ext-
> > ends gives you the point, you're looking for ...
> >
>
> Won't work, min/max_extend only gives the extents of the bounding box, if
> you don't bound the intersection manually this won't even give a usable
> result.
>
> But of course it should not very difficult to calculate the intersection
> of the planes with some basic math.
>
> http://mathworld.wolfram.com/Plane-PlaneIntersection.html
>
>
> Christoph
>
> --
> POV-Ray tutorials, IsoWood include,
> TransSkin and more: http://www.tu-bs.de/~y0013390/
> Last updated 14 Apr. 2002 _____./\/^>_*_<^\/\.______


i've calculated the points
with 14 planes there is 600 intersection points but i could not be able to
find
the way to eliminate them....
here is the object.....
http://vancat.ibu.edu.tr/bz.jpg

tanju


Post a reply to this message

From: Tor Olav Kristensen
Subject: Re: intersection points.....
Date: 16 Apr 2002 16:35:00
Message: <3CBB397C.D7AC06EA@hotmail.com>
Hi Tanju.

Here's some suggestions:

Every possible combination of 3 planes from your
set of 14 planes should be tested for a common
point (or line or plane). (But note that not every
found point will be on the surface of your
intersection of planes shape).

If vPl1, vPl2 and vPl3 are the normal vectors
for each of the planes and pPl1, pPl2 and pPl3 are
arbitrary points on each plane, then this code will
help you find the intersection points for a plane-
triple:

#if (vdot(vPl1, vcross(vPl2, vPl3) != 0)
  #declare pInterSect =
    pl2pl2pl(pPl1, vPl1, pPl2, vPl2, pPl3, vPl3)
#else
  #error "No singe point of intersection"
#end // if


If you don't know any pPl1, pPl2 or pPl3 points,
then you can calculate some with these expressions:

#declare pPl1 = Distt1*vnormalize(vPl1);
#declare pPl2 = Distt2*vnormalize(vPl2);
#declare pPl3 = Distt3*vnormalize(vPl3);

Where Dist1, Dist2 and Dist3 are the distances from
each of the planes to origo (like POV-Ray expects
in its plane {} expressions).

My pl2pl2pl() macro can be found within this post:
"Re: general geometry question" posted 22. Aug.-01
to this group:

http://news.povray.org/povray.general/17701/114420/
news://news.povray.org/3B82F267.36412849%40hotmail.com


If you want go the other way, you can do this:

#declare Dist1 = vdot(pPl1, vnormalize(vPl1));
#declare Dist2 = vdot(pPl2, vnormalize(vPl2));
#declare Dist3 = vdot(pPl3, vnormalize(vPl3));

Feel free to ask more if you need further help.


Tor Olav


Tanju Gurel wrote:
> 
> hi...
> I have 14 planes with their normal vectors and distances from origin...
> Using intersection{} i had intersected them.
> then my object has constructed....
> but i need the intersection points of the planes....
> because i want to put spheres at that locations
> Is there any variable or method to get them from povray?
> thanks.
> Tanju


Post a reply to this message

From: Tor Olav Kristensen
Subject: Re: intersection points.....
Date: 16 Apr 2002 16:49:58
Message: <3CBB3CFE.338FA35C@hotmail.com>
Tanju Gurel wrote:
>...
> i've calculated the points
> with 14 planes there is 600 intersection points but i could not be able to
> find
> the way to eliminate them....
> here is the object.....
> http://vancat.ibu.edu.tr/bz.jpg

You now have to check every point you found
to see if it has any planes "below" it (i.e.
between it and origo.) If it has, then it is
not on the surface of your shape.)

I've earlier worked with this problem myself.

See my post: "Concave shapes"
(to povray.binaries.images 5. Okt.-00)

http://news.povray.org/povray.binaries.images/12996/
news://news.povray.org/39DC993C.5D889A93%40online.no


Tor Olav


Post a reply to this message

From: Tor Olav Kristensen
Subject: Re: intersection points.....
Date: 16 Apr 2002 16:55:35
Message: <3CBB3E4F.9A7E7CF4@hotmail.com>
Tor Olav Kristensen wrote:
> 
> Tanju Gurel wrote:
> >...
> > i've calculated the points
> > with 14 planes there is 600 intersection points but i could not be able to
> > find
> > the way to eliminate them....
> > here is the object.....
> > http://vancat.ibu.edu.tr/bz.jpg
> 
> You now have to check every point you found
> to see if it has any planes "below" it (i.e.
> between it and origo.) If it has, then it is
> not on the surface of your shape.)

Sorry. This is only true if you have "put"
origo inside your shape.


Tor Olav


Post a reply to this message

From: Tanju Gurel
Subject: Re: intersection points.....
Date: 17 Apr 2002 04:26:27
Message: <3cbd31b3@news.povray.org>
"Tor Olav Kristensen" <tor### [at] hotmailcom> wrote in message
news:3CBB3E4F.9A7E7CF4@hotmail.com...
>
> Tor Olav Kristensen wrote:
> >
> > Tanju Gurel wrote:
> > >...
> > > i've calculated the points
> > > with 14 planes there is 600 intersection points but i could not be
able to
> > > find
> > > the way to eliminate them....
> > > here is the object.....
> > > http://vancat.ibu.edu.tr/bz.jpg
> >
> > You now have to check every point you found
> > to see if it has any planes "below" it (i.e.
> > between it and origo.) If it has, then it is
> > not on the surface of your shape.)
>
> Sorry. This is only true if you have "put"
> origo inside your shape.
>
>
> Tor Olav


thanks to all....
i've done it...
here is the object...
http://vancat.ibu.edu.tr/chbz.jpg
have a nice day....


Post a reply to this message

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