|
|
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
|
|