Jump to content
  • Advertisement
Sign in to follow this  
lucky6969b

C++ Compile shaders inside of IDE

Recommended Posts

Is it possible to compile shaders directly from the IDE? What I tried -> when you right-click on the .fx files on the IDE file pane, you've got a few options, one of which is to choose which program to open that file, if you choose the fxc.exe, you can't really compile anything, you also have exclude from build and item type option inside properties.

Any one sheds some lights on this?

thanks

Jack

Share this post


Link to post
Share on other sites
Advertisement
Posted (edited)

You can add .hlsl files to your solution, and they will be compiled to .cso objects when building (remember to right-click them in the Solution Explorer and set stuff like shadertype, shaderversion, entrypoint etc.), which you can then use directly in your program using DX11Device->CreatePixelShader(...) etc.!

 

Edited by vinterberg

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  

  • 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!