help!first GL program(compile error)

alright, i just started programming in OpenGL, so got the book and everything. I try to compile the program and it gives me this:

c:\program files\microsoft visual studio\myprojects\opengl test\openglllltest\bob].cpp(73) : error C2601: ‘DrawTorso’ : local function definitions are illegal

‘DrawTorso’ is the name of the function

i run Visual C++ under XPpro so HELP, PLEASE! thank you

Send your source code for me, I will find error from your program.
quangkid@hcm.fpt.vn

Originally posted by rage7826:
[b]alright, i just started programming in OpenGL, so got the book and everything. I try to compile the program and it gives me this:

c:\program files\microsoft visual studio\myprojects\opengl test\openglllltest\bob].cpp(73) : error C2601: ‘DrawTorso’ : local function definitions are illegal

‘DrawTorso’ is the name of the function

i run Visual C++ under XPpro so HELP, PLEASE! thank you[/b]

I’m guessing that you are not only new to OpenGL, but also fairly new to C++. If you aren’t new, that error would tell you that you are trying to create a function inside another function, which is not possible in C++.

Double check that you have your brackets all in place correctly. It’s possible that whatever function is before DrawTorso is missing an ending bracket.

Put down the compiler, and STEP AWAY before someone gets hurt!