Jump to content
  • Advertisement
Sign in to follow this  
Will-O

OpenGL Compiling Book Code

This topic is 3839 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

I needed to have a look through some code in the book "Beginning OpenGL Game Programming (Astle D & Hawkins K, 2004)," which worked on VS2003 but not with VS2005. There were a few compile errors which were solved with (slightly nasty) hacks - namely Compile Error: (3 exactly like this but in different places) "cannot convert parameter 2 form 'const char [8]' to 'LPCWSTR'" Hack: Well of course I cast the char array to LPCWSTR! - most odd that this kind of thing can't be done automatically by the compiler though. Once I got it to compile, it wouldn't link. There are no less than 19 LNK2019 errors. These might be to do with my hack but by the looks of where the problems are occurring, it's more to do with the functions in the CGfxOpenGL class and I was wondering - have the authors (who I think work/have worked on this very site), or has anyone else come upon these problems and further to that has a solution been found? If this post is in the wrong forum, please advise and I'll move along! Many Thanks.

Share this post


Link to post
Share on other sites
Advertisement
Sounds like your project is compiled for unicode, so you should use unicode everywhere. You shouldn`t cast unless you know exactly what you are doing.

BTW, your question belongs in a C++ forum.

Share this post


Link to post
Share on other sites
Go to Project -> Properties -> Configuration Properties -> General -> Character Set and change it to Not Set. This should fix the problem.

Share this post


Link to post
Share on other sites
Sign in to follow this  

  • Advertisement
×

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

We are the game development community.

Whether you are an indie, hobbyist, AAA developer, or just trying to learn, GameDev.net is the place for you to learn, share, and connect with the games industry. Learn more About Us or sign up!

Sign me up!