NOO-B with OpenGL

A

AcidSphinx

I have written a peice of code in Visual V++ 6.0, it is almost
identical to a file I downloaded from www.nehe.com, it basicly sets up
an OpenGL window and scans for key presses.
It compiles ok after I have fixed up the typos, but when it gets to
the linking part I get 15 errors, which I assume are probably based on
the first one, as before I fixed my code these errors did not appear.
------------------------------------------------------------------------
OpenGL Screen Setup.obj : error LNK2001: unresolved external symbol
_gluPerspective@32
------------------------------------------------------------------------
is the 1st error followed by a ton of other "unresolved external
symbol" style errors, I have checked to make sure that I included all
the header files. I don't use the "_gluPerspective" keyword anywhere
in my code. I have no idea why this is not working, after all it is
almost a direct port from a working peice of code, less one message
box.
I don't want to post the code here because it is several pages in
length (and has tons of comments), but if you want to have a look at
it just ask and I'll send it to you.
AcidSphinx
 
J

Jack Klein

I have written a peice of code in Visual V++ 6.0, it is almost
identical to a file I downloaded from www.nehe.com, it basicly sets up
an OpenGL window and scans for key presses.

Ask in a Windows programming group like
This group discusses the
C++ language, not third-party non-standard libraries.

--
Jack Klein
Home: http://JK-Technology.Com
FAQs for
comp.lang.c http://www.eskimo.com/~scs/C-faq/top.html
comp.lang.c++ http://www.parashift.com/c++-faq-lite/
alt.comp.lang.learn.c-c++ ftp://snurse-l.org/pub/acllc-c++/faq
 
M

Martin Magnusson

AcidSphinx said:
It compiles ok after I have fixed up the typos, but when it gets to
the linking part I get 15 errors, which I assume are probably based on
the first one, as before I fixed my code these errors did not appear.

Probably you missed linking with (some of the) OpenGL libraries. Try
appending "-lOpenGL32 -lGlu32 -lGlut32" to the compiler command line.

/ martin
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,766
Messages
2,569,569
Members
45,042
Latest member
icassiem

Latest Threads

Top