The invention belongs to the technical field of additive manufacturing on-line measurement, and discloses an on-line detection method of the contour accuracy of a molding layer in the
laser selectivemelting process. The on-line detection method includes the following steps that S1, a model of a to-be-machined part is sliced, and an auxiliary image is generated; S2,
powder spreading is conduced, and then
powder is melted and molded in a
laser selective mode; S3, an image of a basic molding area is collected, and a contour of a segmented image is extracted; S4, the
image contour is subjected tothree-dimensional reconstruction to obtain an image actual contour; S5, the image actual contour Cr is compared with a contour of a corresponding
slicing layer to analyze the accuracy, if the requirements are met, the step S6 is executed, and otherwise,
machining is completed; and S6, whether
machining of the to-be-machined part is completed or not is detected. According to the on-line detectionmethod of the contour accuracy of the molding layer in the
laser selective melting process, the range of
image contour extraction can be effectively and accurately delimited, and then the number of iteration times in the calculation process is greatly decreased; and thus the extraction accuracy of the
image contour reaches the sub-pixel level, and accurate and rapid contour detection is realized.