POV-Ray : Newsgroups : povray.general : Q: plane equation : Re: Q: plane equation Server Time
12 Aug 2024 23:24:46 EDT (-0400)
  Re: Q: plane equation  
From: Stephen Lavedas
Date: 21 Dec 1998 21:39:15
Message: <367F07AE.CAF654FC@virginia.edu>
Oh! Oh!! 3D Math... now do you REALLY want the math behind this?  Or a
quick and dirty way to do it in POVRay?  Well, you're going to get the
math as I figure it out... (I just finished my last final a couple of
hours ago, and since I don't HAVE to use my brain, I want to)
Okay.. let's take three  points... <x1,y1,z1>, <x2,y2,z2>, and
<x3,y3,z3>.  Now, the midpoint formula for a point exactly on the line
half way in between point 1 and 2 is <(x1-x2)/2, (y1-y2)/2, (z1-z2)/2>
now all that remains is to determine the perpendicular vector that lies
along the same plane as point 3. This can be done by (unless I've gone
off the deep end here, and I have tested this to some extent, but I
could be wrong) taking any multiple of <xm-x3, ym-y2, zm-z3>.  That
should give you your fourth point, however, said point is probably not
equidistant.  This can be solved by trig now.  Let's see... (I'm having
trouble visualizing now...) Can I get away by saying that point is
indeed on the plane, and tranforming it by a fraction of the vector
between point 1 and 2 will put it equidistant?? I doubt it, but will you
give a guy a break??

Steve
(my mind is hurting.. i should have written this down..)


Margus Ramst wrote:
> 
> Could somebody help me out here...
> How can I define a plane in POV code? That is, if I give three coordinates to
> a macro, what equation defines the points lying on the plane defined by these
> 3 coordinates? (Sheesh, that was messy...)
> Let's say, I define 3 points. I now want to find a point at some equal
> distance fom 2 of these points - and lying on the plane defined by the 3
> points. How do I accomplish this?
> 
> My math is failing me...
> 
> Margus


Post a reply to this message

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