Original Post
Hi We are currently designing our new game engine (not a high end one :) ), and trying to implement some fancy shaders. Now the plan is to edit almost as much as we can, onfly in the game. The idea is to edit the shaders inside the game. But it requires some extra functionality, to be able to set vertex attributes (for example inverse tanget matrix) and uniform variables onfly. To accomplish this, we want define a base class. And for every variable settings, calculating the buffer values if necessary and setting the vertex attributes, setting the uniform variables, etc... we are derivating a class. When rendering an object with a shader, we would call 1-5 derived class throu the base class virtual functions. What do you think about this approach? Will it result an extremly slow rendering phase? We are planning to use similar approach to achive morph, matrix, and uv animations. Is it that a good approach or is there a better way to do this? Peter Balogh