As far as I can tell, GLUT has not been updated to support OpenGL 3.2, right? FreeGLUT has calls for specifying OpenGL version, but I can’t find anything similar in GLUT.
I can write Cocoa-based OpenGL programs with 3.2, and there are competitors like GLFW, but GLUT is a terrific API that I really want to keep using for my teaching. Should I switch to FreeGLUT?
Yes, switch to freeGLUT, unless you want to use GLFW. Nobody should use GLUT these days.
Then it would be nice if Apple could get their act together and simply update to FreeGLUT.
Nothing’s stopping you from building FreeGLUT and linking against it. Just like adding any open source library to your app.
The problem with updating GLUT to 3.2 isn’t 3.2 per se, it’s Core Profile. All of that glutSolidTeapot etc API relies on deprecated API that doesnt exist in Core Profile.
No, nothing stops me from fixing it myself in all sorts of ways (including taking the GLUT code and just update it myself), but GLUT comes with the OS, is official sample code and all. So I think Apple should just update it to make it current. They are so fast at deprecating everything else. But maybe that is the problem, they are good at replacing but not at maintaining.
isn’t using NSOpenGLView supposed to take care of all the glut stuff? Looking at the diagram on the apple developer website it seems that it should be able to handle all of the keyboard and mouse events.
Oh, of course it does, in a non-portable way. But that is the problem. It won’t help me make code that will run in our Linux lab.
Still, why aren’t you setting up a FreeGLUT build like arukkuse suggested?
Because I can’t waste time on installing libraries that doesn’t clearly support 3.2 (possibly ending up with an old version), and I needed to get going immediately. You can only afford failing that many times, then you just go any kind of “safe” way. But yes, FreeGLUT should be the right solution and I will use it as soon as I have the time. But it always takes time.
If your only using the window management facilities (include context/core context creation) then using FreeGLUT and GLEW is completely sufficient. Do you need any of the fixed-function using FreeGLUT convenience functions?
This topic was automatically closed 183 days after the last reply. New replies are no longer allowed.