find_data_code_2d 一次性识别图片中的多个二维码

read_image (Image2134020847, 'F:/2-13-40-20-847.jpg')
gen_rectangle1 (ROI_0, 709.694, 548.556, 1283.63, 1649.7)
reduce_domain(Image2134020847, ROI_0, ImageReduced)
crop_domain(ImageReduced, ImagePart)
rgb1_to_gray(ImagePart, GrayImage)




create_data_code_2d_model('QR Code', [], [], DataCodeHandle)


set_data_code_2d_param(DataCodeHandle, 'polarity', 'dark_on_light')
set_data_code_2d_param(DataCodeHandle, ['module_size_min', 'module_size_max'], [1, 100])
set_data_code_2d_param(DataCodeHandle, 'contrast_min', 10)
set_data_code_2d_param(DataCodeHandle, 'module_gap','no')
 
find_data_code_2d(GrayImage, SymbolXLDs, DataCodeHandle, 'stop_after_result_num', 2, ResultHandles, DecodedDataStrings)

猜你喜欢

转载自blog.csdn.net/lingtianyulong/article/details/78255046