• 中国期刊全文数据库
  • 中国学术期刊综合评价数据库
  • 中国科技论文与引文数据库
  • 中国核心期刊(遴选)数据库
刘望龙, 陈元枝, 王梓豪, 等. 基于ZXing的彩色QR码自适应识读与定位方法[J]. 桂林电子科技大学学报, 2025, 45(1): 49-53. DOI: 10.16725/j.1673-808X.2022324
引用本文: 刘望龙, 陈元枝, 王梓豪, 等. 基于ZXing的彩色QR码自适应识读与定位方法[J]. 桂林电子科技大学学报, 2025, 45(1): 49-53. DOI: 10.16725/j.1673-808X.2022324
LIU Wanglong, CHEN Yuanzhi, WANG Zihao, et al. Adaptive reading and locating method of color QR code based on ZXing[J]. Journal of Guilin University of Electronic Technology, 2025, 45(1): 49-53. DOI: 10.16725/j.1673-808X.2022324
Citation: LIU Wanglong, CHEN Yuanzhi, WANG Zihao, et al. Adaptive reading and locating method of color QR code based on ZXing[J]. Journal of Guilin University of Electronic Technology, 2025, 45(1): 49-53. DOI: 10.16725/j.1673-808X.2022324

基于ZXing的彩色QR码自适应识读与定位方法

Adaptive reading and locating method of color QR code based on ZXing

  • 摘要: 针对基于ZXing设计的彩色QR码中无法识别任意分辨率图片的问题,设计了一种彩色QR码的自适应识读与定位方法。该方法参考了黑白QR码的二值化过程,根据彩色QR码2k值化亮度矩阵与位矩阵之间的映射关系,建立了自适应识读与定位的公式,主要与位矩阵的大小、k值有关,根据偏移位置公式编写相关算法,实现了彩色QR码的自适应识读与定位功能。因算法中需要多次遍历图像数据,所以解码速度主要取决于图片分辨率的大小,也即像素的数量。通过分析3种分辨率下的4色与16色彩色QR码图片数据,验证了该方法的可行性。

     

    Abstract: Aiming at the problem that the color QR code designed based on ZXing could not recognize pictures with arbitrary resolution, an adaptive reading and positioning method for color QR code was designed. which referred to the binary process of black and white QR code, According to the mapping relationship between the 2k value luminance matrix and the bit matrix of color QR code, the formula of adaptive reading and positioning was established, which was mainly related to the size and k value of the bit matrix. Then according to the formula, the relevant algorithm was compiled to realize the adaptive reading and positioning function of color QR code. Traversing the image data multiple times was needed in the algorithm, so the decoding speed was determined by the size of the image resolution, which was represented by the number of pixels. The feasibility of this method is verified by analyzing the 4-color and 16-color QR code image data under three resolutions.

     

/

返回文章
返回