Skip to main content
GameDev.net gamedev.net
🔒 Locked

GUI selection in OpenGL, C++

Started by DonceLT May 26, 2011 at 7:26 PM 3 replies 2.8k views
Original Post
DonceLT
DonceLT
Currently I am working on a C++ OpenGL traffic simulation, and the main problem GUI. I have created my own classes like table, button, label. The problem is that it is getting very complicated and I am wondering, is it worth using some GUI library or windows GUI?
Dunge
Dunge

Currently I am working on a C++ OpenGL traffic simulation, and the main problem GUI. I have created my own classes like table, button, label. The problem is that it is getting very complicated and I am wondering, is it worth using some GUI library or windows GUI?


It's easy to create a smaller viewport than you window and use Windows controls. In .NET it would probably be the best way, but in C++ the Win32/MFC api is rather crappy and you will curse a lot. You can also continue on your path, and create your own GUI, but that's a lot of job. There are libraries you could use, but they are rare. The most common one is probably CEGUI.

By the way, I'm also working for traffic management. Would love to hear more about your project.
wqking
wqking
If you mean Windows GUI, I would recommend wxWidgets, easy to use and relative lightweight.
If you don't mind very heavyweight, Qt is another choice.

If you mean GUI in OpenGL, maybe look at GLUI? I don't have any experience on it.

Since your UI is complicated, don't do it yourself, choose an appropriate existing library, then spend your time on game logic.
DonceLT
DonceLT

[quote name='DonceLT' timestamp='1306437993' post='4816144']
Currently I am working on a C++ OpenGL traffic simulation, and the main problem GUI. I have created my own classes like table, button, label. The problem is that it is getting very complicated and I am wondering, is it worth using some GUI library or windows GUI?


It's easy to create a smaller viewport than you window and use Windows controls. In .NET it would probably be the best way, but in C++ the Win32/MFC api is rather crappy and you will curse a lot. You can also continue on your path, and create your own GUI, but that's a lot of job. There are libraries you could use, but they are rare. The most common one is probably CEGUI.

By the way, I'm also working for traffic management. Would love to hear more about your project.
[/quote]

Well, my project is still in development, so there isn't much to tell. I have few videos, but it's quite old, so it's not worth showing. Maybe I'll write about it in the future. What about your project, could you give some info about it?
RabblePants
RabblePants
Check out the UI library + Editor I put together - www.otterui.com. It's not quite as involved as CEGUI, but it'll (hopefully) get the job done for you pretty quickly. Also, if you don't want to worry about OpenGL / DirectX / etc rendering, there are sample renderers for you to get you going quickly.

Topic Locked

This topic has been locked by a moderator. New replies are not allowed.

Sign in to reply to this topic.