Added flexible generation of sliced meshes, plus module test