PDA

View Full Version : Unable to compile openGL programs :(



mkartic
August 21st, 2008, 04:18 AM
hey guys, am trying to learn openGL for doing a college project. I followed the instructions in this thread: http://ubuntuforums.org/showthread.php?t=375425&highlight=glut

It got compiled fine, but when i try to run it, am getting errors! can someone help me out please?:confused:

jeez@jeez-desktop:~/Desktop/openGL$ g++ bla.cpp -lglut
jeez@jeez-desktop:~/Desktop/openGL$ ./a.out
freeglut (./a.out): OpenGL GLX extension not supported by display ':0.0'

thanks!

[edit]
http://amazingrando.wordpress.com/2007/04/10/compiling-and-using-newest-nvidia-drivers-in-ubuntu-its-easier-than-you-think/
I followed that link and my problem's now fixed! thanks guys :)

slavik
August 21st, 2008, 04:53 AM
what video card and driver are you using and do you have direct rendering? (what does `glxinfo | grep direct` say?)

jespdj
August 21st, 2008, 11:54 AM
It got compiled fine, but when i try to run it, am getting errors! can someone help me out please?
Then why is the title of your post "Unable to compile OpenGL programs"?

mkartic
August 21st, 2008, 05:24 PM
Then why is the title of your post "Unable to compile OpenGL programs"?

fat help, thanks! :)


@slavik:
jeez@jeez-desktop:~/stuff/VTK/bin$ glxinfo | grep direct
Xlib: extension "GLX" missing on display ":0.0".
Xlib: extension "GLX" missing on display ":0.0".
Xlib: extension "GLX" missing on display ":0.0".
Error: couldn't find RGB GLX visual
Xlib: extension "GLX" missing on display ":0.0".
Xlib: extension "GLX" missing on display ":0.0".
Xlib: extension "GLX" missing on display ":0.0".
Xlib: extension "GLX" missing on display ":0.0".
Xlib: extension "GLX" missing on display ":0.0".
Xlib: extension "GLX" missing on display ":0.0".
Same error! :(
And i tried installing vtk, and wen i tried running an example, i got the same error! I have an nVidia 8500GT gcard!
how do i check the version of the driver??

Zugzwang
August 21st, 2008, 05:28 PM
mkartic, this is the wrong forum for these problems as it appears as you didn't set up your graphic drivers correctly. Did you try installing the proprietary drivers? The respective menu entry is somewhere in the GNOME menu...

slavik
August 21st, 2008, 05:34 PM
fat help, thanks! :)


@slavik:
jeez@jeez-desktop:~/stuff/VTK/bin$ glxinfo | grep direct
Xlib: extension "GLX" missing on display ":0.0".
Xlib: extension "GLX" missing on display ":0.0".
Xlib: extension "GLX" missing on display ":0.0".
Error: couldn't find RGB GLX visual
Xlib: extension "GLX" missing on display ":0.0".
Xlib: extension "GLX" missing on display ":0.0".
Xlib: extension "GLX" missing on display ":0.0".
Xlib: extension "GLX" missing on display ":0.0".
Xlib: extension "GLX" missing on display ":0.0".
Xlib: extension "GLX" missing on display ":0.0".
Same error! :(
And i tried installing vtk, and wen i tried running an example, i got the same error! I have an nVidia 8500GT gcard!
how do i check the version of the driver??
what are the results of `grep driver /etc/X11/xorg.conf`

mordox
August 21st, 2008, 05:50 PM
Try this:

http://www.linuxforums.org/forum/linux-desktop-x-windows/32497-glx-extension-missing.html



Also check if you have the correct driver selected in xorg.conf.

U can let X -configure for X11 to detect the settings.