Should i learn GLUT or SFML?

I am stuck between GLUT and SFML... Everything i try to do in GLUT NEVER works :( Soooo :D Advice?
I've not yet tried GLUT but SFML is a good library, used with C++, cross-platform and glut can even be used on SFML. I also has a network package, and supports multi-threading.
Maybe googling SFMLvs GLUT might give you some results.

I'm a very big fan of SFML, though to be fair I haven't used GLUT very much.

SFML is nice in that it covers more area than GLUT (it also does audio, gamepad input, etc). And it's also OOP which means it's harder to "misuse".
Correct me if I'm wrong but:

GLUT is a wrapper for OpenGL. SFML is a wrapper for a window manager and can create your OpenGL canvas, you still need to OpenGL (of course it can do other things too). Since the OpenGL part isn't done by SFML, you can still use GLUT at the same time instead of writing directly with OpenGL.

Therefore use SFML for your window manager and/or 2d graphics. Use GLUT for the OpenGL wrapping. They are not exclusive libraries.
Last edited on
I thought GLUT was a window manager? And wrapped things like texture loading (which SFML also does).

(Likely not comprehensive) feature list from the GLUT webpage:

Multiple windows for OpenGL rendering
Callback driven event processing
Sophisticated input devices
An 'idle' routine and timers
A simple, cascading pop-up menu facility
Utility routines to generate various solid and wire frame objects
Support for bitmap and stroke fonts
Miscellaneous window management functions

SFML does most of that, but granted not all of it.
Last edited on
SFML seems like the better choice I think. I don't know much about GLUT, but its not as widely used as SFML or SDL.
SFML is semi obscure, so GLUT is likely far more widely used.
Topic archived. No new replies allowed.