Jump to content
  • Advertisement
Sign in to follow this  
  • entries
  • comments
  • views

Morning Coffee

Sign in to follow this  


Preparing to implement new parameter semantics and annotation naming conventions for effect files used in coordination with the shader material class. I just added an interface to the core shader class which allows parameter descriptions and handles to be retrieved. I also removed two overloaded member functions from the shader class due to the fact that my models now share the DEBaseModel abstract base class.

A list of the naming conventions, I will be implementing, is found below:

float4x4 (handle):DEVIEW;
float4x4 (handle):DEPROJ;
float4x4 (handle):DEWORLD;
float4x4 (handle):DEWORLDVIEW;
float4x4 (handle):DEWORLDVIEWPROJ;
float4 (handle):DEEYEPOSITION;
texture (handle):DETEXTURE;
texture (handle):DECUBETEXTURE;
sDELight (handle):DELIGHT;
sDELight (handle):DENALIGHT1;
sDELight (handle):DENALIGHT2;
sDEAmbientLight (handle):DEAMBIENTLIGHT;

My opinion: I certainly am glad that I have backtracked a few days in order to implement the shader material class in this manner. The material editor will be much more elegant than the clunky beast I had previously designed.

Further thoughts: I am considering applying annotations to each effect technique in the form so that the most appropriate technique (from a set of n techniques) can be chosen at load time for the current GPU based on compatibility. Another option is to add an order of precedence to the techniques in the effect where the nth technique found would be the preferred technique back to the first technique - which would be the least favored of the group. This would simplify shader development but I am unsure of how to choose the proper technique without testing to see if each fails at load time. If anyone has a better idea then I'd like to hear it.
Sign in to follow this  


Recommended Comments

There are no comments to display.

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