Jump to content
  • Advertisement
Sign in to follow this  

Usage flags for depth stencil surface

This topic is 5194 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 using the DepthStencil usage flag for my depth-stencil surface but I'm wondering whether I need to use the RenderTarget flag as well? Also, if you create a render target with the DirectX function you can specify multisampling settings but you can't do that when you create the surface as a texture can you? (I have to do that to use it as a texture in an effect) Also, if you create a depth-stencil surface with the DirectX function you can specify the PresentFlag but I don't think you can do that when creating as a texture can you? It's a shame with the cited benefits:
Enables z-buffer discarding if set when the device or swap chain is created. When this flag is set, the contents of the depth stencil buffer are invalid after either Device.Present or Device.DepthStencilSurface are called. Discarding z-buffer data can increase performance and is dependent on the driver. The debug runtime enforces discarding by clearing the z-buffer to some constant value after calling either Device.Present or Device.DepthStencilSurface with a different depth surface.

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.

GameDev.net is your game development community. Create an account for your GameDev Portfolio and participate in the largest developer community in the games industry.

Sign me up!