- kill some dead code
- allow to pass in mesh segment settings in options