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 5 of 5

Thread: glVertex3f(x,y,z) internal function

  1. #1
    Junior Member Newbie
    Join Date
    Aug 2012
    Posts
    8

    Lightbulb glVertex3f(x,y,z) internal function

    hello everybody....
    I have a problem in understand the internal function of { glVertex3f(x,y,z) } and how it is work ??
    and can I enter the internal library of opengl to view how this function working??

    thanks in advance....
    Last edited by alneam; 08-04-2012 at 04:49 PM.

  2. #2
    Senior Member OpenGL Pro
    Join Date
    Jan 2007
    Posts
    1,180
    What part of it are you having difficulty with?

    The exact implementation of glVertex3f depends on your driver. No, you can't view any source code for it, because OpenGL is not open source (and nor is it software).

  3. #3
    Junior Member Newbie
    Join Date
    Aug 2012
    Posts
    8
    thanks Mhagain for your quick response...
    I have a difficulty with the projection that used in this function, because i tried to Plot 3D Points onto a 2D screen .
    where the very useful and quick way to draw 3D point onto the screen is:
    x_screen = x_3D / z_3D;
    y_screen = y_3D / z_3D;

    but the results on the screen is not the same results that produce by { glVertex3f } , so i need to understand the type of projection in this function to do like it..

    thanks in advance

  4. #4
    Junior Member Regular Contributor
    Join Date
    Dec 2009
    Posts
    206
    You can look at the source of the gluProject function, which does the correct transformation, here: http://cgit.freedesktop.org/mesa/mes...project.c#n233

  5. #5
    Junior Member Newbie
    Join Date
    Aug 2012
    Posts
    8
    Quote Originally Posted by mbentrup View Post
    You can look at the source of the gluProject function, which does the correct transformation, here: http://cgit.freedesktop.org/mesa/mes...project.c#n233
    but i used glut library in visual c++ 2008 , I think it differ .

Posting Permissions

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