Results 1 to 9 of 9

Thread: GL_NORMALIZE: Do or Do Not?

  1. #1
    Senior Member Regular Contributor
    Join Date
    Mar 2000
    Location
    Aurora, Illinois, USA
    Posts
    192

    GL_NORMALIZE: Do or Do Not?

    hmm... should I normalize my vectors myself or let openGL ICD do it?

    system:
    Redhat Linux 7.1
    accelerated drivers from Nvidia (so hardware acceleration under X )
    Riva TNT2 Ultra (Viper 770 Ultra)

    So, which choice _should_ be faster?
    Navreet Gill [img]/forum/images/%%GRAEMLIN_URL%%/smile.gif[/img]

  2. #2
    Senior Member Regular Contributor
    Join Date
    Nov 2000
    Location
    Sydney, NSW, Australia
    Posts
    426

    Re: GL_NORMALIZE: Do or Do Not?

    Development time wise letting OGL do it is faster, runtime wise calculating it yourself is faster.
    :: Sleep is a poor substitute for caffeine ::

  3. #3
    Senior Member OpenGL Pro
    Join Date
    May 2001
    Location
    Kristianstad,Skåne,Sweden
    Posts
    1,595

    Re: GL_NORMALIZE: Do or Do Not?

    nVIDIA's FAQ recommend that you always do it as the extra cost is very small.

    Mikael

  4. #4
    Senior Member Regular Contributor
    Join Date
    Mar 2000
    Location
    Aurora, Illinois, USA
    Posts
    192

    Re: GL_NORMALIZE: Do or Do Not?

    Thank you, Mr. Shoe... if did it both ways and checked which one is faster...

    Can I trust that it will be faster that way on all machines?? (at least with Nvidia ICDs) or is it always that the ICD is slower than your own calculations... even on hardware T&L machines??
    Navreet Gill [img]/forum/images/%%GRAEMLIN_URL%%/smile.gif[/img]

  5. #5
    Senior Member Regular Contributor
    Join Date
    Mar 2000
    Location
    Aurora, Illinois, USA
    Posts
    192

    Re: GL_NORMALIZE: Do or Do Not?

    ahh well that answers the question! thanks michael
    Navreet Gill [img]/forum/images/%%GRAEMLIN_URL%%/smile.gif[/img]

  6. #6
    Senior Member Frequent Contributor
    Join Date
    Sep 2000
    Location
    SWEDEN
    Posts
    601

    Re: GL_NORMALIZE: Do or Do Not?

    First of all try to avoid scaling the modelview matrix. If you have to, use uniform scaling and the rescale normals extension if you're running on machines without HW T&L, else just enable normalization (you can't do it yourself btw, unless your doing all the transformations and lighting yourself).

  7. #7
    Senior Member OpenGL Guru zed's Avatar
    Join Date
    Nov 2010
    Posts
    2,466

    Re: GL_NORMALIZE: Do or Do Not?

    as harsman saiz. u only need to enable it when u rescale your models eg with glScale(..). other leave it switched off.

  8. #8
    Senior Member Regular Contributor
    Join Date
    Mar 2000
    Location
    Aurora, Illinois, USA
    Posts
    192

    Re: GL_NORMALIZE: Do or Do Not?

    hmm... if I ever use hardware scaling... it only does them once right? not every frame?
    Navreet Gill [img]/forum/images/%%GRAEMLIN_URL%%/smile.gif[/img]

  9. #9
    Senior Member Frequent Contributor
    Join Date
    Sep 2000
    Location
    SWEDEN
    Posts
    601

    Re: GL_NORMALIZE: Do or Do Not?

    When you scale the current matrix (usually the modelview, but it could be projection or texture) it stays that way until you change or push it. And the matrices affect all vertices passed to OpenGL. This is normal though, and nothing you should worry about.

Similar Threads

  1. GL_NORMALIZE
    By nib in forum OpenGL: macOS
    Replies: 2
    Last Post: 08-15-2008, 08:47 PM
  2. GL_NORMALIZE or not?
    By 9ine in forum OpenGL: Basic Coding
    Replies: 4
    Last Post: 08-17-2004, 08:47 PM
  3. GL_RESCALE_NORMAL and GL_NORMALIZE
    By martinho_ in forum OpenGL: Advanced Coding
    Replies: 2
    Last Post: 05-11-2004, 11:12 AM
  4. GL_NORMALIZE & vertex programs
    By burt in forum OpenGL: Basic Coding
    Replies: 2
    Last Post: 04-11-2003, 03:51 AM
  5. Radeon GL_NORMALIZE bugged ?
    By bzarokian in forum OpenGL: Advanced Coding
    Replies: 6
    Last Post: 05-30-2002, 12:43 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Proudly hosted by Digital Ocean