Jump to content
  • Advertisement


  • Content Count

  • Joined

  • Last visited

Community Reputation

122 Neutral

About meZmo

  • Rank
  1. Make sure you're generating and embed a manifest in your exe. Visual Studio will do this for you if you tell it to.
  2. meZmo

    Multiple windows one device?

    Actually, for d3d9 you don't even need to create multiple swap chains. Just render and _present_ your scene once for each window, making sure your swapchain is at least as big as the largest window (full screen sized makes that easier), and that your viewport is correctly sized for each window's client rect. Then, when you invoke Device::Present, pass your window handle as an override to present to that specific window. -meZ
  3. Unless you're working on "the next big thing", GetCursorPos in combination with ScreenToClient should do just fine. Don't be confused by Ron's code, it has a small error: the WM_MOUSEMOVE data is already relative to the client rect, so you shouldn't use ScreenToClient in that case. There really isn't any reason to get into DirectInput for mouse input, Microsoft doesn't even recommend using DI for mouse/keyboard.
  4. Matt's suggestion is a good one. Nvidia tends to accept more errors and still render correctly, it might be that your app has been slightly broken all along, but nvidia drivers just ignored the error and kept steaming on. Also, assuming you're using d3d9, there used to be cases where nvidia would fill in missing data with white, whereas ati would return black, though I'm not sure if that is still the case.
  5. How are you getting your mouse coordinates? DirectInput GetDeviceState returns relative mouse movements, not absolute positions. If you have correct absolute positions from somewhere else, they're probably in the wrong "space". Did you forget to transform them from screen to window coordinates? Or did you not supply the correct window styles when transforming them to the client rect? Adding magic numbers is bound to give you trouble.. e.g. when you transition to full screen mode and your window no longer has any borders.
  • Advertisement

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

GameDev.net is your game development community. Create an account for your GameDev Portfolio and participate in the largest developer community in the games industry.

Sign me up!