Foro de elhacker.net

Programación => Programación C/C++ => Mensaje iniciado por: totolia en 13 Mayo 2012, 20:41 pm



Título: Problema OpenGL y glut.h (Libreria)
Publicado por: totolia en 13 Mayo 2012, 20:41 pm
Hola verán, me estoy volviendo realmente loco buscando un error que estoy seguro que es sencillo de solucionar. Estoy usando CodeBlocks para programar en OpenGL pero no consigo hacer include de la libreria glut.h y me salen los siguientes errores:
c:\program files (x86)\codeblocks\mingw\bin\..\lib\gcc\mingw32\4.4.1\..\..\..\..\include\GL\glut.h|486|undefined reference to `__glutInitWithExit'| linea 486 undefined reference to '__glutInitWithExit'
c:\program files (x86)\codeblocks\mingw\bin\..\lib\gcc\mingw32\4.4.1\..\..\..\..\include\GL\glut.h|503|undefined reference to `__glutCreateWindowWithExit'| linea 503 undefined reference to '__glutCreateMenuWithExit'
c:\program files (x86)\codeblocks\mingw\bin\..\lib\gcc\mingw32\4.4.1\..\..\..\..\include\GL\glut.h|549|undefined reference to `__glutCreateMenuWithExit'| linea 549 undefined reference to '__glutCreateMenuWithExit'

Es un error de configurar mal el codeblocks? O tengo mal puesta la librería. Gracias.


Título: Re: Problema OpenGL y glut.h (Libreria)
Publicado por: totolia en 13 Mayo 2012, 20:50 pm
Pues para quien haya tenido problemas, con algo parecido, que añada el #include <windows.h> encima del todo. Y luego es muy posible que el glut.dll este dañado que pase por aquí: http://www.dll-files.com/dllindex/dll-files.shtml?glut32

Ami me funciono.