Besides Qt, GTK, wxWidgets... What are the recommendations for a cross platform, open source GUI framework library that works with OpenGL?
Its not quite a GUI framework. But GLFW is good for an OpenGL window with some extra features like keyboard and joystick handling.
I found the other framework I was looking for. It is SFML. I only used it briefly but I do remember liking it very much. It does contain a lot of nice extras going a step further than GLFW. If I recall correctly the documentation was stellar.
For a full featured cross-platform GUI framework I think you would be hard pressed to beat QT, GTK, or wx.
I'm not sure, but at a guess, the other framework mfperzel was trying to think of might have been fltk (the "fast light tool kit"). Where glfw is mostly an OpenGL window with some ability to read the mouse and keyboard, fltk is a GUI framework that supports OpenGL (but as the name implies it's still quite a bit smaller and faster than most GUI frameworks). I haven't tried it yet, but there's a new GUI builder program for it (FLUID) that looks fairly promising as well. One warning though: FLTK uses its own widgets, which tend to look at least a little foreign to most users.
Related
I need to program a game, it's a card game actually, and I must make it with graphic interface, but I don´t know about C++ graphic interface libraries.
Is there something for C++ similar to Python's Tkinter or Pygame (I don´t know if there are others).
If there are libs, are they suited for building a simple card game?
The most common cross-platform GUI toolkit is Qt, I'd go with that for any C++ GUI application. Especially easy on Linux, all distros have packages for it, but Windows has binary installers too for different compilers.
You can use Netbeans, but I'd really go with Qt Creator for Qt programming.
For a card game with Qt, QGraphicsView is probably easiest, if you want animated card movement etc. For a more static UI, QWidget based one would be very easy. For a modern visually rich UI, QML (but then GUI part is not C++) would work very well.
Achilles heel of Qt for game development is real-time game sound effects, but you can mix Windows-specific sound stuff easily if you do not care about cross platform stuff, and card games don't need much there anyway, if anything. Also, I think Qt5 may actually have improvements for sound, making pure Qt good enough for games.
If it is a game, you may consider SDL
Fun fact: pygame is backed by SDL.
BTW, if you want to have GUI controls in your game( http://www.tayloredge.com/utilities/vbapps/gui.GIF ) , you will need a GUI library. Otherwise, a game library, like SDL, is more suitable for you.
I need a cross-platform GUI toolkit with OpenGL support. I also need to be able to draw on a canvas or panel from an image buffer. The candidates I've chosen so far are FLTK (it can do OpenGL windows -- I don't know about canvases), Qt, and wxWidgets.
Any idea which would be the best?
Thanks!
I would say Qt. But that might be argumentative question...
Hey Deep, XVT support openGL. It's a GUI cross-platform toolkit for C and C++ www.xvt.com
For simple things I would suggest GLUT or something similar. But for anything above a simple window into which you render some OpenGL, I strongly recommend Qt. But as tibur said, its probably a matter of taste.
Checkout the Ecere SDK. It's a feature rich cross-platform GUI toolkit, and it supports a variety of graphics driver (e.g. GDI, X11, OpenGL, Direct3D). It has a built-in 3D engine, but you can mix it with your own OpenGL code as well, there are samples showing you how to do just that. It was originally designed as a GUI system for in-game menus, so it supports full screen mdoe as well as windowed mode, but is now a general purpose SDK.
I'm making a game with OpenGL render api. Now I need in level editor. It should consist of lots of widgets parents/children etc, so it's hard to write need widgets by hands.
Any ideas about good gui-system which can be easilly connected with opengl? The most important part is gui editing. I really need some editing-tool for it.
Thanks
You should have a look to http://qt.nokia.com/ .
It is very easy to inject the OpenGL rendering into Qt widgets.
To easily edit your GUI, you can use Qt Creator ( http://qt.nokia.com/products/developer-tools ).
You have several options (and this has been answered before, but probably not exactly like this):
SDL: very good abstraction layer for audio, graphics and anything related. It will force you to write your widget stuff by hand.
Qt: has an OpenGL module that makes it easy to set up an OpenGL context. It will make widgets and everything very easy.
wxWidgets: same as Qt, but has slightly worse documentation and tools (if I might be so blunt)
I'd go with number two: it has a beautiful Designer tool to create Widgets with all the fancyness you'll need. OpenGL is also built right in.
If you're running Windows (can't confirm Mono will do it), another option would be to use C# and WinForms to make your life significantly easier.
Check out CEGUI:
http://www.cegui.org.uk/wiki/index.php/Main_Page
It defines its GUIs in XML and has editors for it.
Glut seems rather old, and SDL also as if it's not the youngest anymore - what is being used as (cross-platform) window manager for OpenGL nowadays?
Cross platform UI toolkit
1. wxwidgets
2. fltk
3. qt
4. glut(freeglut)
5. sdl
I have used glui. Sucks real bad(in terms of performance). There huge difference in performance penalty just by including glui(without actually using it) in your apps.
To be honest, i prefer platform specific UI toolkit. Faster. Reliable.
Depends on how you want to use it. Don't think there is a clear winner.
I like to use Qt because I'm familiar with it so it feels easy to me, and because I use it for other UI elements in my mostly windowed openGL apps.
Haven't tried it myself, yet, but want to in my next project. It seems to be very popular.
SFML . It`s the "successor" to SDL written in C++
I am using freeglut, but it is just a bit improved glut.
You can also use QT
I think GLFW is the best choice for small to medium applications/games. This type of libraries should be easy,small and fast with no extra services such as image helper functions and so on. GLFW is going to remove all helper functions to focus on the main goal.
QT is the best for graphics applications but not for games or small applications.
I'm searching for a OpenGL User Interface Library like WxWidgets but not OS dependent.
It would have to provide callbacks for user input since this is OS dependent.
If something like this doesn't yet exist (which I doubt because most games have most of the Basic UI Elements) is there a OpenGL HTML/CSS renderer?
FLTK, GTK+, and QT support OpenGL widgets in a portable way. QT in particular can render all of its widgets in an OpenGL viewport. I know there's been some work on getting GTK to do the same thing, but I haven't heard on the progress of it.
OTK comes up on a quick Google search as an OpenGL-backed widget library.
It's also worth pointing out that Cairo has an OpenGL backend, and there are a number of toolkits that depend on it, including GTK+.