Jump to content


Photo
- - - - -

opengl vs gtk vs qt vs w/e else


  • Please log in to reply
8 replies to this topic

#1 Dr. Z2A

Dr. Z2A

    Dangerous free thinker

  • Members
  • 845 posts
  • Gender:Male
  • Location:San Francisco

Posted 12 April 2006 - 07:07 PM

I have recently taken an interest in programming GUIs. I am wondering what library would you all recommend to learn with. My only previous gui programming experience has been writing games with Allegro. I have decided against learning to use directx because I don't use Windows very much anymore. I don't use KDE, so I am thinking I wouldn't want to mess around with qt. What would you all recommend to use? (be it gtk, opengl, or something that I'm not thinking of)

#2 Venom

Venom

    SUPR3M3 31337 Mack Daddy P1MP

  • Members
  • 365 posts
  • Location:919

Posted 12 April 2006 - 07:22 PM

I have recently taken an interest in programming GUIs.  I am wondering what library would you all recommend to learn with.  My only previous gui programming experience has been writing games with Allegro.  I have decided against learning to use directx because I don't use Windows very much anymore.  I don't use KDE, so I am thinking I wouldn't want to mess around with qt.  What would you all recommend to use? (be it gtk, opengl, or something that I'm not thinking of)

View Post



OpenGL is something I used to use for video game programming.

I found it pretty easy, but its not something I'd code a GUI in. I mostly used it for 3D stuff.

I do think its got 2D architecture though, and image mapping is pretty simple, so if you want to use a base of images to map its probably going to be one of the good ones.

I don't really know much about other stuff, its really the only thing I focused in when it came to graphics programming. Hope it helps.

#3 jabzor

jabzor

    hax?

  • Agents of the Revolution
  • 1,146 posts
  • Country:
  • Gender:Male
  • Location:Northern Elbonia, fighting the lefties

Posted 12 April 2006 - 07:50 PM

GTK is rather universal (win/lin of any kind) if you are looking for just application front end to some powerful engine, but i wouldn't ever think of doing any games or anything in it
i just use it to make front-ends/wrappers for cli scripts/programs that people who don't like cli or programs that would really benefit from the gui

#4 Venom

Venom

    SUPR3M3 31337 Mack Daddy P1MP

  • Members
  • 365 posts
  • Location:919

Posted 12 April 2006 - 08:23 PM

OpenGL is cross-compatable as well.

#5 heprimm

heprimm

    Will I break 10 posts?

  • Members
  • 8 posts
  • Location:UK // 1872

Posted 13 April 2006 - 11:48 AM

This article on freshmeat gives an overview of some of the GUI toolkits available to use under X (and some which can be used under Windows too). It's a few years old now but some of what it says stands true today.

I'd personally reccomend GTK primarily because I've found it nice to work with under both X and w32 (w32 support now is much better now than it was when that article was written) - most people running X will have appropriate GTK libraries installed. There's always Glade if you want to develop interfaces visually.

As far as OpenGL and DirectX go, these are graphics libraries (and in DirectX's case, a complete multimedia library) which aren't used in simple GUIs. If you're making a screensaver or a game (for tiled games, use SDL) or something that would have graphics requirements beyond the those of simple widgets then you may want to consider using OpenGL.

Edited by heprimm, 13 April 2006 - 12:08 PM.


#6 jedibebop

jedibebop

    Dangerous free thinker

  • Members
  • 1,935 posts

Posted 13 April 2006 - 01:06 PM

GTK+ is for C, there is GTKmm for C++

QT is C++ only

both QT and GTK+, as well as wxWidgets have python/perl/lisp/some other language here bindings as well

#7 tiocsti

tiocsti

    rekcah-rebÜ

  • Banned
  • 676 posts

Posted 13 April 2006 - 01:41 PM

Apart from qt using kde, qt has nothing whatsoever to do with kde. You can eliminate opengl for gui applications, for the most part, it is not well suited for that. It is a graphics engine. The choices you should consider are basically three:

qt (gpl)
gtk+ (lgpl)
wxWidgets (lgpl)

Objectively speaking, the best among these is qt, it is just a really well designed class library. My second choice (or my first choice if developing a proprietary application) would be wxWidgets. It's pretty good, but not as good as gtk+ imo. Both will produce guis that look right on the native platform.

Gtk+ would be my last choice, and the only reason i'd use it is if you are afraid of c++.

I have recently taken an interest in programming GUIs.  I am wondering what library would you all recommend to learn with.  My only previous gui programming experience has been writing games with Allegro.  I have decided against learning to use directx because I don't use Windows very much anymore.  I don't use KDE, so I am thinking I wouldn't want to mess around with qt.  What would you all recommend to use? (be it gtk, opengl, or something that I'm not thinking of)

View Post



#8 Automaton

Automaton

    SUP3R 31337

  • Members
  • 169 posts

Posted 13 April 2006 - 01:53 PM

SDL is also verry nice - very easy to pick up, and has hooks built-in for openGL.

#9 tiocsti

tiocsti

    rekcah-rebÜ

  • Banned
  • 676 posts

Posted 13 April 2006 - 02:00 PM

SDL sucks for making gui applications, which is what the op asked about. It's a good library for tasks it is well suited for, though (games).


SDL is also verry nice - very easy to pick up, and has hooks built-in for openGL.

View Post






BinRev is hosted by the great people at Lunarpages!