Sign in to follow this  

Problem with AA and 2D screen elements

This topic is 3592 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 have a directX9 3D engine and want to enable anti-aliasing. When I set the present parameters.MultiSampleType to anything other than D3DMULTISAMPLE_NONE the 3D looks fine, but the 2D interface is misaligned with 1-pixel gaps at the joins and other artefacts. Can I disable anti-aliasing on the 2D interface? I am thinking maybe I could use a pixel shader and perform anti-aliasing before the 2D is drawn - would this be slower than using the hardware flag? thanks in advance!

Share this post


Link to post
Share on other sites
thanks that is a good read.

I think my problem is slightly different though. My problem is that two 2D elements that appear to sit next to each other with no multisampling (i.e/ no gap between them) appear to be one pixel apart once the multisampling is enabled.

Share this post


Link to post
Share on other sites
Quote:
Original post by Bluud
thanks that is a good read.

I think my problem is slightly different though. My problem is that two 2D elements that appear to sit next to each other with no multisampling (i.e/ no gap between them) appear to be one pixel apart once the multisampling is enabled.


I'm not sure if there is an easy way to do what you want to do... Don't quote me on that, but I've seen many retail games suffer from this same dilema (although it's not as obvious since their ui elements either take this into account or are very basic anyway (fps games, etc)

Share this post


Link to post
Share on other sites
ah thank you MJP this has saved me! I was about to totally rewrite the way my UI is rendered until you told me that you could disable AA per object! Fantastic !

Share this post


Link to post
Share on other sites

This topic is 3592 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.

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

Sign in to follow this