Jump to content
  • Advertisement
Sign in to follow this  
jagguy2

another UI and directx

This topic is 3817 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, q1)In my program i want another screen where i change the settings with directx/c++. So i ht maybe F1 and i goto another screen to change something then come back and continue the program with a new setting. In directX is there an easy way or do i need to call another screen with win32 code? how do i do this again? q2) To have a settings window (another screen)with UI controls on a screen do I use regular c++ win32 COM objects or can i use .net managed code or even Visual Basic.net? So i will have a directx program that you hit f1 and goto a a setings page written in VB.net.

Share this post


Link to post
Share on other sites
Advertisement
The usual options are:
1. A separate config app run before the main app, that enumerates devices, presents options and saves the results to an ini/registry. (e.g. Lucasarts games?)
2. Enumerate and render the directx options (resolution etc) in the app and call Reset() etc. on the directx device with the new settings. (e.g. id software games, DirectX 9 examples)
3. A combo where a regular Windows dialog is spawned by the main app and effectively does the same thing as 1, but finishes by doing 2. (e.g. DirectX 8 examples).

Share this post


Link to post
Share on other sites
thanks for the replies

q) I want a vc++ program using directx to enable f1 and goto a a setings page written in VB.net, which returns variables. Is this possible?

Share this post


Link to post
Share on other sites
Possible, but probably not too easy or efficient. Accutually, probably quite hard. I would recommend looking at UI libraries instead.

Share this post


Link to post
Share on other sites
If it's already a vc++ program, I'd investigate Modal Dialogs. You can put your options in that. It won't be .net and it doesn't have to be COM.

http://www.devarticles.com/c/a/Cplusplus/Using-MFC-in-Cplus-Dialog-Boxes/1/
http://www.functionx.com/visualc/controls/dialogbox.htm

You can catch F1 from your message loop or a Keyboard Accelerator. If you don't know what these things are I think you have a lot of reading to do on MSDN!

Share this post


Link to post
Share on other sites
ok i will have a look at it.

one more q) to test for key input in directx in am using GetAsyncKeyState(some key )) but is there a dirextx way that is better?

Share this post


Link to post
Share on other sites
Quote:
Original post by jagguy2
one more q) to test for key input in directx in am using GetAsyncKeyState(some key )) but is there a dirextx way that is better?


Not really. DirectX contains a component called DirectInput that provides keyboard data, but you'd be better off just using the WM_KEYDOWN and WM_KEYUP messages that Windows sends to your WndProc already.

Share this post


Link to post
Share on other sites
Also check out the DX samples that come with your DX SDK (it's somewhere in the SDK folder look for it). They (and the DXUT library) should provide some decent GUI for changing DX settings.

Share this post


Link to post
Share on other sites
Quote:
Original post by DvDmanDT
Possible, but probably not too easy or efficient. Accutually, probably quite hard. I would recommend looking at UI libraries instead.


what UI libraries are these ? you mean the UI option on VC++ express for instance?
These are MFC?

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.

Participate in the game development conversation and more when you create an account on GameDev.net!

Sign me up!