Part of the Khronos Group
OpenGL.org

The Industry's Foundation for High Performance Graphics

from games to virtual reality, mobile phones to supercomputers

Results 1 to 4 of 4

Thread: Smooth shading

  1. #1
    Junior Member Newbie
    Join Date
    Feb 2002
    Location
    Rockport, MA, USA
    Posts
    2

    Smooth shading

    When I create a sphere (or any shape) I can see each facet. How do I get the smooth sphere effect. Is it that I am using a single normal for each quad? I tried both smooth and flat shading and I see no difference.

  2. #2
    Member Regular Contributor
    Join Date
    Oct 2001
    Location
    Princeton, NJ
    Posts
    391

    Re: Smooth shading

    you need to provide a normal for each vertex, average the normals of each face that a vertex is in to find the normal of that vertex

  3. #3
    Intern Contributor
    Join Date
    Feb 2002
    Posts
    82

    Re: Smooth shading

    Isnt there a shading method that uses the angles of 2 tris and if its less than a number (so you keep sharp corners) it makes a new normal. or something like that???

  4. #4
    Junior Member Newbie
    Join Date
    Feb 2002
    Posts
    23

    Re: Smooth shading

    if you are doing a sphere, the normal should be the same as the vertex, because all of the points in a sphere are the same distance away from the center. yeah, i didn't explain that well, but it works.

Posting Permissions

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