Jump to content
  • Advertisement
Sign in to follow this  
gencha

Multisampled Rendertargets

This topic is 3674 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 am working on a Direct3D9 project and am trying to get multisampling to work. Now, sadly, when i enable Multisampling on the backbuffer and the postprocessing rendertargets i only get garbage. No actual scene geometry is in my rendertargets. Now, i am aware of the fact that i have to render to a rendertarget created by CreateRenderTarget with multisampling enabled and then StretchRect into a texture that i can use for postprocessing. But somehow i think that is not the problem here. I ran the application through PIX to check the contents of my textures during the draw calls and their content never changes. The app sets the new rendertarget and does some draw calls but the content of the rendertarget is still the memory garbage that's usually in there :P I check all return values from D3D and they're all S_OK, i used the debug runtime and besides the warnings about duplicate states there is nothing it complains about. Just to be clear on this, if i just disable multisampling, everything runs as expected. The rendertargets are filled with whatever i am drawing and then later copied by StretchRect for processing. And help on why this happens would be greatly appreciated.

Share this post


Link to post
Share on other sites
Advertisement
I'm not sure, but I think your render targets have to all the same size and format.
That's probably your problem

Share this post


Link to post
Share on other sites
The sizes all match those of the backbuffer and for testing purposes i set all rendertargets and textures to D3DFMT_A8R8G8B8 but that doesn't solve it.

Share this post


Link to post
Share on other sites
Yes, at first i was simply using EnableAutoDepthStencil but right now i create the DepthStencil surface manually.
The outcome is always the same.

Share this post


Link to post
Share on other sites
As it turns out the problem was MRT. I did not know that it is not compatible with FSAA.

Thanks anyway :)

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!