Part of the Khronos Group

The Industry's Foundation for High Performance Graphics

from games to virtual reality, mobile phones to supercomputers

Results 1 to 3 of 3

Thread: How do I specify per-vertex normals?

  1. #1
    Newbie Newbie
    Join Date
    Aug 2012

    How do I specify per-vertex normals?

    How do I specify per-vertex normals? Do I simply define a normal before each and every single vert, like I would for a set of faces?

  2. #2
    Senior Member OpenGL Pro
    Join Date
    Jan 2012
    Yes - see glnormal3f

  3. #3
    Senior Member OpenGL Pro Aleksandar's Avatar
    Join Date
    Jul 2009
    You are probably talking about legacy OpenGL. Well, it is a state-machine, and everything set before calling glVertex*() is used for that vertex. If every vertex has a different normal, then yes, you need to call glNormal*() before every glVertex*(). If several verices share same normal, then call glNormal*() just once before those vertices.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts