Jump to content
  • Advertisement
Sign in to follow this  
EnochDagor

Set Wrap0 in Effect File

This topic is 3816 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

Ok, so I have a line of code that makes it so that rendering textured spheres is not ugly. moDevice.RenderState.Wrap0 = WrapCoordinates.Zero Now, I wrote an FX file to render a sphere with some cool effects and stuff... but it seems that setting this render state does not affect the FX file. So... how do I do it now? To illustrate the issue: Image with Artifact Old Way, without artifact -E

Share this post


Link to post
Share on other sites
Advertisement
Could you paste some code about how you're trying to set this renderstate from the effect file?

Share this post


Link to post
Share on other sites
Ok I have tried several renditions...

Outside of the .fx file:

moDevice.RenderState.Wrap0 = WrapCoordinates.Zero
// set up our effect here
// render the sphere
// end the effect
moDevice.RenderState.Wrap0 = 0

Inside the .fx file:

technique NormalMapTech
{
pass P0
{
Wrap0 = COORD0;
//Do render calls
}
}

Always the same result. However, without the .fx file, everything works fine.

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!