Jump to content
  • Advertisement
Sign in to follow this  
Salv0

Choosing between WPF, wxWidgets, Win32 API and MFC

This topic is 3256 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

Imagine you are on Windows 7 and you have to write a GUI for a GRAPHIC application, (like a terrain editor, mesh viewer ..) which involves a great use of DirectX and OpenGL (so written in native C++). If your goal is a multi-platform software then you should go for wxWidgets, but imagine you're doing a Windows' only app...what would your choice be? and why? I'm supposing that the application would work on both XP and Vista/7 and obviously in the WPF case the UI will be managed, but it will call native functions by a C++/CLI proxy-like class ( will "bouncing" from managed-native and native-managed cause performance issues? ). Thank you in advance for the answers

Share this post


Link to post
Share on other sites
Advertisement
If the rendering engine were native C++, I would probably use a C++ GUI toolkit like Qt. I would definitely stay away from MFC, there are better alternatives.

WinForms or WPF are more useful if the rendering engine is also managed, otherwise you'll have to write tedious interop code that is not trivial if you're not familiar with the low-level mechanics of the CLR. And yes managed->native transitions are most definitely not free, and can result in performance issues if you do it a lot. For UI stuff you probably wouldn't notice it.

Share this post


Link to post
Share on other sites
For me I'd pick wxWidgets any day, the main reasons for this for me is:

1) It is open source.
2) Free.
3) Can be compiled into a static library, which for my applications is very important.
4) There's not a load to learn in comparison with QT which has libraries for everything. On the other hand, this means that you may have to write more code than you would with QT.
5) Cross-platform.

I would have picked QT but it fails on the third point and still requires the user to install the Visual Studio Runtime, although as you're using DirectX which involves the user installing a runtime anyway, then it's up to you... Personally I'd still go with wxWidgets,

Share this post


Link to post
Share on other sites
Quote:
Original post by Salv0
If your goal is a multi-platform software then you should go for wxWidgets

Honestly, if multi-platform were on the wishlist, I'd seriously contemplate WORA functionality. So, one of the big two managed frameworks - .NET/Mono (WinForms, WPF, et al), or Java (AWT, Swing...).
I'd then take a great-deal of care in designing an architecture for interop between the managed core and native graphics implementation modules. Certainly not an easy route, but the resultant system is very useful.

Quote:
Original post by Salv0
but imagine you're doing a Windows' only app...what would your choice be? and why?

I'm supposing that the application would work on both XP and Vista/7 and obviously in the WPF case the UI will be managed, but it will call native functions by a C++/CLI proxy-like class ( will "bouncing" from managed-native and native-managed cause performance issues? ).

Well, forget performance issues - for a non-potable app, native/managed interop is probably just unwarranted complexity.
If you're not extremely confident with pure Win32, and/or have no reason to dabble on that low of a level, grab a library like wx or Qt. Hell, if you can find a good WPF wrapper for native C++ that abstracts the interop, you could go for that, too. Just make your job as simple as you possibly can whilst still meeting objectives of the project. ;)

Share this post


Link to post
Share on other sites
Sign in to follow this  

  • Advertisement
×

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

We are the game development community.

Whether you are an indie, hobbyist, AAA developer, or just trying to learn, GameDev.net is the place for you to learn, share, and connect with the games industry. Learn more About Us or sign up!

Sign me up!