i use this compiler :
Borland 5.5 c++ under windows
i get this errors:

Warning W8065 shortest.c 13: Call to function ‘auxInitPostion’ with no prototype
in function main
Turbo Incremental Link 5.00 Copyright (c) 1997, 2000 Borland
Error: Unresolved external ‘auxInitDisplayMode’ referenced from D:\ITC\OPENGL\SH
Error: Unresolved external ‘_auxInitPostion’ referenced from D:\ITC\OPENGL\SHORT
Error: Unresolved external ‘auxInitWindowA’ referenced from D:\ITC\OPENGL\SHORTE

this is the code i use:


#include <windows.h>
#include <conio.h>
#include <Gl\gl.h>
#include <Gl\glaux.h>

void main(void) {
auxInitDisplayMode(AUX_SINGLE | AUX_RGBA);
auxInitWindow(“My first OpenGL Progrem”);

glClearColor(0.0f, 0.0f,1.0f,1.0f);


cprintf("Press any key to close thw window


how can i solve the erorrs?

thanks shlomik

you need to include the glaux library. However this library is not supplied in a borland friendly format, has many memory leaks, and is generally outdated. I suggest looking at GLFW or GLUT as possible alternatives

I insert glut32.lib and GLAUX.lib to the lib directory of Borland but i still get the same erorrs
you can please suggest me about a compiler that came with the glaux library?

On top you need to add the libraries in your project I believe. Probably through the file manager. Also the error that states you’re calling a function without prototype, makes me think you might not be including the header as well.
As for compilers I think the easiest one is Microsoft’s Visual C++ as it has the headers and the libraries (except glut, but you can add it easily) ready in place. For a free compiler Dev-C++ seems to be popular but I’ve never used it for OpenGL. Since you’re using Borland you might want to try CBuilderX. I think that it is built around java though (the IDE, not the compiler!) so you better have a fast machine. There’s a personal edition free of charge. Also, for the sake of completion, you could always get cygwin (a linux emulator for windows) and start programming with Vim (for me it took a lot of time to know it well, but it’s a great editor) and gcc. But if your programming on windows I wouldn’t recommend the last option (though CBuilderX supports gcc).

And when you solved all library issues, make sure you write auxInitPosition correctly.

Would any one please tell me whether OpenGL programing could be developed in Java environment?
If yes,how to deploy the workspace? I mean using
Thanks a lot.I’m a newer to OpenGL and Java.