Sign in to follow this  
zny

a question about hlsl's semantics

Recommended Posts

hi everyone, when i read the DirectX's Sdk, it said: TEXCOORD[n],n is an optional integer between 0 and the number of resources supported. i want to know how can i get the n's value exactly.

Share this post


Link to post
Share on other sites
For DX10 and up: http://stackoverflow.com/questions/1414891/directx-device-caps

In summary all DX10 hardware has a minimum set of functionality.

And http://msdn.microsoft.com/en-us/library/bb174320%28VS.85%29.aspx for retrieving device capabilities.

Share this post


Link to post
Share on other sites
the amount of texcoords in pixel function input depends on pixel shader target you compile hlsl against. In 2.0 target it is 8 texcoords, in 3.0 I do not know how much but you can test it easily-just add texcoords until shader compiles.

Share this post


Link to post
Share on other sites
Quote:
Original post by JohnnyCode
the amount of texcoords in pixel function input depends on pixel shader target you compile hlsl against. In 2.0 target it is 8 texcoords, in 3.0 I do not know how much but you can test it easily-just add texcoords until shader compiles.


this means that n is related the shader model version, not the hardware.
many thanks

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