Maxence 1 Report post Posted December 19, 2013 Hi, Thanks Deltakosh for your wiki page about merging meshes (https://github.com/BabylonJS/Babylon.js/wiki/How-to-merge-meshes).It helped me to create a function to merge a mesh to another one. I added the function to your Mesh class and I could send you a pull-request if you want. Nevertheless I'm not totaly happy about it since I didn't manage to avoid to create a new mesh to contain the result of the merging. Indeed, I think it could be helpful to directly modify the first mesh to be the merged mesh, thus the process could be simpler to chain meshes merging (and I need this ) and more efficient. Here are two jsfiddles. The first one gives the good result but a new mesh has to be created, the second one avoids the creation of a new mesh but the result is translated and I don't understand why. http://jsfiddle.net/MaxenceBrasselet/epzrV/ http://jsfiddle.net/MaxenceBrasselet/epzrV/1/ (only two lines are different: l48 and l65) Quote Share this post Link to post Share on other sites
Deltakosh 4315 Report post Posted December 20, 2013 Because you are baking your worldMatrix into vertices, do not forget to set position, rotation and scaling to default values on your mesh Quote Share this post Link to post Share on other sites
Maxence 1 Report post Posted December 20, 2013 Thanks for your answer, I found a solution this morning, could you please tell me if it seems to be the right way to solve the problem. I made a jsFiddle to explain my choice. http://jsfiddle.net/MaxenceBrasselet/epzrV/5/ (change l61 and l70-75). Quote Share this post Link to post Share on other sites
Deltakosh 4315 Report post Posted December 20, 2013 This is correct Quote Share this post Link to post Share on other sites