optical encoder layout generator