Background:
I am now using cocos2d-x v3.10 to develop 3D games.
Now I have some 3D models with different #parts# which shares the same materials.
Because there will be expected to have hundreds and thousands of this models to be existed in my game. So I planned to see if it is possible to reduce the GL call for each model with different parts.
Current situation is that one part of the model will have 1 GL call.
Problems:
Since I am new to OpenGL, so I am not sure if the planned direction is correct. Please correct me if I am wrong.
- To make sure the material (or even mesh) is the same, the shader and the texture should be the same. I cannot find any method to achieve for the current version (I found that it is still under improvement now). Please suggest if I am correct and give me some direction if I went wrong.
- Unlike Quad and Triangle, each part of a model will have its own Mesh, MeshCommand, Technique and Passes , please let me know if I should prepare a buffer and group together like what Quad and Triangle do, or the other directions to go for.
I am not exactly sure if my thoughts are correct or not, so please let me know if there is anything uncertain in my words. I will try my best to make the situation as clear as I can do. Thank you all in advance.