Some shader refactoring.