Original Post
Hi all,
I usually program in linux so i''m sure this is a rudimentary question but in VC++ how do you get it to let you seperate your functions into seperate cpp files?
For instance, let''s say i want to put DrawGLScene in a file by itself. In linux i would just have my main headers, a custom header for my global variables, a custom function header for function prototypes, and #include "draw.cpp", let''s say, that holds the DrawGLScene function. My problem is when i try to do the same in VC, i.e:
#include
#include the rest of the headers that would go here, including custom headers
#include "draw.cpp"
int WINAPI WinMain...rest of program,
it comes back with the errors:
c:\windows\desktop\winprogs\tetrivix\draw.cpp(5) : error C2065: ''GLvoid'' : undeclared identifier
c:\windows\desktop\winprogs\tetrivix\draw.cpp(6) : error C2448: '''' : function-style initializer appears to be a function definition
Error executing cl.exe.
It seems like it would look at the GL headers that had already been defined. Anyway, any help is greatly appreciated.
Thanks,
Crimson