2010-08-07 5 views
0

J'ai essayé toutes les solutions flottant sur le net que j'ai pu trouver .. mais toujours pas de succès dans la compilation d'un tutoriel simple sur Windows 7 avec MSVS C++ 2010 Express Edition.opengl programmation sur MSVS C++ express 2010 sur Windows 7

Si quelqu'un peut me donner des indices sur la façon de procéder, je serais reconnaissant.

Merci.

Modifier: erreurs

------ Build started: Project: Polyons, Configuration: Debug Win32 ------ 
C:\Program Files\MSBuild\Microsoft.Cpp\v4.0\Microsoft.CppBuild.targets(990,5): warning MSB8012: TargetPath(C:\Users\Ashish\Downloads\GameloftOpenGL\02Polygons\.\Debug\Polyons.exe) does not match the Linker's OutputFile property value (C:\Users\Ashish\Downloads\GameloftOpenGL\02Polygons\Debug\test.exe). This may cause your project to build incorrectly. To correct this, please make sure that $(OutDir), $(TargetName) and $(TargetExt) property values match the value specified in %(Link.OutputFile). 
C:\Program Files\MSBuild\Microsoft.Cpp\v4.0\Microsoft.CppBuild.targets(992,5): warning MSB8012: TargetName(Polyons) does not match the Linker's OutputFile property value (test). This may cause your project to build incorrectly. To correct this, please make sure that $(OutDir), $(TargetName) and $(TargetExt) property values match the value specified in %(Link.OutputFile). 
Polygons.obj : error LNK2019: unresolved external symbol _gluPerspective referenced in function "void __cdecl ReSizeGLScene(int,int)" ([email protected]@[email protected]) 
Polygons.obj : error LNK2019: unresolved external symbol _glLoadIdentity referenced in function "void __cdecl ReSizeGLScene(int,int)" ([email protected]@[email protected]) 
Polygons.obj : error LNK2019: unresolved external symbol _glMatrixMode referenced in function "void __cdecl ReSizeGLScene(int,int)" ([email protected]@[email protected]) 
Polygons.obj : error LNK2019: unresolved external symbol _glViewport referenced in function "void __cdecl ReSizeGLScene(int,int)" ([email protected]@[email protected]) 
Polygons.obj : error LNK2019: unresolved external symbol _glHint referenced in function "int __cdecl InitGL(void)" ([email protected]@YAHXZ) 
Polygons.obj : error LNK2019: unresolved external symbol _glDepthFunc referenced in function "int __cdecl InitGL(void)" ([email protected]@YAHXZ) 
Polygons.obj : error LNK2019: unresolved external symbol _glEnable referenced in function "int __cdecl InitGL(void)" ([email protected]@YAHXZ) 
Polygons.obj : error LNK2019: unresolved external symbol _glClearDepth referenced in function "int __cdecl InitGL(void)" ([email protected]@YAHXZ) 
Polygons.obj : error LNK2019: unresolved external symbol _glClearColor referenced in function "int __cdecl InitGL(void)" ([email protected]@YAHXZ) 
Polygons.obj : error LNK2019: unresolved external symbol _glShadeModel referenced in function "int __cdecl InitGL(void)" ([email protected]@YAHXZ) 
Polygons.obj : error LNK2019: unresolved external symbol _glEnd referenced in function "void __cdecl DrawCube(float,float,float,float,float,float,float,float,float,float,float,float,float,float,float,float,float,float,float,float,float,float,float,float)" ([email protected]@[email protected]) 
Polygons.obj : error LNK2019: unresolved external symbol _glVertex3f referenced in function "void __cdecl DrawCube(float,float,float,float,float,float,float,float,float,float,float,float,float,float,float,float,float,float,float,float,float,float,float,float)" ([email protected]@[email protected]) 
Polygons.obj : error LNK2019: unresolved external symbol _glColor3f referenced in function "void __cdecl DrawCube(float,float,float,float,float,float,float,float,float,float,float,float,float,float,float,float,float,float,float,float,float,float,float,float)" ([email protected]@[email protected]) 
Polygons.obj : error LNK2019: unresolved external symbol _glBegin referenced in function "void __cdecl DrawCube(float,float,float,float,float,float,float,float,float,float,float,float,float,float,float,float,float,float,float,float,float,float,float,float)" ([email protected]@[email protected]) 
Polygons.obj : error LNK2019: unresolved external symbol _glClear referenced in function "int __cdecl DrawGLScene(void)" ([email protected]@YAHXZ) 
.\Debug/test.exe : fatal error LNK1120: 15 unresolved externals 
========== Build: 0 succeeded, 1 failed, 0 up-to-date, 0 skipped ========== 
+0

Plus d'information serait utile. Quelles erreurs obtenez-vous du compilateur? – Rushyo

Répondre

1

Vous devez créer un lien avec les bibliothèques appropriées

Aller projet-> Paramètres-> Linker->> bibliothèques supplémentaires entrées-et ajouter:

opengl32.lib glu32.lib