Skip to main content
GameDev.net gamedev.net
🔒 Locked

Direction vector normalizing?

Started by henrym Jul 19, 2002 at 4:34 AM 5 replies 1.3k views
Original Post
henrym
henrym
I was just pondering whether or not to normalize my direction vector for every object, so that the direction vector actually lives up to its name and only specifies a direction rather than a speed aswell. Each object would also have a speed aswell. Henrym My Site
Roquqkie
Roquqkie
You can do both, but I usally have both a velocity vector and a (normalized) direction vector. It´s really up to you.

[edited by - Roquqkie on July 19, 2002 5:41:43 AM]
henrym
henrym
*bump*

Seriously guys, I just want your opinions.

Henrym
My Site
a person
a person
you see it depends on what your after. if you need only the direction and speed has no effect, then normalize it. if you need both (maybe to figure out forces that will act upon something) then dont normalize it.

like said before and will probably be siad by all who reply. it all depends on what you need.
davepermen
davepermen
a normalized direction only needs 2 values..

"take a look around" - limp bizkit
www.google.com
If that's not the help you're after then you're going to have to explain the problem better than what you have. - joanusdmentia
My Page davepermen.net | My Music on Bandcamp and on Soundcloud
Dreamforger
Dreamforger
quote:
Original post by davepermen
a normalized direction only needs 2 values..


How so? in 2D yes, but a non-normalized vector needs as many.
In 3D you need 3 values as well. Just because x^2+y^2+z^2=1 you cannot store only x and y. Besides having huge computational expenses to recreate the 3rd you loose it''s sign.
If you''re referering to angles it works, but is impracticable as hell for general purposes



---------------------------
I may be getting older, but I refuse to grow up
I may be getting older, but I refuse to grow up

Topic Locked

This topic has been locked by a moderator. New replies are not allowed.

Sign in to reply to this topic.