hello all. hello matthew.
Now I have installed code::blocks! (version 10.05)
Yesterday evening I wanted to install a first openGL example (GLUT) and
the setup wizard stopped with this error:
...after "please select GLUT location"
I've typed path where I have installed Freeglut ( a) minGW 2.6.0.3 and b) freeglut 2.6.0) and GLUT 3.7.6.+
bin files (unzipped). I tried to go both ways.
then this script error message appears:
glut32.dll I have installed also *.lib and *.inc files."the path you entered seems valid, but the wizard can't locate the
following glut's library file:
glut32 in it. (Also tried prepending lib and appending .a and .lib)
the file "glut32.lib " I cannot find in GLUT 3.7.6.+ zip file.
freeglut folder content:
don't know why the setup stopped ;("freeglut minGW 2.6.0.3 mp" folder content:
1) include (folder) : GL Folder: with 4 freeglut header files
2) lib (folder) : 2 files : libfreeglut + libfreeglut_static
3) freeglut 2.6.0.0 dll
4) 2 text files
any help would be good!
thanks, frank
you can't always get what you want, but if you try sometimes you might find, you get what you need
Ok, I've attached a version of GLUT that I downloaded from here which has been specifically compiled with MinGW.
I installed the MinGW compiler separately & have it located at C:\MinGW, I've got glut32.dll at C:\MinGW\bin, glut.h is at C:\MinGW\include\GL & libglut32.a is located at C:\MinGW\lib.
Don't bother using the setup wizard, just create a new empty project, add an empty source file to the project & paste the code below into it.
Then link with...
[code=cpp]-lglut32 -lglu32 -lopengl32
#include <stdlib.h>
#include <GL/glut.h>
void keyboard(unsigned char key, int x, int y);
void display(void);
int main(int argc, char** argv)
{
glutInit(&argc, argv);
glutCreateWindow("GLUT Test");
glutKeyboardFunc(&keyboard);
glutDisplayFunc(&display);
glutMainLoop();
return EXIT_SUCCESS;
}
void keyboard(unsigned char key, int x, int y)
{
switch (key)
{
case '\x1B':
exit(EXIT_SUCCESS);
break;
}
}
void display()
{
glClear(GL_COLOR_BUFFER_BIT);
glColor3f(1.0f, 0.0f, 0.0f);
glBegin(GL_POLYGON);
glVertex2f(-0.5f, -0.5f);
glVertex2f( 0.5f, -0.5f);
glVertex2f( 0.5f, 0.5f);
glVertex2f(-0.5f, 0.5f);
glEnd();
glFlush();
}
[/code]
Operating System: Windows 10 Home 64-bit
CPU: Intel Celeron N4000 CPU @ 1.10GHz
Memory: 4.00GB RAM
Graphics: Intel UHD Graphics 600
Bookmarks