Sign in to follow this  
ClementLuminy

Multisampled Antialiasing and Z Prepass

Recommended Posts

ClementLuminy    121
Hi everyone, I'm investigating multisampled antialiasing with Directx9, and i'm having a problem to make it work with my Z prepass system: Because i'm using DX9 and because i need the depth informations afterward, in the Z prepass, i render the scene depth informations into both the depth buffer and a depth texture. If i do not enable antialisaing, everythings works fine, but if i do, i get strange visual artefacts which looks like a problem with the content of the depth buffer. I suppose the problem come from the fact that my depth buffer is created to be used with multisampled render target, which is not the case in the Z prepass: The depth texture is a regular texture (i.e: not multisampled) created with CreateTexture. Is it possible to solve this issue with DX9 system? Thanks

Share this post


Link to post
Share on other sites
MJP    19755
You can't render to a non-multsampled render target with a multisampled depth buffer. The number of samples needs to match.

If you turn on the debug runtimes, it will warn you about things like this.

Share this post


Link to post
Share on other sites

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