The material recognition and size measuring cell is very important for the development and practicability of flexible manufacturing system (FMS). However, the existing FMS mostly recognize the two-dimensional shape of the workpiece, measure the one- dimensional shape of the finishing product. This greatly limits the performance of FMS. In this paper, these cells have been optimally designed to identify and measure the three-dimensional shape of the workpiece based on the optical measurement principle. The method has the advantage at robust recognition rate and high recognition quality.