Help I Have errors in Visual C++

when i Working under windows and use glut methods i Got this errors

1>MosegaardsClothTutorial.obj : error LNK2019: unresolved external symbol _glutPostRedisplay referenced in function “void __cdecl display(void)” (?display@@YAXXZ)
1>MosegaardsClothTutorial.obj : error LNK2019: unresolved external symbol _glutSwapBuffers referenced in function “void __cdecl display(void)” (?display@@YAXXZ)
1>MosegaardsClothTutorial.obj : error LNK2019: unresolved external symbol _glutSolidSphere referenced in function “void __cdecl display(void)” (?display@@YAXXZ)
1>MosegaardsClothTutorial.obj : error LNK2019: unresolved external symbol _glutReshapeWindow referenced in function “void __cdecl arrow_keys(int,int,int)” (?arrow_keys@@YAXHHH@Z)
1>MosegaardsClothTutorial.obj : error LNK2019: unresolved external symbol _glutFullScreen referenced in function “void __cdecl arrow_keys(int,int,int)” (?arrow_keys@@YAXHHH@Z)
1>MosegaardsClothTutorial.obj : error LNK2019: unresolved external symbol _glutMainLoop referenced in function _main
1>MosegaardsClothTutorial.obj : error LNK2019: unresolved external symbol _glutSpecialFunc referenced in function _main
1>MosegaardsClothTutorial.obj : error LNK2019: unresolved external symbol _glutKeyboardFunc referenced in function _main
1>MosegaardsClothTutorial.obj : error LNK2019: unresolved external symbol _glutReshapeFunc referenced in function _main
1>MosegaardsClothTutorial.obj : error LNK2019: unresolved external symbol _glutDisplayFunc referenced in function _main
1>MosegaardsClothTutorial.obj : error LNK2019: unresolved external symbol _glutCreateWindow referenced in function _main
1>MosegaardsClothTutorial.obj : error LNK2019: unresolved external symbol _glutInitWindowSize referenced in function _main
1>MosegaardsClothTutorial.obj : error LNK2019: unresolved external symbol _glutInitDisplayMode referenced in function _main
1>MosegaardsClothTutorial.obj : error LNK2019: unresolved external symbol _glutInit referenced in function _main
1>C:\Users\Inazuma\Desktop\myfolders\MosegaardsClothTutorial\Debug\MosegaardsClothTutorial.exe : fatal error LNK1120: 14 unresolved externals
========== Build: 0 succeeded, 1 failed, 0 up-to-date, 0 skipped ==========

and i got all libraries in my linker
OpenGL32.lib glut32.lib freeglut.lib gl32.lib

glut32.lib freeglut.lib : having both is not needed, can you try with only one of these ?
Are you sure freeglut.lib is at a findable place for VC++ ?

yes all libraries are placed in C:/OGL/lib/ and all are linked with it and the include directories

Something is definitely not set up correctly; the “unresolved external symbol” error, in this case, indicates that the linker can’t find a library. Could you post your code (including the project and solution files)?

sure here is http://www.megaupload.com/?d=R99B0F1T

i try to upload here but throw error

It’s been a while since I used freeglut but as far as I can remember freeglut had 2 library types, static and dll (i.e freeglut_static.lib and freeglut.lib or something to that effect).

from you errors it looks like you are trying to use the static lib (i.e. probably defined FREEGLUT_STATIC or something similar) but actually linking with freeglut.lib (which should be for the dll version).

Either try linking with static lib or do not define FREEGLUT_STATIC.

I am writing this completely from memory, the names of the libs and preprocessor macros might be different what they actually are.

Good luck.

nope I’ve try it and not work

This topic was automatically closed 183 days after the last reply. New replies are no longer allowed.