In addition to what has already been said, it is important to
remember that a vector is a means of specifying a direction.  In many
cases you may want to manipulate them mathematically (e.g., What
direction is halfway between the two thugs,  left and right, that I am
trying to escape?).  It is difficult to do that if the "directions" are
not consistent (What if one thug is further away than the other?).  A
great many mathematical functions eliminate the distance problem by
setting the vector length to one ("normalizing" the vector) so the only
component of concern is its direction.  I suggest you take a look at an
introductory book on computer graphics.  The field does require a fair
understanding of math concepts and an understanding of vectors, dot
products, etc. is essential if you ever plan to program anything other
than the most basic scenes.
        -Gary Graf

Jasmine Kwok wrote:

> Thanks.But how does it help in any program?I mean why would one use
> normalise() in his program, does it help in any kind of
> function?  Jasmine Kwok
>
>      ----- Original Message -----
>      From: Patrick-Emmanuel Boulanger-Nadeau
>      To: [EMAIL PROTECTED]
>      Sent: Wednesday, February 12, 2003 3:37 PM
>      Subject: Re: [JAVA3D] Function of normalise()
>       Normalising a vector is giving him the unitary lenght, by
>      definition. The function simply calculate the lenght (square
>      root of the sum of the square of each composant) and then
>      divide every composant by it .. so the function is really
>      doing what it should =)
>
>           ----- Original Message -----
>           From: Jasmine Kwok
>           To: [EMAIL PROTECTED]
>           Sent: Wednesday, February 12, 2003 12:09 AM
>           Subject: [JAVA3D] Function of normalise()
>            Dear all, Does anyone has any idea what exactly
>           does the normalize() in Vector3d does?How come the
>           length of the vector becomes 1.0 after it is
>           normalized, regardless of the values of x, y & z.I
>           need some explanation on this as the API does not
>           explain the method's function in details.I would
>           be thankful to anyone who can provide me with a
>           simple explanation on this. Cheers,Jasmine Kwok
>

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