Jump to content
  • Advertisement


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


quick question

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

what happens if i initialize directinput twice? i was just given this huge program. it uses directx the guy before me used directx5 to 7 i just realized that he was initializing directx by DirectInputCreateEx(g_Hinstance, DIRECTINPUT_VERSION, IID_IDirectInput7, (void**)&g_lpdi, NULL); at some part of the program while i was initializing another with if (FAILED(DirectInput8Create(GetModuleHandle(NULL), DIRECTINPUT_VERSION, IID_IDirectInput8, (void**)&lpdi, NULL))) return false; can i do that? initialize it twice? btw. i am getting an error msg for his initialization ... [edited by - paymonh on July 25, 2002 4:02:08 PM]

Share this post

Link to post
Share on other sites
No, you shouldn''t do it twice. You can but shouldn''t. It creates two sepereate contexts for input stuff to work in and you would have to manage it for no reason at all.

Stephen Manchester
Senior Technical Lead
Virtual Media Vision, Inc.
(310) 930-7349

Share this post

Link to post
Share on other sites

  • 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!