The paper established the edge alignment function firstly and carries on the global registration for the sample PCB image and testing PCB image through the sampling characteristics point. Because camera lens distortion caused the image non-linear distortion, the local registration had some deviations after the overall registration. We proposed block registration strategy, to solve local image alignment issue and simultaneously carried on the edge fitting with the method of least square according to the ruptured phenomenon between the block and block. Finally image ...