• Advertisement
Sign in to follow this  

direct input 8 linker error

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

Below is the code from microsoft's DX sdk for creating a direct input object: // HINSTANCE g_hinst; // initialized earlier HRESULT hr; LPDIRECTINPUT8 g_lpDI; hr = DirectInput8Create(g_hinst, DIRECTINPUT_VERSION, IID_IDirectInput8, (void**)&g_lpDI, NULL); if FAILED(hr) { // DirectInput not available; take appropriate action } When I try to build this using VC.net I get an "unresolved external" linking error concerning the "IID_IDirectInput8" flag. I have no idea what the problem could be. I've included the dinput8 library and files and paths like I always do so I don't think it's that. It seems to take the DI structure and create function just fine, but chokes on the IID_IDirectInput8 flag. The linker actually specifies IID_IDirectInput8A as the unresolved external, but since I didn't define unicode that should be fine.

Share this post


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

  • Advertisement