Jump to content
  • Advertisement
Sign in to follow this  
jatobu

changeing the RenderState on HLSL

This topic is 4039 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 all, I'm trying to change the Render State in one of my shader codes (specifically, I want to change the DepthBias), I've been looking for some information on how to change it but couldn't find much. Anyone could help?... some doc's or any insight?? Thanks!

Share this post


Link to post
Share on other sites
Advertisement
In pure HLSL (just a shader) you can't.

In an FX file just add any render states into the pass block where the vertex and pixel shaders are compiled. ie: Just add "DepthBias = 2;" or whatever.

Look up "Effect States" in the SDK help index. All the supported states and settings are listed.

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!