working on mesh generation