refactoring planeMesh