WO2012149778A1 - Multilayer quick response code image encoding/decoding method and encoding/decoding device - Google Patents

Multilayer quick response code image encoding/decoding method and encoding/decoding device Download PDF

Info

Publication number
WO2012149778A1
WO2012149778A1 PCT/CN2011/080306 CN2011080306W WO2012149778A1 WO 2012149778 A1 WO2012149778 A1 WO 2012149778A1 CN 2011080306 W CN2011080306 W CN 2011080306W WO 2012149778 A1 WO2012149778 A1 WO 2012149778A1
Authority
WO
WIPO (PCT)
Prior art keywords
layer
code
image
fast response
component
Prior art date
Application number
PCT/CN2011/080306
Other languages
French (fr)
Chinese (zh)
Inventor
袁健
Original Assignee
华为技术有限公司
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by 华为技术有限公司 filed Critical 华为技术有限公司
Priority to CN201180003663.3A priority Critical patent/CN102741864B/en
Priority to PCT/CN2011/080306 priority patent/WO2012149778A1/en
Publication of WO2012149778A1 publication Critical patent/WO2012149778A1/en

Links

Classifications

    • GPHYSICS
    • G09EDUCATION; CRYPTOGRAPHY; DISPLAY; ADVERTISING; SEALS
    • G09CCIPHERING OR DECIPHERING APPARATUS FOR CRYPTOGRAPHIC OR OTHER PURPOSES INVOLVING THE NEED FOR SECRECY
    • G09C5/00Ciphering apparatus or methods not provided for in the preceding groups, e.g. involving the concealment or deformation of graphic data such as designs, written or printed messages
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06KGRAPHICAL DATA READING; PRESENTATION OF DATA; RECORD CARRIERS; HANDLING RECORD CARRIERS
    • G06K19/00Record carriers for use with machines and with at least a part designed to carry digital markings
    • G06K19/06Record carriers for use with machines and with at least a part designed to carry digital markings characterised by the kind of the digital marking, e.g. shape, nature, code
    • G06K19/06009Record carriers for use with machines and with at least a part designed to carry digital markings characterised by the kind of the digital marking, e.g. shape, nature, code with optically detectable marking
    • G06K19/06046Constructional details
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L9/00Cryptographic mechanisms or cryptographic arrangements for secret or secure communications; Network security protocols

Definitions

  • the present invention relates to the field of image processing, and in particular, to a multi-layer fast response code encoding and decoding method and a coding and decoding apparatus.
  • QR Quick Response
  • the Quick Response (QR) code is a 2D barcode that was developed in 1994 by Denso-Wave, Japan.
  • the current QR code is square, only black and white.
  • three small square patterns resembling the Chinese character "back” are printed.
  • the squares of the three "back” glyphs help to identify the angle at which the QR code is tilted when the QR code is resolved. Therefore, the user of the QR code does not need to be aligned when scanning the QR code, that is, the data can be read correctly regardless of scanning at any angle.
  • QR code can store more data than the ordinary barcode, and the recognition is faster than the ordinary barcode.
  • the QR code is called the "quick response" code.
  • Prior Art QR codes are obtained by some algorithm according to their own existing coding rules.
  • an image encoded using a QR code always has a limited amount of information.
  • a QR code image if the number is a number, contains up to 7059 characters; if it is a letter, it can contain up to 4296 characters; if it is a binary number, it can contain up to 2953 bytes.
  • the QR code version cannot be increased indefinitely. In other words, when the QR code is increased to the highest version, the information capacity contained in the QR code is also increased to the maximum and will not continue to increase.
  • Embodiments of the present invention provide a multi-layer fast response code encoding and decoding method, and an encoding and decoding apparatus to improve information capacity included in a QR code.
  • An embodiment of the present invention provides a multi-layer fast response code encoding method, where the method includes: acquiring an image layer of a multi-layer fast response QR code, the multi-layer fast response QR code is original Multi-layer fast response QR code obtained by fast response QR code encoding;
  • the original fast response QR code image layers are superimposed in a predetermined color order using the acquired N sets of color coefficient feature values to obtain the multi-layer fast response QR code image.
  • An embodiment of the present invention provides a multi-layer fast response code decoding method, where the method includes: parsing a multi-layer fast response QR code image to obtain pixel RGB components of each layer of the multi-layer fast response QR code image, The number of image layers of the multi-layer fast response QR code is N, and the multi-layer fast response QR code image is obtained by acquiring N sets of color feature values from the bidirectional reversible color coefficient feature library and then performing the image layer of the original fast response QR code in color order.
  • superimposing a multi-layer fast response QR code image drawing a single-layer fast response QR code image from pixel RGB components of each layer of the multi-layer QR code image;
  • the information content parsed from each of the single layer quick response QR code images is connected in the color sequence.
  • An embodiment of the present invention provides a multi-layer fast response code encoding apparatus, where the apparatus includes: an image layer number obtaining module, configured to acquire a number of image layers N of a multi-layer fast response QR code, and the multi-layer fast response QR code is a multi-layer fast response QR code obtained by encoding the original fast response QR code;
  • a color feature value obtaining module configured to acquire N sets of color feature values from the bidirectional reversible color coefficient feature library, wherein the color coefficient feature values are used to change color parameters of the original fast response QR code image layer;
  • the acquired N sets of color coefficient feature values superimpose the image layers of the original quick response QR code in color order to obtain the multi-layer fast response QR code image.
  • An embodiment of the present invention provides a multi-layer fast response code decoding apparatus, where the apparatus includes: a pixel component parsing module, configured to parse a multi-layer fast response QR code image to obtain each layer of the multi-layer fast response QR code image.
  • the multi-layer fast response QR code image is a multi-layer fast response QR obtained by superimposing the image layers of the original fast response QR code in color order after acquiring N sets of color coefficient feature values from the bidirectional reversible color feature library.
  • An image drawing module configured to draw a single layer quick response QR code image by pixel RGB components of each layer image of the multi-layer fast response QR code image
  • An image processing module configured to process the single layer quick response QR code image to parse the information content included in the single layer fast response QR code image
  • connection module configured to connect the information content parsed from each single layer quick response QR code image according to the color sequence.
  • the color coefficient feature value equal to the number of image layers N of the multi-layer fast response QR code can be obtained from the bidirectional reversible color feature library, and the original QR code image layer is used in color order.
  • the multi-layer QR code image is obtained, by which the information capacity contained in the original QR code image is expanded. Therefore, on the one hand, multi-layer QR code images can satisfy the transmission of large amounts of information, thereby improving transmission efficiency.
  • multiple encryption of files can be performed, which increases the security of file transmission.
  • FIG. 1 is a schematic flowchart of a multi-layer fast response code encoding method according to an embodiment of the present invention
  • FIG. 2 is a schematic flowchart of a multi-layer fast response code decoding method according to an embodiment of the present invention
  • Schematic diagram of a layer fast response code encoding device 4 is a schematic structural diagram of a multi-layer fast response code encoding apparatus according to another embodiment of the present invention
  • FIG. 5 is a schematic structural diagram of a multi-layer fast response code encoding apparatus according to another embodiment of the present invention
  • FIG. 7 is a schematic structural diagram of a multi-layer fast response code decoding apparatus according to another embodiment of the present invention
  • FIG. 8 is a multi-layer fast response code decoding apparatus according to another embodiment of the present invention
  • Embodiments of the present invention provide a multi-layer fast response code encoding, decoding method, and encoding and decoding apparatus to improve information capacity included in a QR code.
  • FIG. 1 is a schematic flowchart of a multi-layer fast response code encoding method according to an embodiment of the present invention, which mainly includes the following steps:
  • the multi-layer QR code is a multi-layer QR code obtained by encoding the original fast response QR code
  • the image layer number N is related to the user requirement, for example, the security of the encrypted file
  • the information capacity of the multi-layer QR code or the size of the information amount transmission is related.
  • the stricter the user's needs for example, the higher the security of the file or the larger the information capacity of the multi-layer QR code, the larger the number of image layers N of the multi-layer QR code should be.
  • the levy inventory stores color coefficient feature values for changing the color parameters of the image layer of the original QR code.
  • the color parameter of the original QR code image layer can be the original QR code image.
  • the RGB components of the image pixels in the layer that is, red (Red, R), green (Green, G), and blue (Blue, B) in the three primary colors (R, G, B) of the image.
  • bidirectional reversible color feature library it is called "bidirectional reversible color feature library" because the bidirectional reversible color feature library provided by the embodiment of the present invention can be used to calculate the pixel RGB component of the multi-layer QR code image when encoding the original QR code, and can be used in The number of image layers included in the multi-layer QR code image is calculated when decoding the multi-layer QR code. The image layers are superimposed in color order to obtain the multi-layer QR code image.
  • an original QR code image contains information capacity represented by num QR
  • the capacity is approximately N x num QR . It can be seen that the information capacity of the multi-layer QR code image obtained after encoding is N times the information capacity of the original QR code image, and the expansion of the information capacity means that the file can be multi-encrypted. , increase the security of file transfer.
  • the "color order" may be agreed with the decoding end before encoding at the encoding end.
  • the color order agreed upon before encoding is that the first layer is red, the second layer is yellow, and the third layer is It is purple.
  • the decoding end connects the decoded information contents in this color order during decoding, and restores the original information contained in the multi-layer QR code.
  • the multi-layer fast response code encoding method since the color coefficient characteristic value equal to the image layer number N of the multi-layer fast response QR code can be obtained from the bidirectional reversible color feature library, The original QR code image layers are superimposed in color order to obtain the multi-layer QR code image, by which the information capacity of the original QR code image is expanded. Therefore, on the one hand, the multi-layer QR code image can satisfy the transmission of a large amount of information, thereby improving the transmission efficiency. On the other hand, the file can be multi-encrypted, which increases the security of file transmission.
  • the user Before designing a multi-layer QR code, the user can know the total information capacity that the multi-layer QR code should contain, and the maximum information capacity of each layer of the multi-layer fast response QR code also has an approximation. Therefore, in one embodiment of the present invention, for the number of image layers N of the multi-layer fast response QR code, the total information capacity of the multi-layer QR code and the maximum information capacity of each layer of the multi-layer QR code may be Divide to obtain, that is, if the two can be divisible, the quotient obtained by dividing the two directly is regarded as the image layer number N of the multi-layer QR code; if the two cannot be divisible, the quotient of dividing the two is obtained The value obtained by rounding up is used as the image layer of the multi-layer fast response QR code, for example, the total information capacity of the multi-layer QR code is divided by the maximum information capacity of each layer image in the multi-layer QR code. 3.2, then the 4 obtained by rounding up 3.2 is used as the image layer number of the multi-
  • each set of color coefficient feature values obtained from the bidirectional reversible color feature library includes a color coefficient feature component a k , a color coefficient feature component b k , and a color coefficient feature component c k , that is, each set of colors
  • the eigenvalues are represented by a k , b k , ).
  • the color coefficient feature component a k , the color coefficient feature component b k , and the color coefficient feature component c k included in each set of color coefficient feature values may be used as feature coefficients, and each layer image in the image layer of the original QR code is
  • the pixel RGB components are correspondingly superimposed to obtain a pixel RGB component of the multi-layer QR code, that is, a pixel value, wherein, for a white pixel block in the original QR code image, white or a predetermined color is used for calibration; and then, according to the multi-layer QR
  • the pixel RGB component of the code plots the multi-layer QR code image.
  • the image layer (consisting of the pixels of the calculated multi-layer QR code) is superimposed in color order (the color order can be agreed in advance).
  • the calculated multi-layer QR code one of which is yellow (the RGB component of the pixel is denoted as (Rl, Gl, B1)), and the other image layer is orange (the RGB component of the pixel is denoted as (R2, G2, B2)),
  • the RGB component of the pixel is denoted as (R2, G2, B2)
  • There is also an image layer that is purple (the RGB components of its pixels are recorded as (R3, G3, B3)). If the agreed color order is yellow, orange, and purple, first draw the first image layer of the multi-layer QR code with the pixel (R1, Gl, B1), and superimpose it on the first image layer composed of yellow.
  • the orange color of the pixel (R2, G2, B2) constitutes the second image layer of the multi-layer QR code, in yellow
  • the superimposed pixels are purple of (R3, G3, B3), thereby forming a three-layer QR code image.
  • the multi-layer QR code image obtained by this method can increase N-fold according to the acquired N-group color feature values during information transmission, and the image size of the multi-layer QR code does not increase much.
  • files of different formats can be stored in the multi-layer QR code image by reading their binary code in the computer.
  • each set of color coefficient feature values ( ⁇ , b k , ) obtained from the bidirectional reversible color feature library is unique, the color coefficient characteristics of each group are described.
  • the values a k , b k , c k ) as the feature coefficients the pixel RGB components of the multi-layer QR code obtained by superimposing the pixel RGB components of each layer image in the image layer of the original QR code are also unique, thus, according to the multi-layer
  • the multi-layer QR code image drawn by the pixel RGB component of the QR code is also unique.
  • the color coefficient feature component 3 ⁇ 4, the color coefficient feature component, and the color coefficient feature component included in each set of color coefficient feature values are used as feature coefficients, and pixels of each layer image in the image layer of the original QR code are used.
  • the RGB components corresponding to the superposition to obtain the pixel RGB components of the multi-layer QR code can be realized by the following steps:
  • Step S1 the color coefficient feature component a k , the color coefficient feature component b k , and the color coefficient feature component c k included in each set of color coefficient feature values and the pixel of each layer image in the image layer of the original QR code
  • the R component and the G component of the RGB component are respectively multiplied by the B component;
  • the obtained product is denoted as b k y k and .
  • the R component, the G component ⁇ and the B component of the pixel RGB component of each layer image in the image layer of the original QR code are respectively red (Red, R) in the three primary colors (R, G, B) of the general image. , Green (G) and Blue (Blue, B) have the same meaning.
  • the RGB component may be the RGB component of the pixel constituting the white color, or the RGB component of the pixel of the other color of the convention, which may not be limited in the embodiment of the present invention.
  • the three sets of color coefficient eigenvalues are obtained from the bidirectional reversible color feature library as (A, b x , ), ( a 2 , b 2 , c 2 ) and ( ⁇ 3 , b 3 , c 3 ), if the original QR
  • the image layer of the code is two layers, and the R component, the G component ⁇ and the B component of the pixel RGB component are respectively recorded as j x , and ( , y 2 , z 2 ), and the R of the image layer of the original QR code is less.
  • the component, the G component ⁇ , and the B component 3 ⁇ 4 that is, 3 , y 3 , ), can be regarded as (0, 0, 0).
  • Step S2 the color coefficient feature component, the color coefficient feature component bk, and the color coefficient feature component ck included in each set of color coefficient feature values and the pixel RGB component of each layer image in the image layer of the original QR code
  • the product of the R component, the G component ⁇ , and the B component respectively multiplied, b k y k
  • the R component of the pixel RGB component of the obtained multi-layer QR code is ⁇ ⁇ jj-i- z 1
  • the G component is ⁇ 3 ⁇ 4 + b 2 y 2 + c 2
  • the B component is ⁇ 3 ⁇ 4 + b 3 y 3 + c 3
  • the R component, the G component ⁇ and the B component of the pixel RGB component are respectively recorded as ( ⁇ 3 ⁇ 4, j x , ) and ( , y 2 , z 2 )
  • the R component of the pixel RGB component of the obtained multi-layer QR code is + y 1 + Cl ⁇
  • the G component is a 2 x 2 + b 2 y 2 + c 2 z 2
  • the original QR code image consists of two colors, black and white. These two colors represent pixels containing information and no information. The information is encoded as 1 and 0 respectively.
  • the original QR code image pixels are drawn in two colors on the image; further, the colors on the single layer QR code image are replaced with two other colors. Since each layer of QR image contains 0, that is, a pixel that does not contain information, this color can be defined as M, and the pixel value is taken as M (50, 50, 50).
  • each layer is a single layer QR code image.
  • the color containing the information is defined as A (180, 0, 0); in the second layer QR code image, the color containing the information is defined as B (0, 180, 0); In the layer QR code image, the color containing the information is defined as C (0, 0, 150).
  • the single-layer image includes only A and M or B and M, and the image is binarized, which is the original QR code image).
  • A+B that is, the pixel points contain information in both layers of images, and after the image is superimposed, the pixel value of the pixel is (180, 180, 0);
  • A+M that is, the pixel contains information in the first layer image, and the second layer image does not contain information, and the pixel value of the pixel after the superposition is (210, 30, 30); 3.
  • M+B that is, the pixel does not contain information in the first layer image, and the second layer image contains information. After the image is superimposed, the pixel value of the pixel is (30, 210, 30);
  • M+M that is, the pixel contains information in both layers of images. After the image is superimposed, the pixel value of the pixel is (60, 60, 60).
  • A+B+C that is, the pixel points contain information in the three-layer image. After the image is superimposed, the pixel value of the pixel is (180, 180, 180);
  • A+B+M that is, the pixel contains information in the first and second layer images, and the third layer image does not contain information. After the image is superimposed, the pixel value of the pixel is pixel value (210, 210, 30);
  • A+M+C that is, the pixel points contain information in the first and third layer images, and the second layer image does not contain information.
  • the pixel value of the pixel is the pixel value (210, 30, 210);
  • A+M+M that is, the pixel contains information in the first layer image, and the second and third layer images do not contain information. After the image is superimposed, the pixel value of the pixel is (240, 60, 60);
  • M+B+C that is, the pixel does not contain information in the first layer image, and the second and third layer images all contain information.
  • the pixel value of the pixel is (30). 210, 210);
  • M+M+C that is, the pixel does not contain information in the first and second layer images, and the third layer image contains information. After the image is superimposed, the pixel value of the pixel is the pixel value (60, 60). , 210);
  • M+M+M that is, the pixel does not contain information in the first, second, and third layers of images, and after the image is superimposed, the pixel value of the pixel is (90, 90, 90);
  • pixel extraction may be performed on each pixel of the multi-layer QR code image.
  • the pixel RGB component of the obtained pixel is used as the image of each layer of the multi-layer QR code image.
  • the pixel RGB component of the pixel Since each layer of the multi-layer QR code image has a detection pattern, for example, a "back" font, the area of the detection pattern is covered by each layer image, and the pixel containing the information also contains the information of each layer image.
  • the color overlay Therefore, in the embodiment, the detection pattern may be a sampling point of each layer image in the multi-layer QR code image,
  • the sampling point is sampled; further, the R component of the RGB component of the pixel according to the multi-layer QR code is
  • the G component is ⁇ b k y k
  • the number of layers in the layer is the number of layers in the layer.
  • the colors containing information according to the foregoing embodiment are A (180, 0, 0) and B (0, 180).
  • the assumption of 0 it can be inferred that the image is obtained by the first mixing method of the two layers of image superposition, that is, by the first layer image (the color containing the information is defined as A (180, 0, 0)) Superimposed with the second layer image (which contains the color of the information defined as B (0, 180, 0)), the number of layers of the multi-layer QR code image is 2 layers.
  • the color containing information according to the foregoing embodiment is A (180, 0, 0), B (0, 180, 0).
  • the image is the first hybrid of the three-layer image overlay Yes, that is, by the first layer image (which contains the color of the information defined as A ( 180, 0, 0)), the second layer image (which contains the color of the information defined as B (0, 180, 0)) and The three-layer image (which contains the color of the information defined as C (0, 0, 180)) is superimposed, so the number of layers of the multi-layer QR code image is three.
  • the pixel RGB components of each layer of the image parsed from the multi-layer QR code image are stored in a memory array for drawing a single layer QR code image.
  • a convention color may be used instead, and the agreed color is included in each of the drawn single-layer QR code images.
  • This process includes the steps:
  • S2031 performing binarization, denoising, and morphological algorithm processing on the single layer fast response QR code image to obtain a binarized image
  • the white pixel block of the binarized image (the pixel block not containing the information content or the codeword not included) is calibrated in white or a predetermined color.
  • performing QR code identification on the binarized image including searching for a detection pattern, a version information, a positioning pattern, a correction pattern, and a mask removal information;
  • the content includes only text information, write it to the text tool; if the information contains the format and file name of the original file, write it to the hard disk in the original file format.
  • S204 Connect the information content parsed from each single layer quick response QR code image according to the color sequence.
  • the calculated multi-layer QR code One of the image layers is yellow (the RGB component of the pixel is denoted as (Rl, Gl, B1)), and the other image layer is orange (the RGB component of the pixel is denoted as (R2, G2, B2)), and one The image layer is purple (the RGB components of the pixel are recorded as (R3, G3, B3)). If the agreed color order is yellow, orange, and purple, the yellow color of the (Rl, Gl, B1) pixel is first formed to form a multi-layer.
  • the first image layer of the QR code on the first image layer composed of yellow, the orange image of the (R2, G2, B2) superimposed pixel forms the second image layer of the multi-layer QR code, which is composed of yellow and orange.
  • the purple color of the superimposed pixels (R3, G3, B3) constitutes a three-layer QR code image.
  • the multi-layer QR code obtained after encoding contains the information content from 1 to 3000, and further assumes that the first image layer composed of yellow contains the content from 1 to 1000, orange
  • the second image layer is composed of numbers from 1001 to 2000, and the third image layer composed of purple contains numbers from 2001 to 3000, in order to ensure the information content parsed from the multilayer QR code.
  • the information content of each image layer is connected in the order of the first image layer, the second image layer, and the third image layer, and restored to the original information content.
  • the multi-layer fast response QR code image is parsed to obtain the information content contained in the single-layer QR code image, and the text information parsed from each single-layer QR code image is obtained.
  • the connections are made in the agreed color order. Since the multi-layer QR code image is obtained by acquiring at least one set of color coefficient feature values equal to the number of image layers of the multi-layer QR code image from the bidirectional reversible color feature library, the image layer of the original QR code is as agreed The QR code image obtained by superimposing the color order, therefore, the multi-layer QR code image satisfies the transmission of a large amount of information, thereby improving the transmission efficiency, and on the other hand, increases the security of file transmission.
  • FIG. 3 it is a schematic structural diagram of a multi-layer fast response code encoding apparatus according to an embodiment of the present invention. For the convenience of description, only parts related to the embodiment of the present invention are shown.
  • the multi-layered fast response code encoding apparatus 03 illustrated in FIG. 3 includes an image layer number obtaining module 301, a color feature value obtaining module 302, and a superimposing module 303, wherein:
  • the image layer number obtaining module 301 is configured to obtain an image layer of the multi-layer fast response QR code.
  • the multi-layer fast response QR code is a multi-layer fast response QR code obtained by encoding the original fast response QR code;
  • the original QR code is a single-layer QR code, that is, the QR code image has only one layer
  • the multi-layer QR code is a QR code obtained by encoding the original QR code, and the number of image layers N and user requirements.
  • the information capacity of the multi-layer QR code or the size of the information volume transmission.
  • the stricter the user requirements such as the higher the security of the file or the larger the information capacity of the multi-layer QR code, the larger the image layer 3 ⁇ 4N of the multi-layer QR code.
  • the color feature value obtaining module 302 is configured to obtain N sets of color coefficient feature values from the bidirectional reversible color feature library, where the color coefficient feature values are used to change color parameters of the original fast response QR code image layer;
  • the bidirectional reversible color feature library described in this embodiment can be established in advance.
  • the two-way reversible color feature library stores color coefficient feature values that are used to change the color parameters of the image layer of the original QR code.
  • the color parameter of the original QR code image layer may be the RGB component of the image pixel in the original QR code image layer, that is, red (Red, R), green (Green) in the three primary colors (R, G, B) of the image. G) and blue (Blue, B).
  • bidirectional reversible color feature library It is called "bidirectional reversible color feature library" because the bidirectional reversible color feature library provided by the embodiment of the present invention can be used to calculate the pixel RGB component of the multi-layer QR code image when encoding the original QR code, and can be used in The number of image layers included in the multi-layer QR code image is calculated when decoding the multi-layer QR code. The image layers are superimposed in color order to obtain the multi-layer fast response QR code image.
  • an original QR code image contains an information capacity represented by num QR
  • the "color order" may be agreed by the multi-layer fast response code encoding device with the multi-layer fast response code decoding device before encoding, for example, the color order agreed upon before encoding is that the first layer is red. The second layer is yellow and the third layer is purple.
  • the multi-layer fast response code decoding device connects the decoded information contents in this color order during decoding, and restores the original information contained in the multi-layer QR code.
  • the color feature value acquiring module can obtain the color coefficient feature of the number of groups and the image layer number N of the multi-layer fast response QR code from the bidirectional reversible color feature library.
  • the value superimposing module superimposes the original QR code image layer in color order to obtain the multi-layer QR code image, which enlarges the information capacity contained in the original QR code image. Therefore, the multi-layer QR code image obtained by the multi-layer fast response code encoding apparatus provided by the embodiment of the present invention can satisfy the transmission of a large amount of information on the one hand, thereby improving the transmission efficiency, and on the other hand, can encrypt the file multiple times, and increase the number of files. File transfer security.
  • each functional module is merely an example, and the actual application may be considered according to requirements, such as configuration requirements of corresponding hardware or convenience of implementation of software.
  • the above function assignment is completed by different functional modules, that is, the internal structure of the multi-layer fast response code encoding device is divided into different functional modules to complete the above description. All or part of the functions described.
  • the corresponding functional modules in this embodiment may be implemented by corresponding hardware, or may be executed by corresponding hardware.
  • the foregoing image layer number obtaining module may have the foregoing implementation.
  • the hardware for obtaining the image layer number N of the multi-layer fast response QR code may also be a general processor or other hardware device capable of executing a corresponding computer program to perform the foregoing functions; It may be hardware having a function of performing the foregoing use of the N sets of color coefficient feature values to superimpose the image layers of the original QR code in a color order to obtain the function of the multi-layer QR code image, such as an overlay, or A general processor or other hardware device capable of executing a corresponding computer program to perform the aforementioned functions (the various embodiments described herein may apply the above described principles).
  • the image layer number obtaining module 301 illustrated in FIG. 3 may be specifically configured to divide the total information capacity of the multi-layer fast response QR code by the maximum information capacity of each layer image in the multi-layer fast response QR code.
  • the quotient obtained by dividing the two directly is used as the image layer number N of the multi-layer fast response QR code; if the two cannot be divisible, the quotient of dividing the two is obtained Rounding up the obtained value as the number of image layers N of the multi-layer fast response QR code, for example, dividing the total information capacity of the multi-layer QR code by the maximum information capacity of each layer image in the multi-layer QR code
  • the quotient is 3.2, and the 4 obtained by rounding up 3.2 is used as the image layer number of the multi-layer fast response QR code.
  • each set of color feature values includes a color coefficient feature component, a color coefficient feature component, and a color coefficient feature component.
  • the superimposing module 301 of the example of FIG. 3 may further include a pixel component superposition sub-module 401 and an image layer superposition sub-module 402, as shown in FIG.
  • a multi-layer fast response code encoding apparatus 04 according to another embodiment of the present invention, wherein: a pixel component superposition sub-module 401, configured to use the color coefficient feature component a k , the color coefficient feature component b k , and the color coefficient feature component c k included in each set of color feature values as a feature coefficient, Pixel RGB components of each layer image in the image layer of the original QR code are correspondingly superimposed to obtain pixel RGB components of the multi-layer QR code;
  • the image layer superposition sub-module 402 is configured to superimpose the image layer in color order according to the pixel RGB component of the multi-layer QR code to draw the multi-layer QR code image.
  • each set of color feature values is represented using ( a k , b k , ).
  • the color coefficient feature component 3 ⁇ 4, the color coefficient feature component b k, and the color coefficient feature component c k included in each set of color feature values may be used as feature coefficients, and the pixels of each layer image in the image layer of the original QR code may be used.
  • the RGB components are correspondingly superimposed to obtain pixel RGB components of the multi-layer QR code, that is, pixel values, wherein, for white pixel blocks in the original QR code image, white or agreed color calibration is used; then, the image layer overlay sub-module 402 renders the multi-layer QR code image according to pixel RGB components of the multi-layer QR code.
  • the image layer is superimposed in color order.
  • the calculated multi-layer QR code one of which is yellow (the RGB component of the pixel is denoted as (Rl, Gl, B1)), and the other image layer is orange (the RGB component of the pixel is denoted as (R2, G2, B2)), and another image layer is purple (the RGB components of the pixels are recorded as (R3, G3, B3)). If the color order is yellow, orange, and purple, the image layer overlay sub-module 402 is drawn first.
  • the yellow color of the pixel (Rl, Gl, B1) constitutes the first image layer of the multi-layer QR code, and on the first image layer composed of yellow, the orange layer of the (R2, G2, B2) superimposed pixel constitutes a multi-layer QR
  • the pixel component superposition sub-module 401 of the example of FIG. 4 may further include an integration unit 501 and a summation unit 502, such as the multi-layer fast response code encoding apparatus 05 provided by another embodiment of the present invention, as shown in FIG.
  • the quadrature unit 501 is configured to: each of the color coefficient feature components a k , the color coefficient feature component, and the color coefficient feature component included in each set of color feature values and each of the image layers of the original QR code
  • the R component, the G component ⁇ and the B component of the pixel RGB component of the layer image are respectively multiplied, and the obtained products are respectively denoted as ⁇ , b k y k and c k z k , that is, multiplied by , multiplied by ⁇ , and Multiply, the resulting products are recorded as 3 ⁇ 4, y k, and c A , respectively .
  • the R component, the G component ⁇ , and the B component of the pixel RGB component of each layer image in the image layer of the original QR code are respectively red (Red, R) among the three primary colors (R, G, B) of the general image. , Green (G) and Blue (Blue, B) have the same meaning.
  • the RGB component may be the RGB component of the pixel constituting the white color, and may be the RGB component of the pixel of the other color of the agreement, which may not be limited in the embodiment of the present invention.
  • the R component of the pixel layer RGB component of the image layer of the original QR code is reduced.
  • the G component ⁇ and the B component are regarded as 0.
  • obtaining three sets of color coefficient eigenvalues from the bidirectional reversible color feature library are denoted as (A, b x , c x ), ( a 2 , b 2 , c 2 ) and ( ⁇ 3 , b 3 , c 3 ), if
  • the image layer of the original QR code is two layers, and the R component, the G component ⁇ , and the B component 3 ⁇ 4 of the pixel RGB component are respectively recorded as J x , ) and ( , y 2 , ), and then an image layer having less original QR code.
  • the R component, the G component ⁇ , and the B component, that is, ( , y 3 , ) can be regarded as (0, 0, 0).
  • a summation unit 502 configured to: the color coefficient feature component a k , the color coefficient feature component, and the color coefficient feature component included in each set of color feature values and the pixel RGB component of each layer image in the image layer of the original QR code The product of the R component, the G component ⁇ , and the B component respectively multiplied
  • FIG. 6 is a schematic structural diagram of a multi-layer fast response code decoding apparatus according to an embodiment of the present invention. For the convenience of description, only parts related to the embodiment of the present invention are shown.
  • the multi-layer fast response code decoding device 06 illustrated in Fig. 6 includes a pixel component analysis module 601, an image rendering module 602, an image processing module 603, and a connection module 604, wherein:
  • a pixel component parsing module 601 configured to parse a multi-layer fast response QR code image to obtain a pixel RGB component of each layer image of the multi-layer QR code image, where the number of image layers of the multi-layer fast response QR code is N,
  • the multi-layer QR code image is a multi-layer fast response QR code image obtained by acquiring N sets of color feature values from the bidirectional reversible color feature library and superimposing the image layers of the original quick response QR code in accordance with a predetermined color sequence;
  • An image drawing module 602 configured to draw a single-layer QR code image by pixel RGB components of each layer image of the multi-layer fast response QR code image, that is, each layer image that is parsed from the multi-layer QR code image
  • the pixel RGB components are stored in a memory array for drawing a single layer QR code image.
  • a convention color may be used instead, and the agreed color is included in each of the single-layer QR code images drawn;
  • the image processing module 603 is configured to process the single layer quick response QR code image to parse the information content included in the single layer fast response QR code image;
  • the connection module 604 is configured to connect the information content parsed from each single-layer quick response QR code image according to the agreed color order. As illustrated in the example of FIG. 1, since the image layer (composed of the calculated multi-layer QR code) is superimposed in the agreed color order when drawing the multi-layer QR code image, for example, the calculated multi-layer QR code One of the image layers is yellow (the RGB component of the pixel is denoted as (Rl, Gl, B1)), and the other image layer is orange (the RGB component of the pixel is denoted as (R2, G2, B2)), and one The image layer is purple (the RGB components of the pixel are recorded as (R3, G3, B3)).
  • the yellow color of the (Rl, Gl, B1) pixel is first formed to form a multi-layer.
  • the first image layer of the QR code, on the first image layer composed of yellow, the orange image of the (R2, G2, B2) superimposed pixel constitutes the second image layer of the multi-layer QR code, which is composed of yellow and orange.
  • the purple color of the superimposed pixels (R3, G3, B3) constitutes a three-layer QR code image.
  • the multi-layer QR code obtained after encoding contains the information content from 1 to 3000, and further assumes that the first image layer composed of yellow contains the content from 1 to 1000, orange
  • the second image layer is composed of numbers from 1001 to 2000
  • the third image layer composed of purple contains numbers from 2001 to 3000, in order to ensure the information content parsed from the multilayer QR code.
  • the connection module 604 connects the information contents of the image layers in the order of the first image layer, the second image layer, and the third image layer, and restores the original information content.
  • each functional module is merely an example, and the actual application may be considered according to requirements, such as configuration requirements of corresponding hardware or convenience of implementation of software.
  • the above function assignment is performed by different functional modules, that is, the internal structure of the multi-layer fast response code decoding device is divided into different functional modules to complete all or part of the functions described above.
  • the corresponding functional modules in this embodiment may be implemented by corresponding hardware, or may be executed by corresponding hardware.
  • the foregoing pixel component parsing module may have the foregoing parsing.
  • a multi-layer fast response QR code image to obtain hardware of pixel RGB components of each layer image of the multi-layer QR code image, such as a pixel component parser, or a general processor capable of executing a corresponding computer program to perform the aforementioned functions or Other hardware devices; and the image drawing module as described above may be hardware having the function of performing the foregoing drawing of a single-layer QR code image by the pixel RGB components of each layer of the multi-layer QR code image, such as an image renderer, or A general processor or other hardware device capable of executing a corresponding computer program to perform the aforementioned functions (the various embodiments described herein may apply the above described principles).
  • the pixel component parsing module 601 of the example of FIG. 6 may further include a pixel obtaining unit 701 and a parsing unit 702, such as the multi-layer fast response code decoding apparatus 07 provided by another embodiment of the present invention, as shown in FIG.
  • the pixel obtaining unit 701 is configured to obtain a pixel value of a pixel of the detection pattern. Since each layer of the multi-layer QR code image has a detection pattern, for example, a "back" font, the area of the detection pattern is covered by each layer image, and the pixel containing the information also contains the information of each layer image. The color overlay. Therefore, in this embodiment, the pixel obtaining unit 701 can sample the detection pattern to obtain a pixel value of the pixel of the detection pattern.
  • the pixel points of the area covered by the detection pattern are obtained by sampling, and the approximate pixel value of the pixel of the detection pattern is obtained by using the method of averaging or mean square error; the parsing unit 702 is configured to obtain the position according to the pixel obtaining unit 701. Depicting the pixel value of the pixel of the detection pattern, parsing the number of layers of the multi-layer QR code image and the pixel value of each layer, that is, according to the multi-layer QR
  • the R component of the RGB component of the pixel of the code is ⁇ ⁇
  • the G component is y k y k
  • FIG. 1 The embodiment provided in FIG. 1 is the same and will not be described again.
  • the image processing module 603 illustrated in FIG. 6 or FIG. 7 may further include a binarization processing unit.
  • a multi-layer fast response code decoding apparatus 08 according to another embodiment of the present invention, wherein:
  • a binarization processing unit 801 configured to perform binarization, denoising, and morphological algorithm processing on the single-layer QR code image to obtain a binarized image;
  • a white pixel block (a pixel block that does not contain information content or a codeword that does not contain a codeword) of the binarized image is calibrated in white or a convention color.
  • the identifying unit 802 is configured to perform QR code identification on the binarized image, including searching for a detection pattern, a version information, a positioning pattern, a correction pattern, and a demasking information;
  • the information parsing unit 803 is configured to parse the binarized image after the QR code identification to obtain the information content included in the single-layer QR code image, and if the information content only includes the text information, write the information content In the text tool; if the information contains the format and file name of the original file, write it to the hard disk in the original file format.
  • Method 1 Obtain a number of image layers N of a multi-layer fast response QR code, the multi-layer fast response QR code is a fast response QR code obtained by encoding the original fast response QR code; and obtaining N groups from the two-way reversible color feature database a color coefficient feature value, the color coefficient feature value is used to change a color parameter of the original fast response QR code image layer; and the original fast response QR code image layer is colored according to the obtained N sets of color coefficient feature values The superposition is sequentially performed to obtain the multi-layer fast response QR code image.
  • Method 2 Parsing a multi-layer fast response QR code image to obtain pixel RGB components of each layer of the multi-layer fast response QR code image, the number of image layers of the multi-layer fast response QR code being N, the multi-layer
  • the quick response QR code image is a QR code image obtained by superimposing the image layers of the original quick response QR code in a color order after acquiring N sets of color coefficient feature values from the bidirectional reversible color feature library; Multi-layer fast response QR code image pixel RGB component of each layer image to draw a single layer fast response QR code image; processing the single layer fast response QR code image to parse out the single layer fast response QR code image Information content; The information content parsed from each single layer quick response QR code image is connected in the color order.
  • the program may be stored in a computer readable storage medium, and the storage medium may include: a Read Only Memory (ROM), a Random Access Memory (RAM), a magnetic disk or an optical disk, and the like.
  • ROM Read Only Memory
  • RAM Random Access Memory
  • magnetic disk or an optical disk and the like.

Abstract

Provided are a multilayer quick response code encoding/decoding method and encoding/decoding device to improve the information capacity contained in the QR code. The method includes: obtaining an image layer number N of a multilayer quick response (QR) code, with the multilayer quick response (QR) code being a multilayer quick response (QR) code obtained by encoding an original quick response (QR) code; acquiring N groups of colour coefficient characteristic values from a bidirectional invertible colour characteristic library, wherein the colour coefficient characteristic values are used for changing the colour parameter of the original quick response (QR) code image layer; and overlaying the original quick response (QR) code image layer according to an agreed colour order using the acquired N groups of colour coefficient characteristic values so as to obtain the multilayer quick response (QR) code image. On one hand, the multilayer QR code image can meet the transmission of a large amount of information, thus improving the transmission efficiency; on the other hand, multiple encryption of the file can be carried out, increasing the security of file transmission.

Description

多层快速响应码图像编码、 解码方法和编码、 解码装置 技术领域  Multi-layer fast response code image coding, decoding method and coding and decoding device
本发明涉及图像处理领域, 尤其涉及多层快速响应码编码、解码方法和编 码、 解码装置。  The present invention relates to the field of image processing, and in particular, to a multi-layer fast response code encoding and decoding method and a coding and decoding apparatus.
背景技术 Background technique
快速响应 ( Quick Response, QR )码是 1994年由日本 Denso-Wave公司发 明的一种二维条码。 目前的 QR码呈正方形, 只有黑白两色。 在 QR码的三个角 落, 分別印有三个类似汉字 "回" 的正方形小图案。 三个 "回" 字形的正方形 小图案可以帮助解 QR码时识別 QR码倾斜的角度。 因此, QR码的使用者在扫 描 QR码时不需要对准, 即, 无论以任何角度扫描, 资料仍可正确被读取。  The Quick Response (QR) code is a 2D barcode that was developed in 1994 by Denso-Wave, Japan. The current QR code is square, only black and white. In the three corners of the QR code, three small square patterns resembling the Chinese character "back" are printed. The squares of the three "back" glyphs help to identify the angle at which the QR code is tilted when the QR code is resolved. Therefore, the user of the QR code does not need to be aligned when scanning the QR code, that is, the data can be read correctly regardless of scanning at any angle.
正是由于 QR码比普通条码可以储存更多资料, 在识別时也比普通条码识 別快这些特点, QR码才被称为 "快速响应" 码。  It is precisely because the QR code can store more data than the ordinary barcode, and the recognition is faster than the ordinary barcode. The QR code is called the "quick response" code.
现有技术 QR码是按照其自身既有的编码规则, 通过某种算法得到。 这样, 使用 QR码编码的图像, 其包含的信息容量总会受到一定限制。 例如, 按照现 有技术提供的编码算法, 一幅 QR码图像, 其内容若是数字, 则最多包含 7059 个字符; 若是字母, 则最多包含 4296个字符; 若是二进制数, 则最多包含 2953 字节。 尽管 QR码包含的信息容量会随着 QR码版本的提高而有所增加, 但 QR 码版本不可能无限制地提高。 换言之, 当 QR码提高至最高版本时, QR码包含 的信息容量也随之增加至最大, 不再继续提高。  Prior Art QR codes are obtained by some algorithm according to their own existing coding rules. Thus, an image encoded using a QR code always has a limited amount of information. For example, according to the encoding algorithm provided by the prior art, a QR code image, if the number is a number, contains up to 7059 characters; if it is a letter, it can contain up to 4296 characters; if it is a binary number, it can contain up to 2953 bytes. Although the amount of information contained in the QR code will increase as the QR code version increases, the QR code version cannot be increased indefinitely. In other words, when the QR code is increased to the highest version, the information capacity contained in the QR code is also increased to the maximum and will not continue to increase.
发明内容 Summary of the invention
本发明实施例提供多层快速响应码编码、 解码方法和编码、 解码装置, 以 提高 QR码包含的信息容量。  Embodiments of the present invention provide a multi-layer fast response code encoding and decoding method, and an encoding and decoding apparatus to improve information capacity included in a QR code.
本发明实施例提供一种多层快速响应码编码方法, 所述方法包括: 获取多层快速响应 QR码的图像层 所述多层快速响应 QR码是对原始 快速响应 QR码进行编码后得到的多层快速响应 QR码; An embodiment of the present invention provides a multi-layer fast response code encoding method, where the method includes: acquiring an image layer of a multi-layer fast response QR code, the multi-layer fast response QR code is original Multi-layer fast response QR code obtained by fast response QR code encoding;
从双向可逆颜色特征库获取 N组颜色系数特征值, 所述颜色系数特征值用 于改变所述原始快速响应 QR码图像层的颜色参数;  Obtaining N sets of color coefficient feature values from the bidirectional reversible color feature library, wherein the color coefficient feature values are used to change color parameters of the original fast response QR code image layer;
使用所述获取的 N组颜色系数特征值将所述原始快速响应 QR码图像层按 照约定的颜色顺序进行叠加以得到所述多层快速响应 QR码图像。  The original fast response QR code image layers are superimposed in a predetermined color order using the acquired N sets of color coefficient feature values to obtain the multi-layer fast response QR code image.
本发明实施例提供一种多层快速响应码解码方法, 所述方法包括: 解析多层快速响应 QR码图像以得到所述多层快速响应 QR码图像每一层 图像的像素 RGB分量,所述多层快速响应 QR码的图像层数为 N,所述多层快速 响应 QR码图像为从双向可逆颜色系数特征库获取 N组颜色特征值后将原始快 速响应 QR码的图像层按照颜色顺序进行叠加得到的多层快速响应 QR码图像; 由所述多层 QR码图像每一层图像的像素 RGB分量绘制单层快速响应 QR 码图像;  An embodiment of the present invention provides a multi-layer fast response code decoding method, where the method includes: parsing a multi-layer fast response QR code image to obtain pixel RGB components of each layer of the multi-layer fast response QR code image, The number of image layers of the multi-layer fast response QR code is N, and the multi-layer fast response QR code image is obtained by acquiring N sets of color feature values from the bidirectional reversible color coefficient feature library and then performing the image layer of the original fast response QR code in color order. Superimposing a multi-layer fast response QR code image; drawing a single-layer fast response QR code image from pixel RGB components of each layer of the multi-layer QR code image;
对所述单层快速响应 QR码图像进行处理以解析出所述单层快速响应 QR 码图像包含的信息内容;  Processing the single layer quick response QR code image to parse the information content included in the single layer fast response QR code image;
将所述从各个单层快速响应 QR码图像解析出的信息内容按照所述颜色顺 序进行连接。  The information content parsed from each of the single layer quick response QR code images is connected in the color sequence.
本发明实施例提供一种多层快速响应码编码装置, 所述装置包括: 图像层数获取模块,用于获取多层快速响应 QR码的图像层数 N,所述多层 快速响应 QR码是对原始快速响应 QR码进行编码后得到的多层快速响应 QR 码;  An embodiment of the present invention provides a multi-layer fast response code encoding apparatus, where the apparatus includes: an image layer number obtaining module, configured to acquire a number of image layers N of a multi-layer fast response QR code, and the multi-layer fast response QR code is a multi-layer fast response QR code obtained by encoding the original fast response QR code;
颜色特征值获取模块, 用于从双向可逆颜色系数特征库获取 N组颜色特征 值,所述颜色系数特征值用于改变所述原始快速响应 QR码图像层的颜色参数; 叠加模块, 用于使用所述获取的 N组颜色系数特征值将所述原始快速响应 QR码的图像层按照颜色顺序进行叠加以得到所述多层快速响应 QR码图像。 本发明实施例提供一种多层快速响应码解码装置, 所述装置包括: 像素分量解析模块, 用于解析多层快速响应 QR码图像以得到所述多层快 速响应 QR码图像每一层图像的像素 RGB分量,所述多层快速响应 QR码图像为 从双向可逆颜色特征库获取 N组颜色系数特征值后将原始快速响应 QR码的图 像层按照颜色顺序进行叠加得到的多层快速响应 QR码图像; a color feature value obtaining module, configured to acquire N sets of color feature values from the bidirectional reversible color coefficient feature library, wherein the color coefficient feature values are used to change color parameters of the original fast response QR code image layer; The acquired N sets of color coefficient feature values superimpose the image layers of the original quick response QR code in color order to obtain the multi-layer fast response QR code image. An embodiment of the present invention provides a multi-layer fast response code decoding apparatus, where the apparatus includes: a pixel component parsing module, configured to parse a multi-layer fast response QR code image to obtain each layer of the multi-layer fast response QR code image. The pixel RGB component, the multi-layer fast response QR code image is a multi-layer fast response QR obtained by superimposing the image layers of the original fast response QR code in color order after acquiring N sets of color coefficient feature values from the bidirectional reversible color feature library. Code image
图像绘制模块, 用于由所述多层快速响应 QR码图像每一层图像的像素 RGB分量绘制单层快速响应 QR码图像;  An image drawing module, configured to draw a single layer quick response QR code image by pixel RGB components of each layer image of the multi-layer fast response QR code image;
图像处理模块, 用于对所述单层快速响应 QR码图像进行处理以解析出所 述单层快速响应 QR码图像包含的信息内容;  An image processing module, configured to process the single layer quick response QR code image to parse the information content included in the single layer fast response QR code image;
连接模块, 用于将所述从各个单层快速响应 QR码图像解析出的信息内容 按照所述颜色顺序进行连接。  And a connection module, configured to connect the information content parsed from each single layer quick response QR code image according to the color sequence.
从上述本发明实施例可知,由于可以从双向可逆颜色特征库获取组数与多 层快速响应 QR码的图像层数 N相等的颜色系数特征值, 用于将原始 QR码图像 层按照颜色顺序进行叠加, 得到所述多层 QR码图像, 通过这种方法扩大了原 始 QR码图像包含的信息容量。 因此, 一方面, 多层 QR码图像可以满足大信息 量的传输, 从而提高传输效率, 另一方面, 可以对文件进行多重加密, 增加了 文件传输的安全性。  It can be seen from the above embodiment of the present invention that the color coefficient feature value equal to the number of image layers N of the multi-layer fast response QR code can be obtained from the bidirectional reversible color feature library, and the original QR code image layer is used in color order. Superimposing, the multi-layer QR code image is obtained, by which the information capacity contained in the original QR code image is expanded. Therefore, on the one hand, multi-layer QR code images can satisfy the transmission of large amounts of information, thereby improving transmission efficiency. On the other hand, multiple encryption of files can be performed, which increases the security of file transmission.
附图说明 DRAWINGS
为了更清楚地说明本发明实施例的技术方案,下面将对现有技术或实施例 描述中所需要使用的附图作筒单地介绍,显而易见地, 下面描述中的附图仅仅 是本发明的一些实施例,对于本领域普通技术人员来讲,在不付出创造性劳动 性的前提下, 还可以如这些附图获得其他的附图。  In order to more clearly illustrate the technical solutions of the embodiments of the present invention, the drawings used in the description of the prior art or the embodiments will be briefly described below. Obviously, the drawings in the following description are only the present invention. For some embodiments, other drawings may be obtained as those of ordinary skill in the art without any inventive labor.
图 1是本发明实施例提供的一种多层快速响应码编码方法流程示意图; 图 2是本发明实施例提供的多层快速响应码解码方法流程示意图; 图 3是本发明实施例提供的多层快速响应码编码装置结构示意图; 图 4是本发明另一实施例提供的多层快速响应码编码装置结构示意图; 图 5是本发明另一实施例提供的多层快速响应码编码装置结构示意图; 图 6是本发明实施例提供的多层快速响应码解码装置结构示意图; 图 7是本发明另一实施例提供的多层快速响应码解码装置结构示意图; 图 8是本发明另一实施例提供的多层快速响应码解码装置结构示意图。 具体实施方式 1 is a schematic flowchart of a multi-layer fast response code encoding method according to an embodiment of the present invention; FIG. 2 is a schematic flowchart of a multi-layer fast response code decoding method according to an embodiment of the present invention; Schematic diagram of a layer fast response code encoding device; 4 is a schematic structural diagram of a multi-layer fast response code encoding apparatus according to another embodiment of the present invention; FIG. 5 is a schematic structural diagram of a multi-layer fast response code encoding apparatus according to another embodiment of the present invention; FIG. 7 is a schematic structural diagram of a multi-layer fast response code decoding apparatus according to another embodiment of the present invention; FIG. 8 is a multi-layer fast response code decoding apparatus according to another embodiment of the present invention; Schematic. detailed description
本发明实施例提供了提供多层快速响应码编码、解码方法和编码、解码装 置, 以提高 QR码包含的信息容量。  Embodiments of the present invention provide a multi-layer fast response code encoding, decoding method, and encoding and decoding apparatus to improve information capacity included in a QR code.
下面将结合本发明实施例中的附图,对本发明实施例中的技术方案进行清 楚、 完整地描述, 显然, 所描述的实施例仅仅是本发明一部分实施例, 而不是 全部的实施例。基于本发明中的实施例, 本领域普通技术人员在没有做出创造 性劳动前提下所获得的所有其他实施例, 都属于本发明保护的范围。  BRIEF DESCRIPTION OF THE DRAWINGS The technical solutions in the embodiments of the present invention will be described in detail below with reference to the accompanying drawings. All other embodiments obtained by a person of ordinary skill in the art based on the embodiments of the present invention without the creative work are all within the scope of the present invention.
请参阅附图 1 , 是本发明实施例提供的一种多层快速响应码编码方法流程 示意图, 主要包括步骤:  1 is a schematic flowchart of a multi-layer fast response code encoding method according to an embodiment of the present invention, which mainly includes the following steps:
S101 , 获取多层快速响应 QR码的图像层 ¾N。  S101. Acquire an image layer 3⁄4N of a multi-layer fast response QR code.
在本发明实施例中, 所述多层 QR码是对原始快速响应 QR码进行编码后得 到的多层 QR码,其图像层数 N与用户需求相关,例如,与加密的文件的安全性、 多层 QR码的信息容量或者信息量传输的大小等相关。 一般地, 用户需求越严 格, 例如, 文件的安全性越高或多层 QR码的信息容量越大, 多层 QR码的图像 层数 N也应该越大。  In the embodiment of the present invention, the multi-layer QR code is a multi-layer QR code obtained by encoding the original fast response QR code, and the image layer number N is related to the user requirement, for example, the security of the encrypted file, The information capacity of the multi-layer QR code or the size of the information amount transmission is related. In general, the stricter the user's needs, for example, the higher the security of the file or the larger the information capacity of the multi-layer QR code, the larger the number of image layers N of the multi-layer QR code should be.
S102, 从双向可逆颜色特征库获取 N组颜色系数特征值, 所述颜色系数特 征值用于改变所述原始 QR码图像层的颜色参数。  S102. Acquire N sets of color coefficient feature values from the bidirectional reversible color feature library, where the color coefficient feature values are used to change color parameters of the original QR code image layer.
征库存储有颜色系数特征值, 这些颜色系数特征值用于改变所述原始 QR码的 图像层的颜色参数。 所谓原始 QR码图像层的颜色参数, 可以是原始 QR码图像 层中图像像素的 RGB分量, 即, 图像的三基色(R, G, B )中的红(Red, R )、 绿(Green, G )和蓝(Blue, B )。 The levy inventory stores color coefficient feature values for changing the color parameters of the image layer of the original QR code. The color parameter of the original QR code image layer can be the original QR code image. The RGB components of the image pixels in the layer, that is, red (Red, R), green (Green, G), and blue (Blue, B) in the three primary colors (R, G, B) of the image.
之所以称为 "双向可逆颜色特征库", 是因为本发明实施例提供的双向可 逆颜色特征库既可用于在对原始 QR码编码时计算多层 QR码图像的像素 RGB 分量, 又可用于在对多层 QR码解码时计算多层 QR码图像包含的图像层数。 像层按照颜色顺序进行叠加以得到所述多层 QR码图像。  It is called "bidirectional reversible color feature library" because the bidirectional reversible color feature library provided by the embodiment of the present invention can be used to calculate the pixel RGB component of the multi-layer QR code image when encoding the original QR code, and can be used in The number of image layers included in the multi-layer QR code image is calculated when decoding the multi-layer QR code. The image layers are superimposed in color order to obtain the multi-layer QR code image.
使用获取的 N组颜色系数特征值将原始 QR码的图像层按照颜色顺序进行 叠加得到的多层 QR码图像, 其图像层数为 N。 若一幅原始 QR码图像包含的信 息容量使用 numQR表示, 则使用获取的 N组颜色系数特征值将原始 QR码的图像 层按照颜色顺序进行叠加得到的多层 QR码图像, 其包含的信息容量大约为 N x numQR , 可见, 编码后得到的多层 QR码图像的信息容量是原始 QR码图像包 含的信息容量的 N倍,而信息容量的扩大,也意味着可以对文件进行多重加密, 增加文件传输的安全性。 A multi-layer QR code image obtained by superimposing the image layers of the original QR code in color order using the obtained N sets of color coefficient feature values, the number of image layers being N. If an original QR code image contains information capacity represented by num QR , the multi-layer QR code image obtained by superimposing the image layers of the original QR code in color order using the obtained N sets of color coefficient feature values, the information contained therein The capacity is approximately N x num QR . It can be seen that the information capacity of the multi-layer QR code image obtained after encoding is N times the information capacity of the original QR code image, and the expansion of the information capacity means that the file can be multi-encrypted. , increase the security of file transfer.
在本发明实施例中, 所述的 "颜色顺序" 可以在编码端编码之前与解码端 约定, 譬如, 在编码前约定的颜色顺序是第一层是红色, 第二层是黄色, 第三 层是紫色。如此,解码端在解码时按照这个颜色顺序将解码出来的信息内容进 行连接, 还原多层 QR码包含的原始信息。  In the embodiment of the present invention, the "color order" may be agreed with the decoding end before encoding at the encoding end. For example, the color order agreed upon before encoding is that the first layer is red, the second layer is yellow, and the third layer is It is purple. In this way, the decoding end connects the decoded information contents in this color order during decoding, and restores the original information contained in the multi-layer QR code.
从上述本发明实施例提供的多层快速响应码编码方法可知,由于可以从双 向可逆颜色特征库获取组数与多层快速响应 QR码的图像层数 N相等的颜色系 数特征值, 用于将原始 QR码图像层按照颜色顺序进行叠加, 得到所述多层 QR 码图像, 通过这种方法扩大了原始 QR码图像包含的信息容量。 因此, 一方面, 多层 QR码图像可以满足大信息量的传输, 从而提高传输效率, 另一方面, 可 以对文件进行多重加密, 增加了文件传输的安全性。 用户设计一个多层 QR码前, 可以知道该多层 QR码应该包含的总信息容 量, 而多层快速响应 QR码中每一层图像的最大信息容量也具有一个近似值。 因此, 在本发明一个实施例中, 对于多层快速响应 QR码的图像层数 N, 可以通 过将多层 QR码的总信息容量与所述多层 QR码中每一层图像的最大信息容量 相除来获取, 即, 若两者能够整除, 则直接将两者相除所得之商作为为多层 QR码的图像层数 N; 若两者不能整除, 则将两者相除所得之商向上取整得到的 值作为所述多层快速响应 QR码的图像层 例如, 多层 QR码的总信息容量 与所述多层 QR码中每一层图像的最大信息容量相除得到的商为 3.2 , 则将 3.2 向上取整得到的 4作为多层快速响应 QR码的图像层数。 According to the multi-layer fast response code encoding method provided by the embodiment of the present invention, since the color coefficient characteristic value equal to the image layer number N of the multi-layer fast response QR code can be obtained from the bidirectional reversible color feature library, The original QR code image layers are superimposed in color order to obtain the multi-layer QR code image, by which the information capacity of the original QR code image is expanded. Therefore, on the one hand, the multi-layer QR code image can satisfy the transmission of a large amount of information, thereby improving the transmission efficiency. On the other hand, the file can be multi-encrypted, which increases the security of file transmission. Before designing a multi-layer QR code, the user can know the total information capacity that the multi-layer QR code should contain, and the maximum information capacity of each layer of the multi-layer fast response QR code also has an approximation. Therefore, in one embodiment of the present invention, for the number of image layers N of the multi-layer fast response QR code, the total information capacity of the multi-layer QR code and the maximum information capacity of each layer of the multi-layer QR code may be Divide to obtain, that is, if the two can be divisible, the quotient obtained by dividing the two directly is regarded as the image layer number N of the multi-layer QR code; if the two cannot be divisible, the quotient of dividing the two is obtained The value obtained by rounding up is used as the image layer of the multi-layer fast response QR code, for example, the total information capacity of the multi-layer QR code is divided by the maximum information capacity of each layer image in the multi-layer QR code. 3.2, then the 4 obtained by rounding up 3.2 is used as the image layer number of the multi-layer fast response QR code.
在本发明实施例中,从双向可逆颜色特征库获取的每一组颜色系数特征值 包含颜色系数特征分量 ak、 颜色系数特征分量 bk和颜色系数特征分量 ck , 即, 每一组颜色特征值使用 ak , bk , )表示。 可以以所述每一组颜色系数特 征值包含的颜色系数特征分量 ak、 颜色系数特征分量 bk和颜色系数特征分量 ck作为特征系数, 将原始 QR码的图像层中每一层图像的像素 RGB分量对应叠 加以得到所述多层 QR码的像素 RGB分量, 即, 像素值, 其中, 对于原始 QR码 图像中的白色像素块, 使用白色或者约定的颜色标定; 然后, 根据多层 QR码 的像素 RGB分量绘制所述多层 QR码图像。 在绘制所述多层 QR码图像时, 按照 颜色顺序 (该颜色顺序可以事先约定) 叠加图像层 (由计算得到的多层 QR码 的像素组成)。 例如, 计算得到的多层 QR码, 其中一个图像层是黄色(其像素 的 RGB分量记为 (Rl , Gl , B1 ) ), 另一个图像层是橙色(其像素的 RGB分量 记为(R2, G2, B2 ) ), 还有一个图像层是紫色(其像素的 RGB分量记为(R3 , G3 , B3 ) )。 如果约定的颜色顺序是黄色、 橙色和紫色, 则先绘制像素为(R1 , Gl , B1 )的黄色构成多层 QR码的第一个图像层, 在黄色构成的第一个图像层 上, 叠加像素为 (R2, G2, B2 )的橙色构成多层 QR码的第二个图像层, 在黄 色和橙色构成的两层图像上, 叠加像素为 (R3 , G3 , B3 ) 的紫色, 从而构成 三层 QR码图像。 像层按照颜色顺序进行叠加以得到多层 QR码图像的一种方法。 通过这种方法 得到的多层 QR码图像, 在信息传输时, 由于其包含的信息容量可以依据获取 的 N组颜色特征值成 N倍增加, 并且, 在多层 QR码图像大小增加幅度不大(与 原始的 QR码图像相比) 的情况下, 可以将不同格式的文件通过读取其在计算 机中二进制码的方式, 将其存放在多层 QR码图像中。 In the embodiment of the present invention, each set of color coefficient feature values obtained from the bidirectional reversible color feature library includes a color coefficient feature component a k , a color coefficient feature component b k , and a color coefficient feature component c k , that is, each set of colors The eigenvalues are represented by a k , b k , ). The color coefficient feature component a k , the color coefficient feature component b k , and the color coefficient feature component c k included in each set of color coefficient feature values may be used as feature coefficients, and each layer image in the image layer of the original QR code is The pixel RGB components are correspondingly superimposed to obtain a pixel RGB component of the multi-layer QR code, that is, a pixel value, wherein, for a white pixel block in the original QR code image, white or a predetermined color is used for calibration; and then, according to the multi-layer QR The pixel RGB component of the code plots the multi-layer QR code image. When the multi-layer QR code image is drawn, the image layer (consisting of the pixels of the calculated multi-layer QR code) is superimposed in color order (the color order can be agreed in advance). For example, the calculated multi-layer QR code, one of which is yellow (the RGB component of the pixel is denoted as (Rl, Gl, B1)), and the other image layer is orange (the RGB component of the pixel is denoted as (R2, G2, B2)), There is also an image layer that is purple (the RGB components of its pixels are recorded as (R3, G3, B3)). If the agreed color order is yellow, orange, and purple, first draw the first image layer of the multi-layer QR code with the pixel (R1, Gl, B1), and superimpose it on the first image layer composed of yellow. The orange color of the pixel (R2, G2, B2) constitutes the second image layer of the multi-layer QR code, in yellow On the two-layer image composed of color and orange, the superimposed pixels are purple of (R3, G3, B3), thereby forming a three-layer QR code image. A method in which layers are superimposed in color order to obtain a multi-layer QR code image. The multi-layer QR code image obtained by this method can increase N-fold according to the acquired N-group color feature values during information transmission, and the image size of the multi-layer QR code does not increase much. In the case of (compared to the original QR code image), files of different formats can be stored in the multi-layer QR code image by reading their binary code in the computer.
需要说明的是,在本发明实施例中, 由于从双向可逆颜色特征库获取的每 一组颜色系数特征值( ^ , bk , )是唯一的, 因此, 以所述每一组颜色系 数特征值 ak , bk , ck )作为特征系数将原始 QR码的图像层中每一层图像的 像素 RGB分量对应叠加得到的多层 QR码的像素 RGB分量也是唯一的, 如此, 根据多层 QR码的像素 RGB分量绘制的多层 QR码图像也具有唯一性。 It should be noted that, in the embodiment of the present invention, since each set of color coefficient feature values (^, b k , ) obtained from the bidirectional reversible color feature library is unique, the color coefficient characteristics of each group are described. The values a k , b k , c k ) as the feature coefficients, the pixel RGB components of the multi-layer QR code obtained by superimposing the pixel RGB components of each layer image in the image layer of the original QR code are also unique, thus, according to the multi-layer The multi-layer QR code image drawn by the pixel RGB component of the QR code is also unique.
作为本发明一个实施例,以每一组颜色系数特征值包含的颜色系数特征分 量¾、 颜色系数特征分量 和颜色系数特征分量 作为特征系数, 将原始 QR 码的图像层中每一层图像的像素的 RGB分量对应叠加以得到所述多层 QR码的 像素 RGB分量可以通过如下步骤实现:  As an embodiment of the present invention, the color coefficient feature component 3⁄4, the color coefficient feature component, and the color coefficient feature component included in each set of color coefficient feature values are used as feature coefficients, and pixels of each layer image in the image layer of the original QR code are used. The RGB components corresponding to the superposition to obtain the pixel RGB components of the multi-layer QR code can be realized by the following steps:
步骤 S 1 , 将所述每一组颜色系数特征值包含的颜色系数特征分量 ak、 颜 色系数特征分量 bk和颜色系数特征分量 ck与原始 QR码的图像层中每一层图像 的像素 RGB分量的 R分量 、 G分量) ^和 B分量 分別相乘; Step S1, the color coefficient feature component a k , the color coefficient feature component b k , and the color coefficient feature component c k included in each set of color coefficient feature values and the pixel of each layer image in the image layer of the original QR code The R component and the G component of the RGB component are respectively multiplied by the B component;
即, 与 相乘, 与^相乘, ¾与 相乘,所得乘积分別记为 、 bkyk 和 。 此处, 原始 QR码的图像层中每一层图像的像素 RGB分量的 R分量 、 G分量 ^和 B分量 分別与一般图像的三基色(R, G, B ) 中的红(Red, R )、 绿(Green, G )和蓝(Blue , B )含义相同。 对于原始 QR码中的白色区域, 其 RGB分量既可以是组成白色的像素的 RGB分量,又可以是约定的其他颜色的像 素的 RGB分量, 本发明实施例可以不做限定。 That is, multiplied by , multiplied by ^, 3⁄4 and multiplied, and the obtained product is denoted as b k y k and . Here, the R component, the G component ^ and the B component of the pixel RGB component of each layer image in the image layer of the original QR code are respectively red (Red, R) in the three primary colors (R, G, B) of the general image. , Green (G) and Blue (Blue, B) have the same meaning. For the white area in the original QR code, The RGB component may be the RGB component of the pixel constituting the white color, or the RGB component of the pixel of the other color of the convention, which may not be limited in the embodiment of the present invention.
需要说明的是, 若原始 QR码的图像层的层数比从双向可逆颜色特征库获 取的颜色系数特征值的组数少, 则少出的原始 QR码的图像层其像素 RGB分量 的 R分量 、 G分量) ^和 B分量 均视为 0。 例如, 从双向可逆颜色特征库获取 三组颜色系数特征值记为 ( A, bx , ), ( a2 , b2 , c2 )和( α3 , b3 , c3 ), 若原始 QR码的图像层为两层, 其像素 RGB分量的 R分量 、 G分量 Λ和 B分量 分別记为 jx , 和( , y2 , z2 ), 则原始 QR码少出的一个图像层 的 R分量 、 G分量 Λ和 B分量 ¾, 即 3, y3 , ), 可以将其视为 (0, 0, 0)。 It should be noted that if the number of layers of the image layer of the original QR code is smaller than the number of sets of the color coefficient feature values obtained from the bidirectional reversible color feature library, the R component of the pixel layer RGB component of the image layer of the original QR code is reduced. , G component) ^ and B components are regarded as 0. For example, the three sets of color coefficient eigenvalues are obtained from the bidirectional reversible color feature library as (A, b x , ), ( a 2 , b 2 , c 2 ) and ( α 3 , b 3 , c 3 ), if the original QR The image layer of the code is two layers, and the R component, the G component Λ and the B component of the pixel RGB component are respectively recorded as j x , and ( , y 2 , z 2 ), and the R of the image layer of the original QR code is less. The component, the G component Λ, and the B component 3⁄4 , that is, 3 , y 3 , ), can be regarded as (0, 0, 0).
步骤 S2, 对所述每一组颜色系数特征值包含的颜色系数特征分量 、 颜 色系数特征分量 bk和颜色系数特征分量 ck与原始 QR码的图像层中每一层图像 的像素 RGB分量的 R分量 、 G分量 Λ和 B分量 分別相乘所得乘积 、 bkyk Step S2, the color coefficient feature component, the color coefficient feature component bk, and the color coefficient feature component ck included in each set of color coefficient feature values and the pixel RGB component of each layer image in the image layer of the original QR code The product of the R component, the G component Λ, and the B component respectively multiplied, b k y k
N N N N N  N N N N N
和^ 分別求和, 得到 ∑¾ 、∑ Λ和 以所述 ∑"Λ、∑^Λ和And ^ separately sum, get ∑ 3⁄4 , ∑ Λ and with the ∑ "Λ, ∑ ^ Λ and
N k=i k=l k=l k=l k=l N k=i k=l k=l k=l k=l
分別作为所述多层 QR码的像素 RGB分量的 R分量、 G分量和 B分量。 k=l  The R component, the G component, and the B component of the pixel RGB component of the multi-layer QR code, respectively. k=l
以从双向可逆颜色特征库获取三组颜色系数特征值(记为 ( A, bx , cx ), ( a2 , b2, c2 )和( α3 , b3 , c3 ))为例, 原始 QR码的图像层(假设也为三层 ), 其像素 RGB分量的 R分量 、 G分量 Λ和 B分量 ¾分別记为( jx , )、( , y2 , ) 和( , y3 , ), 则得到的多层 QR码的像素 RGB分量的 R分量为 αχ jj-i- z1 , G分量为 <¾ +b2 y2 + c2 , B分量为 <¾ +b3 y3 + c3 ; 特另l 地, 若原始 QR码的图像层只有两层, 其像素 RGB分量的 R分量 、 G分量 Λ和 B分量 分別记为 ( ·¾, jx , )和( , y2 , z2 ), 按照前述规定, 其( ¾, y3 , )视为 0,则得到的多层 QR码的像素 RGB分量的 R分量为 + y1 + Cl ζ , G分量为 a2 x2 + b2 y2 + c2 z2 , B分量为 0 ( =a3 x3+b3 y3+c3 z3 = 3x 0 +b3x 0 +c3x 0)。 Obtaining three sets of color coefficient eigenvalues (denoted as (A, b x , c x ), ( a 2 , b 2 , c 2 ) and ( α 3 , b 3 , c 3 )) from the bidirectional reversible color feature library For example, the image layer of the original QR code (assumed also three layers), the R component, the G component Λ and the B component 3⁄4 of the pixel RGB component are denoted as ( j x , ), ( , y 2 , ) and ( , y , respectively. 3 , ), the R component of the pixel RGB component of the obtained multi-layer QR code is α χ jj-i- z 1 , the G component is <3⁄4 + b 2 y 2 + c 2 , and the B component is < 3⁄4 + b 3 y 3 + c 3 ; In particular, if the image layer of the original QR code has only two layers, the R component, the G component Λ and the B component of the pixel RGB component are respectively recorded as (·3⁄4, j x , ) and ( , y 2 , z 2 ), according to the foregoing, when ( 3⁄4 , y 3 , ) is regarded as 0, the R component of the pixel RGB component of the obtained multi-layer QR code is + y 1 + Cl ζ , and the G component is a 2 x 2 + b 2 y 2 + c 2 z 2 , the B component is 0 ( = a 3 x 3 + b 3 y 3 + c 3 z 3 = 3 x 0 + b 3 x 0 + c 3 x 0).
以下给出一个更为具体的实施例来说明本发明的多层快速响应码编码方 法。 为了便于说明, 在以下实施例中, 假设颜色系数特征值全为 1。 需要说明 的是, 虽然这里是以颜色系数特征值全为 1进行说明, 但本领域技术人员可以 理解的是, 本实施例提供的方法依然适用于颜色系数特征值不全为 1的情形。  A more specific embodiment is given below to illustrate the multi-layer fast response code encoding method of the present invention. For convenience of explanation, in the following embodiments, it is assumed that the color coefficient feature values are all ones. It should be noted that although the color coefficient feature values are all described herein, those skilled in the art can understand that the method provided in this embodiment is still applicable to the case where the color coefficient feature values are not all ones.
原始 QR码图像由黑、 白两种颜色构成, 这两种颜色分別代表包含信息和 不包含信息的像素,信息经编码后分別为 1和 0。在图像上面用两种颜色来绘制 原始 QR码图像像素; 进一步, 将单层 QR码图像上的颜色用两种其它颜色来取 代。 因每层 QR图像均会包含 0, 即不包含信息的像素, 可以将此种颜色定义为 M, 像素值取为 M ( 50, 50, 50)。  The original QR code image consists of two colors, black and white. These two colors represent pixels containing information and no information. The information is encoded as 1 and 0 respectively. The original QR code image pixels are drawn in two colors on the image; further, the colors on the single layer QR code image are replaced with two other colors. Since each layer of QR image contains 0, that is, a pixel that does not contain information, this color can be defined as M, and the pixel value is taken as M (50, 50, 50).
单层 QR码图像包含信息的像素中, 颜色定义因每一层而不同, 但是有约 定的顺序。 以三层为例, 每一层是单层 QR码图像。 例如, 第一层 QR码图像中, 包含信息的颜色定义为 A ( 180, 0, 0); 第二层 QR码图像中, 包含信息的颜色 定义为 B (0, 180, 0); 第三层 QR码图像中, 包含信息的颜色定义为 C (0, 0, 150)。  In a single-layer QR code image containing pixels of information, the color definition varies from layer to layer, but in a predetermined order. Taking three layers as an example, each layer is a single layer QR code image. For example, in the first layer QR code image, the color containing the information is defined as A (180, 0, 0); in the second layer QR code image, the color containing the information is defined as B (0, 180, 0); In the layer QR code image, the color containing the information is defined as C (0, 0, 150).
以下分別以两层和三层图像为例具体阐述,(单层图像只包括 A和 M或 B和 M, 将图像二值化后, 即为原始 QR码图像)。  The following is an example of two-layer and three-layer images, respectively (the single-layer image includes only A and M or B and M, and the image is binarized, which is the original QR code image).
对于两层图像的情形, 假设包含信息的颜色是上述定义的 A (180, 0, 0) 和 B (0, 180, 0)。 两层图像叠加, 基元像素有三种颜色, 即 A (180, 0, 0 )、 B (0, 180, 0)和 M (30, 30, 30)。 两层图像叠加, 混合方式有以下四种: For the case of a two-layer image, assume that the color containing the information is A (180, 0, 0) and B (0, 180, 0) as defined above. The two-layer image is superimposed, and the primitive pixels have three colors, namely A (180, 0, 0), B (0, 180, 0), and M (30, 30, 30). Two layers of images are superimposed, and there are four ways to mix:
1、 A+B, 即, 像素点在两层图像中均含有信息, 图像叠加后, 该像素点 的像素值为 ( 180, 180, 0); 1. A+B, that is, the pixel points contain information in both layers of images, and after the image is superimposed, the pixel value of the pixel is (180, 180, 0);
2、 A+M, 即, 像素点在第一层图像中包含信息, 第二层图像中不包含信 息, 该叠加后该像素点的像素值为 (210, 30, 30); 3、 M+B, 即, 像素点在第一层图像中不包含信息, 第二层图像中包含信 息, 图像叠加后, 该像素点的像素值为像素值为 ( 30, 210, 30); 2. A+M, that is, the pixel contains information in the first layer image, and the second layer image does not contain information, and the pixel value of the pixel after the superposition is (210, 30, 30); 3. M+B, that is, the pixel does not contain information in the first layer image, and the second layer image contains information. After the image is superimposed, the pixel value of the pixel is (30, 210, 30);
4、 M+M, 即, 像素点在两层图像中均包含信息, 图像叠加后, 该像素点 的像素值为 (60, 60, 60)。  4. M+M, that is, the pixel contains information in both layers of images. After the image is superimposed, the pixel value of the pixel is (60, 60, 60).
对于三层图像的情形,假设包含信息的颜色是上述定义的 A ( 180, 0, 0)、 For the case of a three-layer image, assume that the color containing the information is A ( 180, 0, 0) as defined above,
B (0, 180, 0)和 C (0, 0, 180)。 三层图像叠加, 基元像素有四种颜色, 即 A (180, 0, 0)、 B (0, 180, 0)、 C (0, 0, 180)和 M (30, 30, 30)。 三 层图像叠加, 混合方式有以下八种: B (0, 180, 0) and C (0, 0, 180). The three-layer image is superimposed, and the primitive pixels have four colors, namely A (180, 0, 0), B (0, 180, 0), C (0, 0, 180), and M (30, 30, 30). Three layers of image overlay, the following eight ways to mix:
1、 A+B+C, 即, 像素点在三层图像中均包含信息, 图像叠加后, 该像素 点的像素值为 ( 180, 180, 180);  1. A+B+C, that is, the pixel points contain information in the three-layer image. After the image is superimposed, the pixel value of the pixel is (180, 180, 180);
2、 A+B+M, 即, 像素点在第一、 二层图像中均包含信息, 第三层图像中 不包含信息, 图像叠加后, 该像素点的像素值为像素值为 (210, 210, 30);  2. A+B+M, that is, the pixel contains information in the first and second layer images, and the third layer image does not contain information. After the image is superimposed, the pixel value of the pixel is pixel value (210, 210, 30);
3、 A+M+C, 即, 像素点在第一、 三层图像中均包含信息, 第二层图像中 不包含信息, 图像叠加后, 该像素点的像素值为像素值为 (210, 30, 210);  3. A+M+C, that is, the pixel points contain information in the first and third layer images, and the second layer image does not contain information. After the image is superimposed, the pixel value of the pixel is the pixel value (210, 30, 210);
4、 A+M+M, 即, 像素点在第一层图像中包含信息, 第二、 三层图像中 均不包含信息, 图像叠加后, 该像素点的像素值为像素值为 (240, 60, 60);  4. A+M+M, that is, the pixel contains information in the first layer image, and the second and third layer images do not contain information. After the image is superimposed, the pixel value of the pixel is (240, 60, 60);
5、 M+B+C, 即, 像素点在第一层图像中不包含信息, 第二、 三层图像中 均包含信息, 图像叠加后, 该像素点的像素值为像素值为 (30, 210, 210);  5, M+B+C, that is, the pixel does not contain information in the first layer image, and the second and third layer images all contain information. After the image is superimposed, the pixel value of the pixel is (30). 210, 210);
6、 M+M+C, 即, 像素点在第一、 二层图像中不包含信息, 第三层图像中 包含信息, 图像叠加后, 该像素点的像素值为像素值为 (60, 60, 210);  6. M+M+C, that is, the pixel does not contain information in the first and second layer images, and the third layer image contains information. After the image is superimposed, the pixel value of the pixel is the pixel value (60, 60). , 210);
7、 M+M+M, 即, 像素点在第一、 二、 三层图像中均不包含信息, 图像 叠加后, 该像素点的像素值为 (90, 90, 90);  7. M+M+M, that is, the pixel does not contain information in the first, second, and third layers of images, and after the image is superimposed, the pixel value of the pixel is (90, 90, 90);
8、 M+B+M, 即, 像素点在第一、 三层图像中不包含信息, 第二层图像中 包含信息, 图像叠加后, 该像素点的像素值为 (60, 240, 60)。 请参阅图 2,是本发明实施例提供的多层快速响应码解码方法流程示意图, 主要包括步骤: 8. M+B+M, that is, the pixel does not contain information in the first and third layers of images, and the second layer contains information. After the image is superimposed, the pixel value of the pixel is (60, 240, 60). . 2 is a schematic flowchart of a method for decoding a multi-layer fast response code according to an embodiment of the present invention, which mainly includes the following steps:
S201 ,解析多层快速响应 QR码图像以得到所述多层 QR码图像每一层图像 的像素 RGB分量, 所述多层快速响应 QR码的图像层数为 N, 所述多层 QR码图 像为从双向可逆颜色特征库获取组数与所述多层 QR码图像的图像层数相等的 颜色特征值后将原始 QR码的图像层按照颜色顺序进行叠加得到的 QR码图像。  S201. Analyze a multi-layer fast response QR code image to obtain a pixel RGB component of each layer image of the multi-layer QR code image, where the number of image layers of the multi-layer fast response QR code is N, the multi-layer QR code image A QR code image obtained by superimposing the image layers of the original QR code in color order from the two-way reversible color feature library to obtain a color feature value equal to the number of image layers of the multi-layer QR code image.
作为本发明一个实施例, 可以对多层 QR码图像的每一个像素点进行像素 提取, 通过解析所述像素点, 所得像素点的像素 RGB分量作为所述多层 QR码 图像每一层图像在该像素点的像素 RGB分量。 由于多层 QR码图像的每一层上 均有一个探测图形, 例如, "回" 字形, 探测图形的区域被每一层图像覆盖, 其中包含信息的像素点也会将每层图像的包含信息的颜色叠加。 因此,在本实 施例中, 可以以所述探测图形为多层 QR码图像中每一层图像的采样点, 对该  As an embodiment of the present invention, pixel extraction may be performed on each pixel of the multi-layer QR code image. By parsing the pixel, the pixel RGB component of the obtained pixel is used as the image of each layer of the multi-layer QR code image. The pixel RGB component of the pixel. Since each layer of the multi-layer QR code image has a detection pattern, for example, a "back" font, the area of the detection pattern is covered by each layer image, and the pixel containing the information also contains the information of each layer image. The color overlay. Therefore, in the embodiment, the detection pattern may be a sampling point of each layer image in the multi-layer QR code image,
N  N
采样点进行采样;进一步,按照多层 QR码的像素 RGB分量的 R分量为 The sampling point is sampled; further, the R component of the RGB component of the pixel according to the multi-layer QR code is
N N k=\ N N k=\
G分量为 ^bkyk , B分量为 ∑cA 的规则, 分解出多层 QR码图像包含的图像 k=l k=l The G component is ^b k y k , and the B component is the rule of ∑c A , which decomposes the image contained in the multi-layer QR code image k=lk=l
层的层数。 The number of layers in the layer.
例如, 如果解析出 "回" 字形中的像素点的像素值为 ( 180, 180, 0)那 么, 根据前述实施例中包含信息的颜色是 A ( 180, 0, 0)和 B (0, 180, 0) 的假设, 则可以推知该图像是由两层图像叠加中的第一种混合方式所得, 即, 由第一层图像(其包含信息的颜色定义为 A ( 180, 0, 0))与第二层图像(其 包含信息的颜色定义为 B (0, 180, 0))叠加, 故该多层 QR码图像的层数为 2 层。  For example, if the pixel value of the pixel in the "back" glyph is parsed as (180, 180, 0), the colors containing information according to the foregoing embodiment are A (180, 0, 0) and B (0, 180). , the assumption of 0), it can be inferred that the image is obtained by the first mixing method of the two layers of image superposition, that is, by the first layer image (the color containing the information is defined as A (180, 0, 0)) Superimposed with the second layer image (which contains the color of the information defined as B (0, 180, 0)), the number of layers of the multi-layer QR code image is 2 layers.
如果解析出 "回" 字形中的像素点的像素值为 ( 180, 180, 180)那么, 根据前述实施例中包含信息的颜色是 A ( 180, 0, 0)、 B (0, 180, 0)和( (0, 0, 180)的假设, 则可以推知该图像是由三层图像叠加中的第一种混合方式所 得, 即, 由第一层图像(其包含信息的颜色定义为 A ( 180, 0, 0 ) )、 第二层 图像(其包含信息的颜色定义为 B ( 0, 180, 0 ) )和第三层图像(其包含信息 的颜色定义为 C ( 0, 0, 180 ) ) 叠加, 故该多层 QR码图像的层数为 3层。 If the pixel value of the pixel in the "back" glyph is parsed as (180, 180, 180), the color containing information according to the foregoing embodiment is A (180, 0, 0), B (0, 180, 0). And ((0, 0, 180) hypothesis, it can be inferred that the image is the first hybrid of the three-layer image overlay Yes, that is, by the first layer image (which contains the color of the information defined as A ( 180, 0, 0)), the second layer image (which contains the color of the information defined as B (0, 180, 0)) and The three-layer image (which contains the color of the information defined as C (0, 0, 180)) is superimposed, so the number of layers of the multi-layer QR code image is three.
N N N  N N N
此处, 2 Λ、 2 έΛ和 中 、 、 ck、 xk、 yk、 、 和 N的含 k= k=i k=l Here, 2 Λ , 2 έΛ and 中 , , c k , x k , y k , , and N have k= k=ik=l
义与前述图 1提供的实施例相同, 不做赘述。 The meanings are the same as those of the embodiment provided in FIG. 1 above, and will not be described again.
5202 , 由所述多层快速响应 QR码图像每一层图像的像素 RGB分量绘制单 层快速响应 QR码图像。  5202, drawing a single layer fast response QR code image by the pixel RGB component of each layer image of the multi-layer fast response QR code image.
即, 将从多层 QR码图像中解析出的每一层图像的像素 RGB分量存放于内 存数组中, 用于绘制单层 QR码图像。 对于单层 QR码图像中未包含码字 (即, 不包含信息内容)的像素块, 可以使用约定的颜色代替, 这种约定的颜色被每 一个绘制出的单层 QR码图像包含。  That is, the pixel RGB components of each layer of the image parsed from the multi-layer QR code image are stored in a memory array for drawing a single layer QR code image. For a block of a single-layer QR code image that does not contain a codeword (i.e., does not contain information content), a convention color may be used instead, and the agreed color is included in each of the drawn single-layer QR code images.
5203 , 对所述单层快速响应 QR码图像进行处理以解析出所述单层快速响 应 QR码图像包含的信息内容。  5203. Process the single layer fast response QR code image to parse the information content included in the single layer fast response QR code image.
这一过程包括步骤:  This process includes the steps:
S2031 , 对所述单层快速响应 QR码图像进行二值化、去噪声和形态学算法 处理, 得到二值化图像;  S2031: performing binarization, denoising, and morphological algorithm processing on the single layer fast response QR code image to obtain a binarized image;
需要说明的是,二值化图像的白色像素块(未包含信息内容或未包含码字 的像素块)是以白色或约定的颜色标定的。  It should be noted that the white pixel block of the binarized image (the pixel block not containing the information content or the codeword not included) is calibrated in white or a predetermined color.
52032,对所述二值化图像进行 QR码识別, 包括寻找探测图形、版本信息、 定位图形、 校正图形和去掩膜信息等过程;  52032, performing QR code identification on the binarized image, including searching for a detection pattern, a version information, a positioning pattern, a correction pattern, and a mask removal information;
52033 , 解析所述进行 QR码识別后的二值化图像, 以得到所述单层 QR码 图像包含的信息内容。  52033, parsing the binarized image after performing the QR code identification to obtain information content included in the single layer QR code image.
若该信息内容只包括文本信息, 则将其写入文本工具中; 若该信息包含原 有文件的格式和文件名, 将其按原文件格式写入硬盘中。 S204, 将所述从各个单层快速响应 QR码图像解析出的信息内容按照所述 颜色顺序进行连接。 If the content includes only text information, write it to the text tool; if the information contains the format and file name of the original file, write it to the hard disk in the original file format. S204. Connect the information content parsed from each single layer quick response QR code image according to the color sequence.
如附图 1示例所述, 由于在绘制多层 QR码图像时, 是按照约定的颜色顺序 叠加图像层(由计算得到的多层 QR码的像素组成),例如,计算得到的多层 QR 码, 其中一个图像层是黄色 (其像素的 RGB分量记为 (Rl , Gl , B1 ) ), 另一 个图像层是橙色 (其像素的 RGB分量记为 (R2, G2, B2 ) ), 还有一个图像层 是紫色 (其像素的 RGB分量记为 (R3, G3 , B3 ) ), 如果约定的颜色顺序是黄 色、 橙色和紫色, 则先绘制像素为 (Rl , Gl , B1 )的黄色构成多层 QR码的第 一个图像层, 在黄色构成的第一个图像层上, 叠加像素为 (R2, G2, B2 ) 的 橙色构成多层 QR码的第二个图像层, 在黄色和橙色构成的两层 QR码图像上, 叠加像素为 (R3, G3, B3 )的紫色构成三层 QR码图像。 以此为例, 假设编码 后得到的多层 QR码包含的信息内容是从 1至 3000的数字, 并进一步假设, 黄色 构成的第一个图像层包含的内容是从 1至 1000的数字, 橙色构成的第二个图像 层包含的内容是从 1001至 2000的数字,紫色构成的第三个图像层包含的内容是 从 2001至 3000的数字, 为了保证从多层 QR码解析出的信息内容和原始信息内 容的顺序一致, 则按照第一个图像层、 第二个图像层和第三个图像层的顺序将 各图像层的信息内容连接, 还原成原始的信息内容。  As illustrated in the example of FIG. 1, since the image layer (composed of the calculated multi-layer QR code) is superimposed in the agreed color order when drawing the multi-layer QR code image, for example, the calculated multi-layer QR code One of the image layers is yellow (the RGB component of the pixel is denoted as (Rl, Gl, B1)), and the other image layer is orange (the RGB component of the pixel is denoted as (R2, G2, B2)), and one The image layer is purple (the RGB components of the pixel are recorded as (R3, G3, B3)). If the agreed color order is yellow, orange, and purple, the yellow color of the (Rl, Gl, B1) pixel is first formed to form a multi-layer. The first image layer of the QR code, on the first image layer composed of yellow, the orange image of the (R2, G2, B2) superimposed pixel forms the second image layer of the multi-layer QR code, which is composed of yellow and orange. On the two-layer QR code image, the purple color of the superimposed pixels (R3, G3, B3) constitutes a three-layer QR code image. Taking this as an example, it is assumed that the multi-layer QR code obtained after encoding contains the information content from 1 to 3000, and further assumes that the first image layer composed of yellow contains the content from 1 to 1000, orange The second image layer is composed of numbers from 1001 to 2000, and the third image layer composed of purple contains numbers from 2001 to 3000, in order to ensure the information content parsed from the multilayer QR code. When the order of the original information content is the same, the information content of each image layer is connected in the order of the first image layer, the second image layer, and the third image layer, and restored to the original information content.
从附图 2示例的多层快速响应码解码方法可知,解析多层快速响应 QR码图 像以得到单层 QR码图像包含的信息内容, 将所述从各个单层 QR码图像解析出 的文本信息按照所述约定的颜色顺序进行连接。 由于所述多层 QR码图像为从 双向可逆颜色特征库获取组数与所述多层 QR码图像的图像层数相等的至少一 组颜色系数特征值后将原始 QR码的图像层按照约定的颜色顺序进行叠加得到 的 QR码图像, 因此, 多层 QR码图像满足了大信息量的传输, 从而提高传输效 率, 另一方面, 也增加了文件传输的安全性。 请参阅附图 3 , 是本发明实施例提供的多层快速响应码编码装置结构示意 图。 为了便于说明, 仅仅示出了与本发明实施例相关的部分。 附图 3示例的多 层快速响应码编码装置 03包括图像层数获取模块 301、颜色特征值获取模块 302 和叠加模块 303 , 其中: It can be seen from the multi-layer fast response code decoding method illustrated in FIG. 2 that the multi-layer fast response QR code image is parsed to obtain the information content contained in the single-layer QR code image, and the text information parsed from each single-layer QR code image is obtained. The connections are made in the agreed color order. Since the multi-layer QR code image is obtained by acquiring at least one set of color coefficient feature values equal to the number of image layers of the multi-layer QR code image from the bidirectional reversible color feature library, the image layer of the original QR code is as agreed The QR code image obtained by superimposing the color order, therefore, the multi-layer QR code image satisfies the transmission of a large amount of information, thereby improving the transmission efficiency, and on the other hand, increases the security of file transmission. Referring to FIG. 3, it is a schematic structural diagram of a multi-layer fast response code encoding apparatus according to an embodiment of the present invention. For the convenience of description, only parts related to the embodiment of the present invention are shown. The multi-layered fast response code encoding apparatus 03 illustrated in FIG. 3 includes an image layer number obtaining module 301, a color feature value obtaining module 302, and a superimposing module 303, wherein:
图像层数获取模块 301 , 用于获取多层快速响应 QR码的图像层 所述 多层快速响应 QR码是对原始快速响应 QR码进行编码后得到的多层快速响应 QR码;  The image layer number obtaining module 301 is configured to obtain an image layer of the multi-layer fast response QR code. The multi-layer fast response QR code is a multi-layer fast response QR code obtained by encoding the original fast response QR code;
在本实施例中, 原始 QR码是单层 QR码, 即 QR码图像只有一层, 所述多 层 QR码是对原始 QR码进行编码后得到的 QR码, 其图像层数 N与用户需求相 关, 例如, 与加密的文件的安全性、 多层 QR码的信息容量或者信息量传输的 大小等相关。 一般地, 用户需求越严格, 例如文件的安全性越高或多层 QR码 的信息容量越大, 多层 QR码的图像层 ¾N也应该越大。  In this embodiment, the original QR code is a single-layer QR code, that is, the QR code image has only one layer, and the multi-layer QR code is a QR code obtained by encoding the original QR code, and the number of image layers N and user requirements. Related, for example, related to the security of the encrypted file, the information capacity of the multi-layer QR code, or the size of the information volume transmission. In general, the stricter the user requirements, such as the higher the security of the file or the larger the information capacity of the multi-layer QR code, the larger the image layer 3⁄4N of the multi-layer QR code.
颜色特征值获取模块 302, 用于从双向可逆颜色特征库获取 N组颜色系数 特征值, 所述颜色系数特征值用于改变所述原始快速响应 QR码图像层的颜色 参数;  The color feature value obtaining module 302 is configured to obtain N sets of color coefficient feature values from the bidirectional reversible color feature library, where the color coefficient feature values are used to change color parameters of the original fast response QR code image layer;
本实施例所述的双向可逆颜色特征库可以事先建立。双向可逆颜色特征库 存储有颜色系数特征值, 这些颜色系数特征值用于改变所述原始 QR码的图像 层的颜色参数。 所谓原始 QR码图像层的颜色参数, 可以是原始 QR码图像层中 图像像素的 RGB分量, 即, 图像的三基色(R, G, B ) 中的红(Red, R )、 绿 ( Green, G )和蓝(Blue, B )。  The bidirectional reversible color feature library described in this embodiment can be established in advance. The two-way reversible color feature library stores color coefficient feature values that are used to change the color parameters of the image layer of the original QR code. The color parameter of the original QR code image layer may be the RGB component of the image pixel in the original QR code image layer, that is, red (Red, R), green (Green) in the three primary colors (R, G, B) of the image. G) and blue (Blue, B).
之所以称为 "双向可逆颜色特征库", 是因为本发明实施例提供的双向可 逆颜色特征库既可用于在对原始 QR码编码时计算多层 QR码图像的像素 RGB 分量, 又可用于在对多层 QR码解码时计算多层 QR码图像包含的图像层数。 像层按照颜色顺序进行叠加以得到所述多层快速响应 QR码图像。 It is called "bidirectional reversible color feature library" because the bidirectional reversible color feature library provided by the embodiment of the present invention can be used to calculate the pixel RGB component of the multi-layer QR code image when encoding the original QR code, and can be used in The number of image layers included in the multi-layer QR code image is calculated when decoding the multi-layer QR code. The image layers are superimposed in color order to obtain the multi-layer fast response QR code image.
使用获取的 N组颜色系数特征值将原始 QR码的图像层按照颜色顺序进行 叠加得到的多层 QR码图像, 其图像层数为 N。 若一幅原始 QR码图像包含的信 息容量使用 numQR表示, 则使用获取的 N组颜色系数特征值将原始 QR码的图像 层按照约定的颜色顺序进行叠加得到的多层 QR码图像, 其包含的信息容量大 约为 N x mw¾R ,可见,编码后得到的多层 QR码图像的信息容量大约是原始 QR 码图像包含的信息容量的 N倍, 而信息容量的扩大, 也意味着可以对文件进行 多重加密, 增加文件传输的安全性。 A multi-layer QR code image obtained by superimposing the image layers of the original QR code in color order using the obtained N sets of color coefficient feature values, the number of image layers being N. If an original QR code image contains an information capacity represented by num QR , a multi-layer QR code image obtained by superimposing the image layers of the original QR code in a predetermined color order using the acquired N sets of color coefficient feature values, including The information capacity is approximately N x mw3⁄4 R. It can be seen that the information capacity of the multi-layer QR code image obtained after encoding is about N times that of the original QR code image, and the expansion of the information capacity means that the file can be Perform multiple encryption to increase the security of file transfer.
在本实施例中, 所述的 "颜色顺序"可以多层快速响应码编码装置在编码 之前与多层快速响应码解码装置约定, 譬如, 在编码前约定的颜色顺序是第一 层是红色, 第二层是黄色, 第三层是紫色。 如此, 多层快速响应码解码装置在 解码时按照这个颜色顺序将解码出来的信息内容进行连接, 还原多层 QR码包 含的原始信息。  In this embodiment, the "color order" may be agreed by the multi-layer fast response code encoding device with the multi-layer fast response code decoding device before encoding, for example, the color order agreed upon before encoding is that the first layer is red. The second layer is yellow and the third layer is purple. In this way, the multi-layer fast response code decoding device connects the decoded information contents in this color order during decoding, and restores the original information contained in the multi-layer QR code.
从上述本发明实施例提供的多层快速响应码编码装置可知,由于颜色特征 值获取模块可以从双向可逆颜色特征库获取组数与多层快速响应 QR码的图像 层数 N相等的颜色系数特征值,叠加模块将原始 QR码图像层按照颜色顺序进行 叠加,得到所述多层 QR码图像,扩大了原始 QR码图像包含的信息容量。 因此, 本发明实施例提供的多层快速响应码编码装置获得的多层 QR码图像, 一方面 可以满足大信息量的传输,从而提高传输效率, 另一方面可以对文件进行多重 加密, 增加了文件传输的安全性。  According to the multi-layer fast response code encoding apparatus provided by the embodiment of the present invention, the color feature value acquiring module can obtain the color coefficient feature of the number of groups and the image layer number N of the multi-layer fast response QR code from the bidirectional reversible color feature library. The value superimposing module superimposes the original QR code image layer in color order to obtain the multi-layer QR code image, which enlarges the information capacity contained in the original QR code image. Therefore, the multi-layer QR code image obtained by the multi-layer fast response code encoding apparatus provided by the embodiment of the present invention can satisfy the transmission of a large amount of information on the one hand, thereby improving the transmission efficiency, and on the other hand, can encrypt the file multiple times, and increase the number of files. File transfer security.
需要说明的是, 以上多层快速响应码编码装置的实施方式中,各功能模块 的划分仅是举例说明, 实际应用中可以根据需要, 例如相应硬件的配置要求或 者软件的实现的便利考虑, 而将上述功能分配由不同的功能模块完成, 即将所 述多层快速响应码编码装置的内部结构划分成不同的功能模块,以完成以上描 述的全部或者部分功能。 而且, 实际应用中, 本实施例中的相应的功能模块可 以是由相应的硬件实现, 也可以由相应的硬件执行相应的软件完成, 例如, 前 述的图像层数获取模块, 可以是具有执行前述获取多层快速响应 QR码的图像 层数 N的硬件, 例如图像层数获取器, 也可以是能够执行相应计算机程序从而 完成前述功能的一般处理器或者其他硬件设备; 再如前述的叠加模块, 可以是 具有执行前述使用获取的所述 N组颜色系数特征值将所述原始 QR码的图像层 按照颜色顺序进行叠加以得到所述多层 QR码图像功能的硬件, 例如叠加器, 也可以是能够执行相应计算机程序从而完成前述功能的一般处理器或者其他 硬件设备(本说明书提供的各个实施例都可应用上述描述原则)。 It should be noted that, in the implementation manner of the foregoing multi-layer fast response code encoding apparatus, the division of each functional module is merely an example, and the actual application may be considered according to requirements, such as configuration requirements of corresponding hardware or convenience of implementation of software. The above function assignment is completed by different functional modules, that is, the internal structure of the multi-layer fast response code encoding device is divided into different functional modules to complete the above description. All or part of the functions described. Moreover, in practical applications, the corresponding functional modules in this embodiment may be implemented by corresponding hardware, or may be executed by corresponding hardware. For example, the foregoing image layer number obtaining module may have the foregoing implementation. The hardware for obtaining the image layer number N of the multi-layer fast response QR code, such as the image layer number acquirer, may also be a general processor or other hardware device capable of executing a corresponding computer program to perform the foregoing functions; It may be hardware having a function of performing the foregoing use of the N sets of color coefficient feature values to superimpose the image layers of the original QR code in a color order to obtain the function of the multi-layer QR code image, such as an overlay, or A general processor or other hardware device capable of executing a corresponding computer program to perform the aforementioned functions (the various embodiments described herein may apply the above described principles).
用户设计一个多层 QR码前, 可以知道该多层 QR码应该包含的总信息容 量, 而多层快速响应 QR码中每一层图像的最大信息容量也具有一个近似值。 因此, 附图 3示例的图像层数获取模块 301可以具体用于将多层快速响应 QR码 的总信息容量与所述多层快速响应 QR码中每一层图像的最大信息容量相除, 来获取, 即, 若两者能够整除, 则直接将两者相除所得之商作为所述多层快速 响应 QR码的图像层数 N; 若两者不能整除,则将两者相除所得之商向上取整得 到的值作为所述多层快速响应 QR码的图像层数 N, 例如, 多层 QR码的总信息 容量与所述多层 QR码中每一层图像的最大信息容量相除得到的商为 3.2 , 则将 3.2向上取整得到的 4作为多层快速响应 QR码的图像层数。  Before designing a multi-layer QR code, the user can know the total information capacity that the multi-layer QR code should contain, and the maximum information capacity of each layer of the multi-layer fast response QR code has an approximation. Therefore, the image layer number obtaining module 301 illustrated in FIG. 3 may be specifically configured to divide the total information capacity of the multi-layer fast response QR code by the maximum information capacity of each layer image in the multi-layer fast response QR code. Obtaining, that is, if the two can be divisible, the quotient obtained by dividing the two directly is used as the image layer number N of the multi-layer fast response QR code; if the two cannot be divisible, the quotient of dividing the two is obtained Rounding up the obtained value as the number of image layers N of the multi-layer fast response QR code, for example, dividing the total information capacity of the multi-layer QR code by the maximum information capacity of each layer image in the multi-layer QR code The quotient is 3.2, and the 4 obtained by rounding up 3.2 is used as the image layer number of the multi-layer fast response QR code.
在附图 3示例的多层快速响应码编码装置中, 每一组颜色特征值包含颜色 系数特征分量 、 颜色系数特征分量 和颜色系数特征分量 。 附图 3示例的 叠加模块 301可以进一步包括像素分量叠加子模块 401和图像层叠加子模块 402,如附图 4所示本发明另一实施例提供的多层快速响应码编码装置 04,其中: 像素分量叠加子模块 401 , 用于以所述每一组颜色特征值包含的颜色系数 特征分量 ak、 颜色系数特征分量 bk和颜色系数特征分量 ck作为特征系数, 将 原始 QR码的图像层中每一层图像的像素 RGB分量对应叠加以得到所述多层 QR码的像素 RGB分量; In the multi-layered fast response code encoding apparatus illustrated in FIG. 3, each set of color feature values includes a color coefficient feature component, a color coefficient feature component, and a color coefficient feature component. The superimposing module 301 of the example of FIG. 3 may further include a pixel component superposition sub-module 401 and an image layer superposition sub-module 402, as shown in FIG. 4, a multi-layer fast response code encoding apparatus 04 according to another embodiment of the present invention, wherein: a pixel component superposition sub-module 401, configured to use the color coefficient feature component a k , the color coefficient feature component b k , and the color coefficient feature component c k included in each set of color feature values as a feature coefficient, Pixel RGB components of each layer image in the image layer of the original QR code are correspondingly superimposed to obtain pixel RGB components of the multi-layer QR code;
图像层叠加子模块 402, 用于根据所述多层 QR码的像素 RGB分量,按照颜 色顺序叠加图像层以绘制所述多层 QR码图像。  The image layer superposition sub-module 402 is configured to superimpose the image layer in color order according to the pixel RGB component of the multi-layer QR code to draw the multi-layer QR code image.
即, 每一组颜色特征值使用 ( ak , bk , )表示。 像素分量叠加子模块That is, each set of color feature values is represented using ( a k , b k , ). Pixel component superposition submodule
401可以以所述每一组颜色特征值包含的颜色系数特征分量 ¾、 颜色系数特征 分量 bk和颜色系数特征分量 ck作为特征系数, 将原始 QR码的图像层中每一层 图像的像素 RGB分量对应叠加以得到所述多层 QR码的像素 RGB分量, 即, 像 素值, 其中, 对于原始 QR码图像中的白色像素块, 使用白色或者约定的颜色 标定; 然后, 图像层叠加子模块 402根据多层 QR码的像素 RGB分量绘制所述多 层 QR码图像。 在绘制所述多层 QR码图像时, 按照颜色顺序叠加图像层(由计 算得到的多层 QR码的像素组成)。 例如, 计算得到的多层 QR码, 其中一个图 像层是黄色 (其像素的 RGB分量记为 (Rl , Gl , B1 ) ), 另一个图像层是橙色 (其像素的 RGB分量记为 (R2, G2, B2 ) ), 还有一个图像层是紫色 (其像素 的 RGB分量记为 (R3 , G3, B3 ) ), 如果颜色顺序约定为黄色、 橙色和紫色, 则图像层叠加子模块 402先绘制像素为 (Rl , Gl , B1 ) 的黄色构成多层 QR码 的第一个图像层, 在黄色构成的第一个图像层上, 叠加像素为(R2, G2, B2 ) 的橙色构成多层 QR码的第二个图像层, 在黄色和橙色构成的两层 QR码图像 上, 叠加像素为 (R3, G3, B3 ) 的紫色, 从而构成三层 QR码图像。 401. The color coefficient feature component 3⁄4, the color coefficient feature component b k, and the color coefficient feature component c k included in each set of color feature values may be used as feature coefficients, and the pixels of each layer image in the image layer of the original QR code may be used. The RGB components are correspondingly superimposed to obtain pixel RGB components of the multi-layer QR code, that is, pixel values, wherein, for white pixel blocks in the original QR code image, white or agreed color calibration is used; then, the image layer overlay sub-module 402 renders the multi-layer QR code image according to pixel RGB components of the multi-layer QR code. When the multi-layer QR code image is drawn, the image layer (composed of the calculated pixels of the multi-layer QR code) is superimposed in color order. For example, the calculated multi-layer QR code, one of which is yellow (the RGB component of the pixel is denoted as (Rl, Gl, B1)), and the other image layer is orange (the RGB component of the pixel is denoted as (R2, G2, B2)), and another image layer is purple (the RGB components of the pixels are recorded as (R3, G3, B3)). If the color order is yellow, orange, and purple, the image layer overlay sub-module 402 is drawn first. The yellow color of the pixel (Rl, Gl, B1) constitutes the first image layer of the multi-layer QR code, and on the first image layer composed of yellow, the orange layer of the (R2, G2, B2) superimposed pixel constitutes a multi-layer QR The second image layer of the code, on the two-layer QR code image composed of yellow and orange, superimposes the pixels to be purple of (R3, G3, B3), thereby forming a three-layer QR code image.
附图 4示例的像素分量叠加子模块 401可以进一步包括求积单元 501和求和 单元 502, 如附图 5所示本发明另一实施例提供的多层快速响应码编码装置 05, 其中:  The pixel component superposition sub-module 401 of the example of FIG. 4 may further include an integration unit 501 and a summation unit 502, such as the multi-layer fast response code encoding apparatus 05 provided by another embodiment of the present invention, as shown in FIG.
求积单元 501 , 用于将所述每一组颜色特征值包含的颜色系数特征分量 ak、 颜色系数特征分量 和颜色系数特征分量 与原始 QR码的图像层中每一 层图像的像素 RGB分量的 R分量 、 G分量 Λ和 B分量 分別相乘, 所得乘积 分別记为^ 、 bkyk和 ckzk , 即, 与 相乘, 与)^相乘, 与 相乘, 所 得乘积分別记为¾ 、 yk和 cA。 此处, 原始 QR码的图像层中每一层图像的 像素 RGB分量的 R分量 、 G分量 Λ和 B分量 分別与一般图像的三基色 (R, G, B ) 中的红(Red, R)、 绿(Green, G)和蓝(Blue, B )含义相同。 对于 原始 QR码中的白色区域, 其 RGB分量既可以是组成白色的像素的 RGB分量, 又可以是约定的其他颜色的像素的 RGB分量,本发明实施例可以不做限定。需 要说明的是, 若原始 QR码的图像层的层数比从双向可逆颜色特征库获取的颜 色系数特征值的组数少,则少出的原始 QR码的图像层其像素 RGB分量的 R分量 、 G分量 ^和 B分量 均视为 0。 例如, 从双向可逆颜色特征库获取三组颜色 系数特征值记为 ( A, bx, cx ), ( a2, b2, c2 )和( α3 , b3 , c3 ), 若原始 QR 码的图像层为两层, 其像素 RGB分量的 R分量 、 G分量 Λ和 B分量 ¾分別记 为 Jx , )和( , y2, ), 则原始 QR码少出的一个图像层的 R分量 、 G分量 ^和 B分量 , 即 ( , y3 , ), 可以将其视为 (0, 0, 0)。 求和单元 502, 用于对所述每一组颜色特征值包含的颜色系数特征分量 ak、 颜色系数特征分量 和颜色系数特征分量 与原始 QR码的图像层中每一 层图像的像素 RGB分量的 R分量 、 G分量 ^和 B分量 分別相乘所得乘积 The quadrature unit 501 is configured to: each of the color coefficient feature components a k , the color coefficient feature component, and the color coefficient feature component included in each set of color feature values and each of the image layers of the original QR code The R component, the G component Λ and the B component of the pixel RGB component of the layer image are respectively multiplied, and the obtained products are respectively denoted as ^, b k y k and c k z k , that is, multiplied by , multiplied by ^, and Multiply, the resulting products are recorded as 3⁄4, y k, and c A , respectively . Here, the R component, the G component Λ, and the B component of the pixel RGB component of each layer image in the image layer of the original QR code are respectively red (Red, R) among the three primary colors (R, G, B) of the general image. , Green (G) and Blue (Blue, B) have the same meaning. For the white area in the original QR code, the RGB component may be the RGB component of the pixel constituting the white color, and may be the RGB component of the pixel of the other color of the agreement, which may not be limited in the embodiment of the present invention. It should be noted that if the number of layers of the image layer of the original QR code is smaller than the number of sets of the color coefficient feature values obtained from the bidirectional reversible color feature library, the R component of the pixel layer RGB component of the image layer of the original QR code is reduced. The G component ^ and the B component are regarded as 0. For example, obtaining three sets of color coefficient eigenvalues from the bidirectional reversible color feature library are denoted as (A, b x , c x ), ( a 2 , b 2 , c 2 ) and ( α 3 , b 3 , c 3 ), if The image layer of the original QR code is two layers, and the R component, the G component Λ, and the B component 3⁄4 of the pixel RGB component are respectively recorded as J x , ) and ( , y 2 , ), and then an image layer having less original QR code. The R component, the G component ^, and the B component, that is, ( , y 3 , ), can be regarded as (0, 0, 0). a summation unit 502, configured to: the color coefficient feature component a k , the color coefficient feature component, and the color coefficient feature component included in each set of color feature values and the pixel RGB component of each layer image in the image layer of the original QR code The product of the R component, the G component ^, and the B component respectively multiplied
N N N N  N N N N
¾ 、 ^和^¾分別求和, 得到 、∑ Λ和 , 以所述 、 3⁄4, ^, and ^3⁄4 are summed separately to obtain , ∑ Λ , and
1 k=l k=l k=l  1 k=l k=l k=l
N N N N
和∑ 分別作为所述多层 QR码的像素 RGB分量的 R分量、 G分量和 B k=l k=l  And ∑ respectively as the R component, G component and B k=l k=l of the pixel RGB component of the multi-layer QR code
分量。 以从双向可逆颜色特征库获取三组颜色系数特征值(记为( A, bx, ), ( a2, b2, c2 )和( α3 , b3, c3 ))为例, 原始 QR码的图像层(假设也为三层 ), 其像素 RGB分量的 R分量 、 G分量 ^和 B分量 分別记为( jx , )、( x2, y2, ) 和( , y3 , ), 则得到的多层 QR码的像素 RGB分量的 R分量为 αλ y + c ζ1 , G分量为 α2 x2+b2 y2 + c2 ζ2 , Β分量为 α3 x3+b3 y3 + c3 ζ3; 特另, J 地, 若原始 QR码的图像层只有两层, 其像素 RGB分量的 R分量 、 G分量 ^和 B分量 ¾分別记为 ( , jx, )和( , y2, ), 按照前述规定, 其( , y3 , )视为 0,则得到的多层 QR码的像素 RGB分量的 R分量为 + y1 + Cl Ζι , G分量为 <¾ + b2 y2 + c2 , B分量为 0 ( =<¾ ¾+b3 y3 +c3 = <¾x 0 +b3x 0 +c3x 0)。 Component. Taking three sets of color coefficient eigenvalues (denoted as (A, b x , ), ( a 2 , b 2 , c 2 ) and ( α 3 , b 3 , c 3 )) from the bidirectional reversible color feature library as an example, The image layer of the original QR code (assumed also three layers), the R component, the G component ^ and the B component of the pixel RGB component are denoted as ( j x , ), ( x 2 , y 2 , ) and ( , y 3 , respectively , ), the R component of the RGB component of the multi-layer QR code obtained is α λ y + c ζ 1 , G component is α 2 x 2 + b 2 y 2 + c 2 ζ 2 , Β component is α 3 x 3 + b 3 y 3 + c 3 ζ 3 ; Specially , J ground, If the image layer of the original QR code has only two layers, the R component, the G component ^ and the B component 3⁄4 of the pixel RGB component are respectively denoted as ( , j x , ) and ( , y 2 , ), according to the foregoing provisions, y 3 , ) is regarded as 0, and the R component of the pixel RGB component of the obtained multi-layer QR code is + y 1 + Cl Ζι , the G component is < 3⁄4 + b 2 y 2 + c 2 , and the B component is 0 (= < 3⁄4 3⁄4 +b 3 y 3 +c 3 = <3⁄4x 0 +b 3 x 0 +c 3 x 0).
请参阅附图 6, 是本发明实施例提供的多层快速响应码解码装置结构示意 图。 为了便于说明, 仅仅示出了与本发明实施例相关的部分。 附图 6示例的多 层快速响应码解码装置 06包括像素分量解析模块 601、 图像绘制模块 602、 图像 处理模块 603和连接模块 604, 其中:  Referring to FIG. 6, FIG. 6 is a schematic structural diagram of a multi-layer fast response code decoding apparatus according to an embodiment of the present invention. For the convenience of description, only parts related to the embodiment of the present invention are shown. The multi-layer fast response code decoding device 06 illustrated in Fig. 6 includes a pixel component analysis module 601, an image rendering module 602, an image processing module 603, and a connection module 604, wherein:
像素分量解析模块 601 ,用于解析多层快速响应 QR码图像以得到所述多层 QR码图像每一层图像的像素 RGB分量,所述多层快速响应 QR码的图像层数为 N, 所述多层 QR码图像为从双向可逆颜色特征库获取 N组颜色特征值后将原始 快速响应 QR码的图像层按照约定的颜色顺序进行叠加得到的多层快速响应 QR码图像;  a pixel component parsing module 601, configured to parse a multi-layer fast response QR code image to obtain a pixel RGB component of each layer image of the multi-layer QR code image, where the number of image layers of the multi-layer fast response QR code is N, The multi-layer QR code image is a multi-layer fast response QR code image obtained by acquiring N sets of color feature values from the bidirectional reversible color feature library and superimposing the image layers of the original quick response QR code in accordance with a predetermined color sequence;
图像绘制模块 602,用于由所述多层快速响应 QR码图像每一层图像的像素 RGB分量绘制单层 QR码图像, 即, 将从多层 QR码图像中解析出的每一层图像 的像素 RGB分量存放于内存数组中, 用于绘制单层 QR码图像。 对于单层 QR码 图像中未包含码字(即, 不包含信息内容)的像素块, 可以使用约定的颜色代 替, 这种约定的颜色被每一个绘制出的单层 QR码图像包含;  An image drawing module 602, configured to draw a single-layer QR code image by pixel RGB components of each layer image of the multi-layer fast response QR code image, that is, each layer image that is parsed from the multi-layer QR code image The pixel RGB components are stored in a memory array for drawing a single layer QR code image. For a pixel block of a single-layer QR code image that does not contain a codeword (ie, does not contain information content), a convention color may be used instead, and the agreed color is included in each of the single-layer QR code images drawn;
图像处理模块 603,用于对所述单层快速响应 QR码图像进行处理以解析出 所述单层快速响应 QR码图像包含的信息内容;  The image processing module 603 is configured to process the single layer quick response QR code image to parse the information content included in the single layer fast response QR code image;
连接模块 604,用于将所述从各个单层快速响应 QR码图像解析出的信息内 容按照所述约定的颜色顺序进行连接。 如附图 1示例所述, 由于在绘制多层 QR码图像时, 是按照约定的颜色顺序 叠加图像层(由计算得到的多层 QR码的像素组成),例如,计算得到的多层 QR 码, 其中一个图像层是黄色 (其像素的 RGB分量记为 (Rl , Gl , B1 ) ), 另一 个图像层是橙色 (其像素的 RGB分量记为 (R2, G2, B2 ) ), 还有一个图像层 是紫色 (其像素的 RGB分量记为 (R3, G3 , B3 ) ), 如果约定的颜色顺序是黄 色、 橙色和紫色, 则先绘制像素为 (Rl , Gl , B1 )的黄色构成多层 QR码的第 一个图像层, 在黄色构成的第一个图像层上, 叠加像素为 (R2, G2, B2 ) 的 橙色构成多层 QR码的第二个图像层, 在黄的和橙色构成的两层 QR码图像上, 叠加像素为 (R3, G3, B3 )的紫色构成三层 QR码图像。 以此为例, 假设编码 后得到的多层 QR码包含的信息内容是从 1至 3000的数字, 并进一步假设, 黄色 构成的第一个图像层包含的内容是从 1至 1000的数字, 橙色构成的第二个图像 层包含的内容是从 1001至 2000的数字,紫色构成的第三个图像层包含的内容是 从 2001至 3000的数字, 为了保证从多层 QR码解析出的信息内容和原始信息内 容的顺序一致, 则连接模块 604按照第一个图像层、 第二个图像层和第三个图 像层的顺序将各图像层的信息内容连接, 还原成原始的信息内容。 The connection module 604 is configured to connect the information content parsed from each single-layer quick response QR code image according to the agreed color order. As illustrated in the example of FIG. 1, since the image layer (composed of the calculated multi-layer QR code) is superimposed in the agreed color order when drawing the multi-layer QR code image, for example, the calculated multi-layer QR code One of the image layers is yellow (the RGB component of the pixel is denoted as (Rl, Gl, B1)), and the other image layer is orange (the RGB component of the pixel is denoted as (R2, G2, B2)), and one The image layer is purple (the RGB components of the pixel are recorded as (R3, G3, B3)). If the agreed color order is yellow, orange, and purple, the yellow color of the (Rl, Gl, B1) pixel is first formed to form a multi-layer. The first image layer of the QR code, on the first image layer composed of yellow, the orange image of the (R2, G2, B2) superimposed pixel constitutes the second image layer of the multi-layer QR code, which is composed of yellow and orange. On the two-layer QR code image, the purple color of the superimposed pixels (R3, G3, B3) constitutes a three-layer QR code image. Taking this as an example, it is assumed that the multi-layer QR code obtained after encoding contains the information content from 1 to 3000, and further assumes that the first image layer composed of yellow contains the content from 1 to 1000, orange The second image layer is composed of numbers from 1001 to 2000, and the third image layer composed of purple contains numbers from 2001 to 3000, in order to ensure the information content parsed from the multilayer QR code. If the order of the original information contents is the same, the connection module 604 connects the information contents of the image layers in the order of the first image layer, the second image layer, and the third image layer, and restores the original information content.
需要说明的是, 以上多层快速响应码解码装置的实施方式中,各功能模块 的划分仅是举例说明, 实际应用中可以根据需要, 例如相应硬件的配置要求或 者软件的实现的便利考虑, 而将上述功能分配由不同的功能模块完成, 即将所 述多层快速响应码解码装置的内部结构划分成不同的功能模块,以完成以上描 述的全部或者部分功能。 而且, 实际应用中, 本实施例中的相应的功能模块可 以是由相应的硬件实现, 也可以由相应的硬件执行相应的软件完成, 例如, 前 述的像素分量解析模块, 可以是具有执行前述解析多层快速响应 QR码图像以 得到所述多层 QR码图像每一层图像的像素 RGB分量的硬件, 例如像素分量解 析器,也可以是能够执行相应计算机程序从而完成前述功能的一般处理器或者 其他硬件设备; 再如前述的图像绘制模块, 可以是具有执行前述由所述多层 QR码图像每一层图像的像素 RGB分量绘制单层 QR码图像功能的硬件,例如图 像绘制器,也可以是能够执行相应计算机程序从而完成前述功能的一般处理器 或者其他硬件设备(本说明书提供的各个实施例都可应用上述描述原则)。 It should be noted that, in the implementation manner of the foregoing multi-layer fast response code decoding device, the division of each functional module is merely an example, and the actual application may be considered according to requirements, such as configuration requirements of corresponding hardware or convenience of implementation of software. The above function assignment is performed by different functional modules, that is, the internal structure of the multi-layer fast response code decoding device is divided into different functional modules to complete all or part of the functions described above. Moreover, in practical applications, the corresponding functional modules in this embodiment may be implemented by corresponding hardware, or may be executed by corresponding hardware. For example, the foregoing pixel component parsing module may have the foregoing parsing. a multi-layer fast response QR code image to obtain hardware of pixel RGB components of each layer image of the multi-layer QR code image, such as a pixel component parser, or a general processor capable of executing a corresponding computer program to perform the aforementioned functions or Other hardware devices; and the image drawing module as described above may be hardware having the function of performing the foregoing drawing of a single-layer QR code image by the pixel RGB components of each layer of the multi-layer QR code image, such as an image renderer, or A general processor or other hardware device capable of executing a corresponding computer program to perform the aforementioned functions (the various embodiments described herein may apply the above described principles).
附图 6示例的像素分量解析模块 601可以进一步包括像素求取单元 701和解 析单元 702 , 如附图 7所示本发明另一实施例提供的多层快速响应码解码装置 07 , 其中:  The pixel component parsing module 601 of the example of FIG. 6 may further include a pixel obtaining unit 701 and a parsing unit 702, such as the multi-layer fast response code decoding apparatus 07 provided by another embodiment of the present invention, as shown in FIG.
像素求取单元 701 , 用于求取所述探测图形的像素点的像素值。 由于多层 QR码图像的每一层上均有一个探测图形, 例如, "回" 字形, 探测图形的区域 被每一层图像覆盖,其中包含信息的像素点也会将每层图像的包含信息的颜色 叠加。 因此, 在本实施例中, 像素求取单元 701可以对所述探测图形进行采样, 求取所述探测图形像素点的像素值。例如,通过采样获取探测图形覆盖的区域 的像素点, 使用求均值或均方差的方法, 求出探测图形像素点的近似像素值; 解析单元 702 ,用于根据像素求取单元 701求取的所述探测图形的像素点的 像素值, 解析所述多层 QR码图像的层数及每一层的像素值, 即, 按照多层 QR  The pixel obtaining unit 701 is configured to obtain a pixel value of a pixel of the detection pattern. Since each layer of the multi-layer QR code image has a detection pattern, for example, a "back" font, the area of the detection pattern is covered by each layer image, and the pixel containing the information also contains the information of each layer image. The color overlay. Therefore, in this embodiment, the pixel obtaining unit 701 can sample the detection pattern to obtain a pixel value of the pixel of the detection pattern. For example, the pixel points of the area covered by the detection pattern are obtained by sampling, and the approximate pixel value of the pixel of the detection pattern is obtained by using the method of averaging or mean square error; the parsing unit 702 is configured to obtain the position according to the pixel obtaining unit 701. Depicting the pixel value of the pixel of the detection pattern, parsing the number of layers of the multi-layer QR code image and the pixel value of each layer, that is, according to the multi-layer QR
N N N N NN
码的像素 RGB分量的 R分量为 γαΛ , G分量为 ykyk , B分量为 ∑ckzk的 k=l k=l k=l 规则, 分解出多层 QR码图像 έ含的图像层的层数及每一层的像素值, 此The R component of the RGB component of the pixel of the code is γ αΛ , the G component is y k y k , and the B component is the k = lk=lk=l rule of ∑c k z k , which decomposes the image layer contained in the multilayer QR code image Number of layers and pixel values for each layer, this
Ν Ν Ν Ν Ν Ν
处, 和 中¾、 bk、 ck、 xk、 yk , ¾、 和 N的含义与前 k=l k=l k=l Where, and the meanings of 3⁄4 , b k , c k , x k , y k , 3⁄4, and N are the same as before k=lk=lk=l
述图 1提供的实施例相同, 不做赘述。 The embodiment provided in FIG. 1 is the same and will not be described again.
附图 6或附图 7示例的图像处理模块 603可以进一步包括二值化处理单元 The image processing module 603 illustrated in FIG. 6 or FIG. 7 may further include a binarization processing unit.
801、识別单元 802和信息解析单元 803 ,如附图 8所示本发明另一实施例提供的 多层快速响应码解码装置 08 , 其中: 801, the identification unit 802 and the information parsing unit 803, as shown in FIG. 8, a multi-layer fast response code decoding apparatus 08 according to another embodiment of the present invention, wherein:
二值化处理单元 801 , 用于对所述单层 QR码图像进行二值化、 去噪声和形 态学算法处理, 得到二值化图像; 在本发明实施例中,二值化图像的白色像素块(未包含信息内容或未包含 码字的像素块)是以白色或约定的颜色标定的。 a binarization processing unit 801, configured to perform binarization, denoising, and morphological algorithm processing on the single-layer QR code image to obtain a binarized image; In an embodiment of the invention, a white pixel block (a pixel block that does not contain information content or a codeword that does not contain a codeword) of the binarized image is calibrated in white or a convention color.
识別单元 802,用于对所述二值化图像进行 QR码识別,包括寻找探测图形、 版本信息、 定位图形、 校正图形和去掩膜信息等过程;  The identifying unit 802 is configured to perform QR code identification on the binarized image, including searching for a detection pattern, a version information, a positioning pattern, a correction pattern, and a demasking information;
信息解析单元 803 , 用于解析所述进行 QR码识別后的二值化图像, 以得到 所述单层 QR码图像包含的信息内容, 若该信息内容只包括文本信息, 则将其 写入文本工具中; 若该信息包含原有文件的格式和文件名,将其按原文件格式 写入硬盘中。  The information parsing unit 803 is configured to parse the binarized image after the QR code identification to obtain the information content included in the single-layer QR code image, and if the information content only includes the text information, write the information content In the text tool; if the information contains the format and file name of the original file, write it to the hard disk in the original file format.
需要说明的是, 上述装置各模块 /单元之间的信息交互、 执行过程等内容, 由于与本发明方法实施例基于同一构思,其带来的技术效果与本发明方法实施 例相同, 具体内容可参见本发明方法实施例中的叙述, 此处不再赘述。  It should be noted that the information interaction, the execution process, and the like between the modules/units of the foregoing device are the same as the embodiment of the method of the present invention. Reference is made to the description in the method embodiment of the present invention, and details are not described herein again.
本领域普通技术人员可以理解上述实施例的各种方法中的全部或部分步 骤是可以通过程序来指令相关的硬件来完成,比如以下各种方法的一种或多种 或全部:  One of ordinary skill in the art will appreciate that all or a portion of the various methods of the above-described embodiments can be performed by a program to instruct the associated hardware, such as one or more or all of the following various methods:
方法一: 获取多层快速响应 QR码的图像层数 N, 所述多层快速响应 QR码 是对原始快速响应 QR码进行编码后得到的快速响应 QR码; 从双向可逆颜色特 征库获取 N组颜色系数特征值, 所述颜色系数特征值用于改变所述原始快速响 应 QR码图像层的颜色参数;使用获取的所述 N组颜色系数特征值将所述原始快 速响应 QR码图像层按照颜色顺序进行叠加以得到所述多层快速响应 QR码图 像。  Method 1: Obtain a number of image layers N of a multi-layer fast response QR code, the multi-layer fast response QR code is a fast response QR code obtained by encoding the original fast response QR code; and obtaining N groups from the two-way reversible color feature database a color coefficient feature value, the color coefficient feature value is used to change a color parameter of the original fast response QR code image layer; and the original fast response QR code image layer is colored according to the obtained N sets of color coefficient feature values The superposition is sequentially performed to obtain the multi-layer fast response QR code image.
方法二: 解析多层快速响应 QR码图像以得到所述多层快速响应 QR码图像 每一层图像的像素 RGB分量,所述多层快速响应 QR码的图像层数为 N,所述多 层快速响应 QR码图像为从双向可逆颜色特征库获取 N组颜色系数特征值后将 原始快速响应 QR码的图像层按照颜色顺序进行叠加得到的 QR码图像; 由所述 多层快速响应 QR码图像每一层图像的像素 RGB分量绘制单层快速响应 QR码 图像; 对所述单层快速响应 QR码图像进行处理以解析出所述单层快速响应 QR 码图像包含的信息内容; 将所述从各个单层快速响应 QR码图像解析出的信息 内容按照所述颜色顺序进行连接。 Method 2: Parsing a multi-layer fast response QR code image to obtain pixel RGB components of each layer of the multi-layer fast response QR code image, the number of image layers of the multi-layer fast response QR code being N, the multi-layer The quick response QR code image is a QR code image obtained by superimposing the image layers of the original quick response QR code in a color order after acquiring N sets of color coefficient feature values from the bidirectional reversible color feature library; Multi-layer fast response QR code image pixel RGB component of each layer image to draw a single layer fast response QR code image; processing the single layer fast response QR code image to parse out the single layer fast response QR code image Information content; The information content parsed from each single layer quick response QR code image is connected in the color order.
该程序可以存储于一计算机可读存储介质中,存储介质可以包括: 只读存 储器(ROM, Read Only Memory ), 随机存取存储器(RAM, Random Access Memory )、 磁盘或光盘等。  The program may be stored in a computer readable storage medium, and the storage medium may include: a Read Only Memory (ROM), a Random Access Memory (RAM), a magnetic disk or an optical disk, and the like.
以上对本发明实施例提供的多层快速响应码编码、解码方法和编码、解码 了阐述, 以上实施例的说明只是用于帮助理解本发明的方法及其核心思想; 同 时, 对于本领域的一般技术人员, 依据本发明的思想, 在具体实施方式及应用 范围上均会有改变之处,综上所述,本说明书内容不应理解为对本发明的限制。  The above description of the multi-layer fast response code encoding and decoding method and the encoding and decoding provided by the embodiments of the present invention are provided. The description of the above embodiments is only for helping to understand the method and the core idea of the present invention. Meanwhile, the general technology in the field In the following, the description of the present invention should not be construed as limiting the scope of the present invention.

Claims

权 利 要 求 Rights request
1、 一种多层快速响应码编码方法, 其特征在于, 所述方法包括: 获取多层快速响应 QR码的图像层数 N, 所述多层快速响应 QR码是对原始 快速响应 QR码进行编码后得到的多层快速响应 QR码;  A multi-layer fast response code encoding method, the method comprising: acquiring a number of image layers N of a multi-layer fast response QR code, wherein the multi-layer fast response QR code is for performing an original fast response QR code Multi-layer fast response QR code obtained after encoding;
从双向可逆颜色特征库获取 N组颜色系数特征值, 所述颜色系数特征值用 于改变所述原始快速响应 QR码图像层的颜色参数;  Obtaining N sets of color coefficient feature values from the bidirectional reversible color feature library, wherein the color coefficient feature values are used to change color parameters of the original fast response QR code image layer;
使用获取的所述 N组颜色系数特征值将所述原始快速响应 QR码图像层按 照颜色顺序进行叠加以得到所述多层快速响应 QR码图像。  The original quick response QR code image layers are superimposed in color order using the obtained N sets of color coefficient feature values to obtain the multi-layer fast response QR code image.
2、 如权利要求 1所述的方法, 其特征在于, 所述获取多层快速响应快速响 应 QR码的图像层 ¾N包括:  2. The method according to claim 1, wherein the acquiring the image layer 3⁄4N of the multi-layer fast response fast response QR code comprises:
将多层快速响应快速响应 QR码的总信息容量与所述多层快速响应快速响 应 QR码中每一层图像的最大信息容量相除, 所得之商或所得之商向上取整得 到的值作为所述多层快速响应快速响应 QR码的图像层 ¾N。  Dividing the total information capacity of the multi-layer fast response fast response QR code from the maximum information capacity of each layer image in the multi-layer fast response fast response QR code, and obtaining the value obtained by rounding up the obtained quotient or the obtained quotient as The multi-layer fast response quickly responds to the image layer 3⁄4N of the QR code.
3、 如权利要求 1或 2所述的方法, 其特征在于, 所述每一组颜色系数特征 值包含颜色系数特征分量 、 颜色系数特征分量 bk和颜色系数特征分量 ck ; 所述使用所述的获取 N组颜色系数特征值将所述原始快速响应 QR码的图 像层按照颜色顺序进行叠加以得到所述多层快速响应 QR码图像包括: 3. The method according to claim 1 or 2, wherein each of the sets of color coefficient feature values comprises a color coefficient feature component, a color coefficient feature component bk, and a color coefficient feature component ck ; Acquiring N sets of color coefficient feature values to superimpose the image layers of the original quick response QR code in color order to obtain the multi-layer fast response QR code image includes:
以所述每一组颜色特征值包含的颜色系数特征分量 、颜色系数特征分量 bk和颜色系数特征分量 ck作为特征系数, 将原始快速响应 QR码的图像层中每 一层图像的像素 RGB分量对应叠加以得到所述多层快速响应 QR码的像素 RGB 分量; The color coefficient feature component, the color coefficient feature component b k and the color coefficient feature component c k included in each set of color feature values are used as feature coefficients, and the pixel RGB of each layer image in the image layer of the original fast response QR code is The components are correspondingly superimposed to obtain pixel RGB components of the multi-layer fast response QR code;
根据所述多层快速响应 QR码的像素 RGB分量, 按照颜色顺序叠加图像层 以绘制所述多层快速响应 QR码图像。  The image layer is superimposed in color order to render the multi-layer fast response QR code image in accordance with the pixel RGB components of the multi-layer fast response QR code.
4、 如权利要求 3所述的方法, 其特征在于, 所述将原始快速响应 QR码的 图像层中每一层图像的像素的 RGB分量对应叠加以得到所述多层快速响应 QR 码的像素 RGB分量包括: 4. The method of claim 3, wherein said initial quick response QR code The RGB components of the pixels of each layer image in the image layer are correspondingly superimposed to obtain the pixel RGB components of the multi-layer fast response QR code including:
将所述每一组颜色系数特征值包含的颜色系数特征分量 ¾、 颜色系数特 征分量 bk和颜色系数特征分量 ck与原始快速响应 QR码的图像层中每一层图像 的像素 RGB分量的 R分量 、 G分量 ^和 B分量 分別相乘, 所得乘积分別记 为¾ 、 yk和 ckzk The color coefficient feature component 226, the color coefficient feature component b k and the color coefficient feature component c k included in each set of color coefficient feature values and the pixel RGB component of each layer image in the image layer of the original fast response QR code The R component, the G component ^ and the B component are respectively multiplied, and the obtained products are denoted as 3⁄4 , y k and c k z k , respectively.
对所述每一组颜色系数特征值包含的颜色系数特征分量 、 颜色系数特 征分量 和颜色系数特征分量 ck与原始 QR码的图像层中每一层图像的像素 RGB分量的 R分量 、 G分量 Λ和 B分量 ¾分別相乘所得乘积% 、 bky ckzk The color component characteristic component, the color coefficient feature component, and the color coefficient feature component c k included in each set of color coefficient feature values and the R component and the G component of the pixel RGB component of each layer image in the image layer of the original QR code The product % and b k yc k z k obtained by multiplying Λ and B components by 3⁄4 respectively
N N N N N N  N N N N N N
分別求和,得到 Λkyk和 Χ¾¾ , 以所述∑¾ 、∑bkyk和∑cA分 k= k=i k=l k=l k=l k=l 別作为所述多层 QR码的像素 RGB分量的 R分量、 G分量和 B分量。 They were summed to give Λ, k y k and Χ ¾¾, to the Σ ¾, Σb k y k and Σc A sub k = k = ik = lk = lk = lk = l respectively as the multilayer QR The R component, the G component, and the B component of the pixel RGB component of the code.
5、 一种多层快速响应码解码方法, 其特征在于, 所述方法包括: 解析多层快速响应 QR码图像以得到所述多层快速响应 QR码图像每一层 图像的像素 RGB分量,所述多层快速响应 QR码的图像层数为 N,所述多层快速 响应 QR码图像为从双向可逆颜色特征库获取 N组颜色系数特征值后将原始快 速响应 QR码的图像层按照颜色顺序进行叠加得到的多层快速响应 QR码图像; 由所述多层快速响应 QR码图像每一层图像的像素 RGB分量绘制单层快速 响应 QR码图像;  A multi-layer fast response code decoding method, the method comprising: parsing a multi-layer fast response QR code image to obtain a pixel RGB component of each layer of the multi-layer fast response QR code image, The number of image layers of the multi-layer fast response QR code is N, and the multi-layer fast response QR code image is obtained by acquiring N sets of color coefficient feature values from the bidirectional reversible color feature library, and then the image layer of the original fast response QR code is in color order. Performing a multi-layer fast response QR code image obtained by superposition; drawing a single-layer fast response QR code image from pixel RGB components of each layer image of the multi-layer fast response QR code image;
对所述单层快速响应 QR码图像进行处理以解析出所述单层快速响应 QR 码图像包含的信息内容;  Processing the single layer quick response QR code image to parse the information content included in the single layer fast response QR code image;
将所述从各个单层快速响应 QR码图像解析出的信息内容按照所述颜色顺 序进行连接。  The information content parsed from each of the single layer quick response QR code images is connected in the color sequence.
6、 如权利要求 5所述的方法, 其特征在于, 所述对所述单层快速响应 QR 码图像进行处理以解析出所述单层快速响应 QR码图像包含的文本信息包括: 对所述单层快速响应 QR码图像进行二值化、 去噪声和形态学算法处理, 得到二值化图像; The method of claim 5, wherein the processing the single layer quick response QR code image to parse the text information included in the single layer quick response QR code image comprises: Performing binarization, denoising, and morphological algorithm processing on the single layer fast response QR code image to obtain a binarized image;
对所述二值化图像进行快速响应 QR码识別;  Performing a quick response on the binarized image, QR code recognition;
解析所述进行快速响应 QR码识別后的二值化图像, 以得到所述单层快速 响应 QR码图像包含的信息内容。  And parsing the binarized image after performing the fast response QR code identification to obtain the information content included in the single layer fast response QR code image.
7、 一种多层快速响应码编码装置, 其特征在于, 所述装置包括: 图像层数获取模块, 用于获取多层快速响应快速响应 QR码的图像层数 N, 所述多层快速响应快速响应 QR码是对原始快速响应 QR码进行编码后得到的 多层快速响应 QR码;  A multi-layer fast response code encoding apparatus, wherein the apparatus comprises: an image layer number acquiring module, configured to acquire a multi-layer fast response fast response QR code image layer number N, the multi-layer fast response The quick response QR code is a multi-layer fast response QR code obtained by encoding the original fast response QR code;
颜色特征值获取模块, 用于从双向可逆颜色特征库获取 N组颜色系数特征 值,所述颜色系数特征值用于改变所述原始快速响应 QR码图像层的颜色参数; 叠加模块, 用于使用所述获取的 N组颜色系数特征值将所述原始快速响应 a color feature value obtaining module, configured to acquire N sets of color coefficient feature values from the bidirectional reversible color feature library, wherein the color coefficient feature values are used to change color parameters of the original fast response QR code image layer; The acquired N sets of color coefficient feature values will be the original fast response
QR码的图像层按照颜色顺序进行叠加以得到所述多层快速响应 QR码图像。 The image layers of the QR code are superimposed in color order to obtain the multi-layer fast response QR code image.
8、 如权利要求 7所述的装置, 其特征在于, 所述图像层数获取模块用于获 取多层快速响应快速响应 QR码的图像层数 N时包括:将多层快速响应快速响应 8. The apparatus according to claim 7, wherein the image layer number acquisition module is configured to obtain a multi-layer fast response fast response QR code image layer number N, including: multi-layer fast response fast response
QR码的总信息容量与所述多层快速响应快速响应 QR码中每一层图像的最大 信息容量相除,所得之商或所得之商向上取整得到的值作为所述多层快速响应 快速响应 QR码的图像层 ¾N。 The total information capacity of the QR code is divided by the maximum information capacity of each layer of the multi-layer fast response fast response QR code, and the resulting quotient or the resulting quotient is rounded up to obtain the multi-layer fast response fast. The image layer 3⁄4N in response to the QR code.
9、 如权利要求 7或 8所述的装置, 其特征在于, 所述每一组颜色系数特征 值包含颜色系数特征分量 ak、 颜色系数特征分量 bk和颜色系数特征分量 ck ; 所述叠加模块包括: 9. The apparatus according to claim 7 or 8, wherein each of the sets of color coefficient feature values comprises a color coefficient feature component a k , a color coefficient feature component b k , and a color coefficient feature component c k ; The overlay module includes:
像素分量叠加子模块,用于以所述每一组颜色系数特征值包含的颜色系数 特征分量 ak、 颜色系数特征分量 bk和颜色系数特征分量 ck作为特征系数, 将 原始快速响应 QR码的图像层中每一层图像的像素 RGB分量对应叠加以得到所 述多层快速响应 QR码的像素 RGB分量; a pixel component superposition sub-module, configured to use the color coefficient feature component a k , the color coefficient feature component b k , and the color coefficient feature component c k included in each set of color coefficient feature values as a feature coefficient, and the original fast response QR code The pixel RGB components of each layer of the image layer are correspondingly superimposed to obtain a pixel RGB component of a multi-layer fast response QR code;
图像层叠加子模块, 用于根据所述多层快速响应 QR码的像素 RGB分量, 按照颜色顺序叠加图像层以绘制所述多层快速响应 QR码图像。  And an image layer superposition sub-module, configured to superimpose the image layer in color order according to the pixel RGB component of the multi-layer fast response QR code to draw the multi-layer fast response QR code image.
10、 如权利要求 9所述的装置, 其特征在于, 所述像素分量叠加子模块包 括:  10. The apparatus according to claim 9, wherein the pixel component superposition sub-module comprises:
求积单元, 用于将所述每一组颜色系数特征值包含的颜色特征分量 ¾、 颜色系数特征分量 bk和颜色系数特征分量 ck与原始快速响应 QR码的图像层中 每一层图像的像素 RGB分量的 R分量 、 G分量 ^和 B分量 分別相乘, 所得 乘积分別记为 akxk、 bk yk和 ckzkAn quadrature unit, configured to use the color feature component 3⁄4, the color coefficient feature component b k, and the color coefficient feature component c k included in each set of color coefficient feature values and each layer image in the image layer of the original fast response QR code The R component, the G component ^ and the B component of the pixel RGB component are respectively multiplied, and the obtained products are denoted as a k x k , b k y k and c k z k , respectively ;
求和单元, 用于对所述每一组颜色特征值包含的颜色系数特征分量 、 颜色系数特征分量 bk和颜色系数特征分量 ck与原始 QR码的图像层中每一层图 像的像素 RGB分量的 R分量 、 G分量 yk和 B分量 ¾分別相乘所得乘积 akxka summation unit, configured to, for each of the set of color feature values, a color coefficient feature component, a color coefficient feature component bk, and a color coefficient feature component ck and a pixel RGB of each layer image in the image layer of the original QR code The product of the component R component, the G component y k and the B component 3⁄4 are multiplied by a k x k ,
N N N ^ ^ )^和 分別求和,得到 、∑^Λ和 ∑ckzk , 以所述∑"Λ 、 ∑ yk NNN ^ ^ )^ and sum, respectively, get ∑^Λ and ∑c k z k , with the ∑"Λ, ∑ y k
N k=l k=l k=l k=1 k=1 和∑ 分別作为多层快速响应 QR码的像素 RGB分量的 R分量、 G分量和 B分 k=l N k = lk = lk = l k = 1 k = 1 and ∑ respectively as the R component, the G component and the B component k = l of the pixel RGB component of the multi-layer fast response QR code
量。 the amount.
11、 一种多层快速响应码解码装置, 其特征在于, 所述装置包括: 像素分量解析模块, 用于解析多层快速响应快速响应 QR码图像以得到所 述多层快速响应 QR码图像每一层图像的像素 RGB分量,所述多层快速响应 QR 码的图像层数为 N,所述多层快速响应 QR码图像为从双向可逆颜色特征库获取 N组颜色系数特征值后将原始快速响应 QR码的图像层按照颜色顺序进行叠加 得到的多层快速响应 QR码图像;  A multi-layer fast response code decoding device, the device comprising: a pixel component parsing module, configured to parse a multi-layer fast response fast response QR code image to obtain the multi-layer fast response QR code image a pixel RGB component of a layer of image, the number of image layers of the multi-layer fast response QR code is N, and the multi-layer fast response QR code image is obtained by acquiring N sets of color coefficient feature values from the bidirectional reversible color feature library a multi-layer fast response QR code image obtained by superimposing image layers in response to a QR code in color order;
图像绘制模块, 用于由所述多层快速响应 QR码图像每一层图像的像素 RGB分量绘制单层快速响应 QR码图像;  An image drawing module, configured to draw a single layer quick response QR code image by pixel RGB components of each layer image of the multi-layer fast response QR code image;
图像处理模块, 用于对所述单层快速响应 QR码图像进行处理以解析出所 述单层快速响应 QR码图像包含的信息内容; An image processing module, configured to process the single layer quick response QR code image to parse the image Describe the information content contained in the single layer quick response QR code image;
连接模块, 用于将所述从各个单层快速响应 QR码图像解析出的信息内容 按照所述颜色顺序进行连接。  And a connection module, configured to connect the information content parsed from each single layer quick response QR code image according to the color sequence.
12、 如权利要求 11所述的装置, 其特征在于, 所述图像处理模块包括: 二值化处理单元, 用于对所述单层快速响应 QR码图像进行二值化、 去噪 声和形态学算法处理, 得到二值化图像;  12. The apparatus according to claim 11, wherein the image processing module comprises: a binarization processing unit, configured to perform binarization, denoising, and morphology on the single layer fast response QR code image. Algorithm processing to obtain a binarized image;
识別单元, 用于对所述二值化图像进行快速响应 QR码识別;  An identification unit, configured to perform fast response on the binarized image, and perform QR code identification;
信息解析单元, 用于解析所述进行快速响应 QR码识別后的二值化图像, 以得到所述单层快速响应 QR码图像包含的信息内容。  The information parsing unit is configured to parse the binarized image after performing the fast response QR code identification to obtain the information content included in the single layer quick response QR code image.
PCT/CN2011/080306 2011-09-28 2011-09-28 Multilayer quick response code image encoding/decoding method and encoding/decoding device WO2012149778A1 (en)

Priority Applications (2)

Application Number Priority Date Filing Date Title
CN201180003663.3A CN102741864B (en) 2011-09-28 2011-09-28 Multilayer quick response code image encoding/decoding method and encoding/decoding device
PCT/CN2011/080306 WO2012149778A1 (en) 2011-09-28 2011-09-28 Multilayer quick response code image encoding/decoding method and encoding/decoding device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
PCT/CN2011/080306 WO2012149778A1 (en) 2011-09-28 2011-09-28 Multilayer quick response code image encoding/decoding method and encoding/decoding device

Publications (1)

Publication Number Publication Date
WO2012149778A1 true WO2012149778A1 (en) 2012-11-08

Family

ID=46995174

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2011/080306 WO2012149778A1 (en) 2011-09-28 2011-09-28 Multilayer quick response code image encoding/decoding method and encoding/decoding device

Country Status (2)

Country Link
CN (1) CN102741864B (en)
WO (1) WO2012149778A1 (en)

Cited By (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US8936194B1 (en) 2013-03-15 2015-01-20 Wunderlich-Malec Engineering, Inc. Methods and systems for using two-dimensional matrix codes associated with panel component and equipment information and quality control
CN104463059A (en) * 2013-09-16 2015-03-25 航天信息股份有限公司 Method for reconstructing damaged figure in QR code recognition
CN104517092A (en) * 2013-09-29 2015-04-15 北大方正集团有限公司 Method and system for detecting QR (quick response) code correction graphics
CN104636702A (en) * 2015-01-26 2015-05-20 川渝中烟工业有限责任公司 Two-dimensional code identification method for tobacco industry
CN104809422A (en) * 2015-04-27 2015-07-29 江苏中科贯微自动化科技有限公司 QR code recognizing method based on image processing
US9286557B2 (en) 2014-03-06 2016-03-15 International Business Machines Corporation Optimizing quick response code capacity using gray luminance

Families Citing this family (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102983938A (en) * 2012-11-13 2013-03-20 中国人民解放军72671部队 No-feedback one-way data transmission method and device based on quick response (QR) codes
CN105335773B (en) * 2014-07-30 2018-05-04 北大方正集团有限公司 QR code encoding methods and device
CN107066908B (en) * 2016-12-26 2021-08-03 福建新大陆自动识别技术有限公司 Bar code scanning device with double trigger modes

Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1845124A (en) * 2006-05-16 2006-10-11 北京紫光捷通科技有限公司 Color information superposition of QR code
CN101149813A (en) * 2007-07-13 2008-03-26 中兴通讯股份有限公司 Matrix type colorful two-dimensional bar code encoding and decoding method
CN101661564A (en) * 2008-08-28 2010-03-03 国际商业机器公司 Bar code generating/identifying device and method

Family Cites Families (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
RU2251734C2 (en) * 2000-05-09 2005-05-10 Колорзип Медиа, Инк. Machine-readable code, method and device for encoding and decoding

Patent Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1845124A (en) * 2006-05-16 2006-10-11 北京紫光捷通科技有限公司 Color information superposition of QR code
CN101149813A (en) * 2007-07-13 2008-03-26 中兴通讯股份有限公司 Matrix type colorful two-dimensional bar code encoding and decoding method
CN101661564A (en) * 2008-08-28 2010-03-03 国际商业机器公司 Bar code generating/identifying device and method

Cited By (8)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US8936194B1 (en) 2013-03-15 2015-01-20 Wunderlich-Malec Engineering, Inc. Methods and systems for using two-dimensional matrix codes associated with panel component and equipment information and quality control
US9047279B1 (en) 2013-03-15 2015-06-02 Wunderlich-Malec Engineering, Inc. Methods and systems for using two-dimensional matrix codes associated with panel component and equipment information and quality control
CN104463059A (en) * 2013-09-16 2015-03-25 航天信息股份有限公司 Method for reconstructing damaged figure in QR code recognition
CN104463059B (en) * 2013-09-16 2017-06-30 航天信息股份有限公司 Reconstructing method when a detection figure is damaged in QR yards of identification
CN104517092A (en) * 2013-09-29 2015-04-15 北大方正集团有限公司 Method and system for detecting QR (quick response) code correction graphics
US9286557B2 (en) 2014-03-06 2016-03-15 International Business Machines Corporation Optimizing quick response code capacity using gray luminance
CN104636702A (en) * 2015-01-26 2015-05-20 川渝中烟工业有限责任公司 Two-dimensional code identification method for tobacco industry
CN104809422A (en) * 2015-04-27 2015-07-29 江苏中科贯微自动化科技有限公司 QR code recognizing method based on image processing

Also Published As

Publication number Publication date
CN102741864B (en) 2014-08-20
CN102741864A (en) 2012-10-17

Similar Documents

Publication Publication Date Title
WO2012149778A1 (en) Multilayer quick response code image encoding/decoding method and encoding/decoding device
US8511562B2 (en) Layered two-dimensional code, creation method thereof, and read method
JP4557866B2 (en) Mixed code, mixed code generation method and apparatus, and recording medium
JP4515999B2 (en) Mixed code decoding method and apparatus, and recording medium
TWI746882B (en) Two-dimensional barcode, printed publication, generating device, and information processing method
US20160321529A1 (en) Producing, capturing and using visual identification tags for moving objects
CN110263813B (en) Significance detection method based on residual error network and depth information fusion
CN104866323B (en) Unlocking interface generation method and device and electronic equipment
KR101554518B1 (en) Information obtaining method and apparatus
WO2017198189A1 (en) Generation and reading method and device for colour identified colour two-dimensional figure code
US9659387B2 (en) Graphics primitive and color channels
CN104866755B (en) Setting method and device for background picture of application program unlocking interface and electronic equipment
WO2019214291A1 (en) Three-dimensional code generating and parsing method
CN111222611A (en) Stacking type three-dimensional code encoding method, encoding device, decoding method, decoding device and storage medium based on colors
CN109214486B (en) Three-dimensional code, three-dimensional code generation method and device, and three-dimensional code identification method and device
CN103336757A (en) Hardware protocol stack
US20160189015A1 (en) Data exchange methods, systems and apparatus using color images
JP2017079082A (en) Optical-reading code preparation device
CN104424619B (en) Information processing equipment and information processing method
WO2024087864A1 (en) Image watermarking method and device
Badawi et al. Fuzzy encoder framework for four layers color QR code
US20130156256A1 (en) Steganographic encoding and verification
CN110378829A (en) Information provides and the method, device and equipment of watermark extracting
CN113781287A (en) Watermark image processing method, watermark image processing device, electronic equipment and computer readable storage medium
WO2019127514A1 (en) Graphic code generation method and apparatus, graphic code verification method and apparatus, device, and storage medium

Legal Events

Date Code Title Description
WWE Wipo information: entry into national phase

Ref document number: 201180003663.3

Country of ref document: CN

121 Ep: the epo has been informed by wipo that ep was designated in this application

Ref document number: 11864877

Country of ref document: EP

Kind code of ref document: A1

NENP Non-entry into the national phase

Ref country code: DE

122 Ep: pct application non-entry in european phase

Ref document number: 11864877

Country of ref document: EP

Kind code of ref document: A1