View Full Version : Porting from VC++6 to VC++.Net
I am trying to port some code that was written using VC6 to VC.Net. (We upgraded compilers.) But the code is refusing to compile. It acts like there are no header files for openGL under VC.Net, though the compiler didn't report any such error.
Is there something you need to do to VC.Net to gain full openGL support?
08-07-2004, 11:09 PM
No, it compiles opengl code out of the box.
Not sure what the problem might be.
08-08-2004, 12:19 PM
the default installation of vc.net has not the opengl headers.... you have to supply them individually. That is, either copy them in the vc7/include directory under the vc.net installation directory in your disk, or add the path where the headers recide on your disk in the INCLUDE system variable. If this is not your problem, then maybe you sould post some errors or something..... what does it shows?
Well it comes with the OpenGL headers but they are located at VC7/PlatformSDK/Include/gl.
I can however comiple new OpenGL programs w/o problems so I guess something went wrong with the project/workspace migration.
Problem solved, but I'm not sure why. I changed the order of the #include files and placed the gl/gl.h and gl/glu.h at the bottom of the list. Viola! It compiles.
I suppose I should look into why this happened, but at this point, I'm just happy it compiles again.
gl.h has dependencies on definitions included in windows.h. you should always include gl/glu last.
Powered by vBulletin® Version 4.2.2 Copyright © 2014 vBulletin Solutions, Inc. All rights reserved.