How about forget the maths and use the methods?:

    // vars
    Point3f  p1     = new Point3f( 8.0f, 20.0f, 15.0f);
    Point3f  p2     = new Point3f(-4.0f,  3.0f, 18.0f);
    Vector3f vec    = new Vector3f();
    float    length = 0.0f;

    ...

    // calc length
    vec.sub(p2, p1);        // creates a vector from the origin
    length = vec.length();

G.


On Wed, 3 Oct 2001 07:23:52 -0700, Michael P. McCutcheon <[EMAIL PROTECTED]> wrote:

>I think there is a simple mathematical formula for getting the distence between two 
>points...
>
>i.e.
>
>-3,2,5 and 5,-6,2
>
>Does anyone remember what this is?
>
>Mike
>
>

===========================================================================
To unsubscribe, send email to [EMAIL PROTECTED] and include in the body
of the message "signoff JAVA3D-INTEREST".  For general help, send email to
[EMAIL PROTECTED] and include in the body of the message "help".

Reply via email to