Today, making quality control systems with reliable accuracy is very important in producing industrial products with zero defects. In this respect, it is an essential issue that camera control systems work with reliable control algorithms. In this study, a real-time control algorithm using a pattern matching algorithm has been developed to optimize the minimum contrast parameter with an Artificial Neural Network (ANN). In the study, the comparison of three algorithms included in pattern matching in terms of time was made using LabVIEW image control tools. Besides, one of the most critical parameters in the low-discrepancy sampling algorithm, which gives good results in time, minimum contrast parameter is discussed. The optimization of this parameter is done by using the Levenberg-Marquardt training algorithm in ANN. The obtained results show that the proposed pattern matching algorithm using ANN for optimizing the minimum contrast parameter is fast and effective for quality control applications.