Jump to content
  • Advertisement
Sign in to follow this  

Context menu decreases performance

This topic is 3456 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. I'm building an editor for my 2d game in C# and wish to switch to DirectX (using SlimDX) for rendering from GDI/BufferedGraphics. Performance is great, but when I cause a context menu to appear, or any other Windows element (such as clicking the Start button) performance massively slows down until the menu/element disappears. I've noticed a similiar problem with other DirectX games in windowed mode. Is there a solution other than stopping rendering when a context menu appears, and restarting when the menu disappears? Many thanks.

Share this post


Link to post
Share on other sites
Advertisement
XP64, but the same thing happens on XP32. Or at least I am assuming it does, as the same issue occurs with the same Direct3D games on that platform.

Share this post


Link to post
Share on other sites
Perhaps your app is running at lower priority due to being forced into the background because of the menus? Direct3D apps don't usually run very well as background apps, especially if they are embedded in WinForms controls.

Share this post


Link to post
Share on other sites
I've found the solution.

You need to set the Multisample type to NonMaskable in the PresentParameters structure.

Thanks for the replies.

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!