Development of an optical sensor for the measurement of surface roughness and waviness