Jump to content
  • Advertisement

Archived

This topic is now archived and is closed to further replies.

ThunderMusic_80

Normal for vertex, possible?

This topic is 5179 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

Advertisement
you can normalize a vector and get a unit vector (unit normal ), but that is [u]not[/u] a normal vector .

a unit vector(or unit normal) is a vector of length 1. So if you normalize a vector you''ll get a unit vector that has the same attributes with your vector but has a length of 1.

to calculate the unit vector u from a vector v:
u = v / |v|

a normal vector is a slightly different unit vector. its perpendicular to a plane . Since you need at least 3 points to define a plane, you can''t define a plane if you just have 1 vector. So you can''t calculate the normal of a vector.

VStrider.

Share this post


Link to post
Share on other sites
Yes you can. You take the average normal of all faces adjoining the vertex and renormalize. It''s used for lighting vertices in a "smooth" manner, since using face normals for lighting gives a "gem stone" sort of effect.

"Most people think, great God will come from the sky, take away everything, and make everybody feel high" - Bob Marley

Share this post


Link to post
Share on other sites
thx Paradigm Shifter for correcting me. Obviously I still have lots of things to learn on 3D graphics.

VStrider.

Share this post


Link to post
Share on other sites

  • Advertisement
×

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

We are the game development community.

Whether you are an indie, hobbyist, AAA developer, or just trying to learn, GameDev.net is the place for you to learn, share, and connect with the games industry. Learn more About Us or sign up!

Sign me up!