Something is not working
hi there, im new to Opengl, and i took a book from the library about Opengl
This is the code that its written, its supose to make a window and stay fix, but what happens is that it dissapears, it doesnt stay at all!
<source>
#include <windows.h>
#include <conio.h>
#include <gl\gl.h>
#include <gl\glaux.h>
main(void)
{
auxInitDisplayMode(AUX_SINGLE | AUX_RGBA); //Le decimos que use una ventana de buffer unico
//Y especificamos el color en base a Rojo, verde azul
auxInitPosition(100,100,250,250);
auxInitWindow(" Mi primera ventana");
getch();
}
</source>
It's a console program. You're supposed to run it from the console (i.e. the DOS prompt where you type the name of the exe to run it). You're double clicking it, i gather or just running it with F5 from your debugger.
Also, getch() is depreciated with Visual Studio 2005 so that may be why it's not working. Also, my 10second google on the subject seems to suggest that maybe it's not a blocking call?
You can try:
1) preferred - put a breakpoint at the end of the main() function and run it through the debugger
2) very very unpreferred use getchar() instead
-me
Also, getch() is depreciated with Visual Studio 2005 so that may be why it's not working. Also, my 10second google on the subject seems to suggest that maybe it's not a blocking call?
You can try:
1) preferred - put a breakpoint at the end of the main() function and run it through the debugger
2) very very unpreferred use getchar() instead
-me
U are right, but when i click it, it appears a message saying something like "Error while iniciating the application, Glaux.dll wasnt found, try the reinstalation of the application"
To add more information..
Im using DEv-C, and i´ve never used glaux before, just because this books uses it, i downloaded the library, i put glaux.h in include folder, glaux.lib in lib folder, and glut32.dll in c:/windows/system, but still is not working.
Any idea, the message that appears is the one i wrote before...
Im using DEv-C, and i´ve never used glaux before, just because this books uses it, i downloaded the library, i put glaux.h in include folder, glaux.lib in lib folder, and glut32.dll in c:/windows/system, but still is not working.
Any idea, the message that appears is the one i wrote before...
Well, like it says, you're missing GLaux.dll. If you have it, put it in the same folder as your application. If you don't, I'm not sure where to tell you to get it. GLaux was not been supported for a long time. I recommend finding a more up-to-date source for OpenGL self-education.
I also recommend finding and using an IDE other than Dev-Cpp. Consider Code::Blocks or MSVC++ Express. Both are free.
I also recommend finding and using an IDE other than Dev-Cpp. Consider Code::Blocks or MSVC++ Express. Both are free.
If you use XP or higher you have to put *.dll files into your windows\system32 folder. Perhaps that might help
This topic is closed to new replies.
Advertisement
Popular Topics
Advertisement