Jump to content
  • Advertisement
Sign in to follow this  
bdachev

DX11 Is it possible to disable MSAA on the fly?

This topic is 1499 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 Guys,

 

I have an application based on both DX9 and DX11.

It renders 3D scene using MSAA. 

I would like to disable MSAA only while drawing certain objects (lines in particular).

For DX9 I found that setting D3DRS_MULTISAMPLEANTIALIAS render state to FALSE does the job.

For DX11 as far as I understand it even though lines are not anti-aliased by default (i.e. unless one of MultisampleEnable or AntialiasedLineEnable fields of D3D11_RASTERIZER_DESC structure are set to TRUE as stated in MSDN) they got blended with underlying pixels resulting semitransparent.

See attached images generated with no MSAA and MSAA set to 4.

 

In short my question is whether it is possible in DX11 to disable multi-sampling on demand and per drawing call?

 

Thank you in advance for you help!

 

Best regards,

Boris.

Share this post


Link to post
Share on other sites
Advertisement

You may want to change the rasterizer state in order not to do MSAA . It's better to sort your work so that you make minimal changes to rasterizer state. 

Share this post


Link to post
Share on other sites

Hi BlackBrain,

 

Thank you for the reply!

Could you be more specific?

Which parameter of the rasterizer's state should be changed in order to avoid the problem I am experiencing?

Currently in my app both MultisampleEnable or AntialiasedLineEnable are set to FALSE (which is the default).

As I said in my previous post the line itself is actually aliased.

The problem I have is that the pixels of the line are sometimes blended with underlying pixels.

 

Best regards,

Boris.

Share this post


Link to post
Share on other sites

Further to my previous post I just did the same test on my home laptop with NVidia card and lines are drawn as expected.

My office has ATI card so it looks like the problem has something to do with ATI's implementation of DX11.

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!