Jump to content
  • Advertisement
Sign in to follow this  
Wizecoder

Need advice on a game engine shader system.

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

I have started up a game engine project that uses dx10 and one thing that i was having trouble deciding on was how to handle the shaders. The options that i have thought of so far are: having the user assemble there own shaders using a shader library that will be packaged with the engine; have a shader fragment assembler inside the engine that assembles shaders based on certain parameters; use and ubershader system. I would appreciate any input on these systems and other options. Thanks. :)

Share this post


Link to post
Share on other sites
Advertisement
If your users aren't going to be graphics programmers, then just implement bump mapping, specular mapping, etc (whatever effects you want), and then let the user choose their shader with an enum or flags, etc...

But if your users are going to be graphics coders, then perhaps they will be comfortable plugging their own .fx files into the engine...
If you take the custom-shader route, it's probably wise to have a bunch of "standard uniforms" that the engine will send to shaders, like lighting or material properties.


Another issue to consider is how you are going to implement lighting in your engine (because this will affect how the users will have to write their shaders).
Forward or deferred? Multi-pass or multi-shader? If forward will you z-pre-pass? If deferred will you light-pre-pass?

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!