Sign in to follow this  

How I can have UI Controls for game engine ?

This topic is 3777 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

Hi, I am making a game engine, which covers video, sounds, physics etc. I am using DX9 for all that stuff. Now I need to make UI or GUI part of it. Controls like: Button, Slider, Editbox, Checkbox, Radio button and other common controls, I wish to make. I need to have their custom look (programmer/artist should be able to change look as per textures they provide). What should I do for this? I have a little idea about sub-classing controls, is that work in DirectX mode? .. maybe I need to create controls on my own? or some library available of it? I wish I could change the look of controls (of windows and use thhem in engine)? any Suggestions/Guidance? [Edited by - DLight on August 12, 2007 1:26:59 PM]

Share this post


Link to post
Share on other sites
If you're using MDX (and in the future SlimDX), you could take a look at my own library (link in signature). It doesn't use textured control (so you don't have to paint your own) but creates controls by computing their shapes using vertices. Skinning will be introduced in the next version.

Share this post


Link to post
Share on other sites
I don't see why you can't sub-class controls.

If you're not using .NET, it'll be a little more tricky, though.

But pretty much extend MFC UI components and override their repaint logic to draw (via DX) your textures.

If that's not possible, I apologize for misleading you - but it seems like a simple, workable solution. It would let you capture events and all the rest of that without having to code that yourself.

Of course, there's always the SDK UI sample. Haven't done too much with that, but it should also suit your task just fine - extend those classes and you'll have pretty much every common control you need.

Share this post


Link to post
Share on other sites

This topic is 3777 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.

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

Sign in to follow this