Fusion deposition modeling (FDM) is currently the most promising 3D printing process. However, due to inappropriate process parameters and motion errors, defects may occur during the forming process of FDM 3D printing, affecting the quality of the formed parts. Therefore, it is of great significance to accurately detect defects that may occur during the layered stacking process of FDM technology. We propose an FDM 3D printing defect online detection method based on machine vision, aiming to accurately detect possible defects in 3D printing. In this study, a machine vision hardware platform was constructed using a monocular camera as an image sensor and a nozzle path adjustment method was adopted to effectively avoid nozzle obstruction. On this basis, the obtained 3D printing process images were preprocessed, and a new layer on the top of the 3D printing part was extracted using a clustering segmentation algorithm. Gabor wavelet transform was used to detect wire drawing defects in the layer area, and the results verified the feasibility of the method.