Archived

This topic is now archived and is closed to further replies.

GUI help please?

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

I''m creating a fullscreen DirectX application using the 6.1 SDK, in C++. I don''t want to upgrade to DX8 because I''ve just learned DirectDraw and don''t feel like relearning how to make 2D apps in the new way right this second (tho i will in the future). So here''s the problem, I''d like to create GUI items like buttons, edit boxes, scroll bars, list boxes, etc. without having to flip to GDI or relying on the existing windows controls, if possible. I can make a working button, that''s no problem, but the rest I''m not sure how to make. Does anyone know where I can find code so I can see how it can be done and create my own? Or where I can simply acquire them and plug them in to my app? I much prefer to spend my programming time on trying to get my programs to run properly "behind the scenes" then trying to reinvent the wheel if possible. I would like to know how it''s done of course, but at this point I''m very frustrated and am hoping someone can point me to working ones. I''d appreciate any advice/help/links/etc. This forum has been a huge help in the past, and I hope it will be again. =) Thanks!

Share this post


Link to post
Share on other sites
I think I can help. Just recently, I have been writing my own GUI in directx, and it works rather well. I can give you my code, if you''d like, so you can look at it, get a feel for what you need to do, or you can even use it yourself if you like it. My screen name on AOL or AIM is ImmigrantMarbles. That is the best place to get ahold of me and I''d MUCH RATHER you do that than write me an EMail. I HATE EMails. However, if you must, my EMail is VChelaru@hotmail. But if possible, please IM me. Thanks.

--Vic--

Share this post


Link to post
Share on other sites
Okay so you hate DX8, but is there anything wrong with at least using DX7.0?? It fixed a few annoyances I had with doing 2d stuff with 6.1...

just my 2 cents..

Share this post


Link to post
Share on other sites
A game I''ve been working on uses a GUI that i''ve made from scratch.
It takes some time, but once you have everything nicely put into classes and things, you''ll find the implementation is rather easy.

I made several classes that make up my form objects such as a textfield and radio button set.


The only thing that may be a problem, or what I found to be a problem was to figure out which field had the "focus", or the one that was just clicked on and is possibly having text entered into it.
What I did was simply create a pointer to an object of the textfield class and then simply pass the pointer into a method or function that would perhaps return characters that were pressed.
Also, don''t forget that with typing, you have to figure out if a key has been pressed, and not necessarily being held down to ensure you don''t have 30 letters show up whenever you press any key.

Share this post


Link to post
Share on other sites
quote:

Also, don''t forget that with typing, you have to figure out if a key has been pressed, and not necessarily being held down to ensure you don''t have 30 letters show up whenever you press any key.



hehe... I know what relish was talking about. I learned that the hard way(spent a couple days trying to make a AsciiKeypressed function that should''ve only taken an hour).

That article in the beginner''s section by Mason McCusky is really good!

Newbie to game programming?
visit

KaBooMgames
Great for Newbs, Masters welcome as well

Share this post


Link to post
Share on other sites