Jump to content
  • Advertisement
Sign in to follow this  

DX11 Window resize handling with DX11

This topic is 2617 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 using DX11, and I have trouble with full-screen transitions. I've registered my swap chain with DXGI_SWAP_CHAIN_FLAG_ALLOW_MODE_SWITCH, so I should be set to get automatic resizing when Alt+Enter is pressed. I'm also correctly passing this flag when calling ResizeBuffers(). However, pressing Alt+Enter does not always raise a WM_SIZE message. In fact, the first few times, the window switches to fullscreen but I don't get any WM_SIZE event; I've checked with Spy++ and nothing gets delivered to my app. For instance, I have a 1280x720 window and when I press fullscreen (which should switch to 1680x1050), I don't get any event mentioning 1680x1050 so there is no way I can capture this. On the same machine, I sometime get correct WM_SIZE events when I repeatedly try to resize the window (for instance, when I kept pressing Alt for a second after pressing enter, a WM_SIZE would be delivered.) What the heck is going on? Right now, I'm not getting any WM_SIZE events any more, no matter how often I change to fullscreen and back, but I get all resize events correctly when resizing the window by grabbing a corner.

How am I supposed to handle full-screen switches? I would like to avoid having to handle Alt+Enter manually, as I use RawInput (however, I didn't specify the NOLEGACY.) It's interesting that I can see the window switching to fullscreen but no WM_SIZE :(

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.

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!