Jump to content
  • Advertisement
Sign in to follow this  
amigocz

Max array size for Vertex Shader

This topic is 3671 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 trying to implement a Shader Instancing to improve my particle system's performance. So I just pass an array of all the nesesary information into the Vertex Shader and I'm just wondering how big arrays can I make using D3D9 to reduce the number of draw calls as much as possible. Is there any way how to compute this value and does it vari on different graphics cards? Or is there any recommended size?

Share this post


Link to post
Share on other sites
Advertisement
Direct3D 9 supports a maximum of 256 vertex shader constants. The actual number is in the MaxVertexShaderConst cap (you can check out the card caps document in the SDK for this value on quite a few cards). (Direct3D actually supports more than 256 constants, but no cards, even not D3D10 ones which could, supports that.) Availability of constants will determine the maximum array size.

However, I see little reason not to use real instancing.

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!