- refactored cubic line generation