Original Post
Hy all, I
m trying to implement an effect file based shader system. But its not so easy. After thinking a few hours. I ended up with 2 similar solutions.And I don`t now wich one to choose. 1] We have an effect file for each render path(dx7,dx8,dx9...) wich contain several techniques. Each technique will do different things. There will be one technique for drawing static meshes other for drawing animated meshes, and other for drawing skyboxes..... Sub mesh classes will store material info(like diffuse color, textures and the name of the technique that we have to use for rendering) Then i will use a render queue to sort sub meshes by technique and material. 2] The second version is similar. We have many effect files. One effect file contains technique for renderig static mesh, another effect files contains technique for rendering animated meshes... Sub mesh class still store material info but this time but instead of technique name itt will contain the name of the effect file. Then i will sort the sub meshes by effects and material. I forgot to mention that in 2 version could contain 3 techniques one for dx7, one for dx8 and one for dx9. Please Help!! PS: Sorry for bad english :(