CN104268615A - Encoding method and decoding method for color two-dimensional code - Google Patents
Encoding method and decoding method for color two-dimensional code Download PDFInfo
- Publication number
- CN104268615A CN104268615A CN201410577744.XA CN201410577744A CN104268615A CN 104268615 A CN104268615 A CN 104268615A CN 201410577744 A CN201410577744 A CN 201410577744A CN 104268615 A CN104268615 A CN 104268615A
- Authority
- CN
- China
- Prior art keywords
- color
- code
- dimensional code
- character
- colors
- Prior art date
- Legal status (The legal status 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 status listed.)
- Pending
Links
Landscapes
- Color Image Communication Systems (AREA)
Abstract
The invention relates to an encoding method and a decoding method for a color two-dimensional code, and belongs to the technical field of computers and two-dimensional codes. The encoding method comprises the following steps: step one, enabling all colors needing to be used by the two-dimensional code to correspond to corresponding numerical values in a one-to-one correspondence mode; step two, converting information to be expressed into single characters one by one; step three, converting the single characters into ASCII (American Standard Code for Information Interchange) codes; step four, converting the ASCII codes into N-system digits; step five, converting the digits into different colors; step six, filling a matrix graph with the colors in the step five to form the color two-dimensional code. The encoding method and the decoding method for the color two-dimensional code provided by the invention is good in practicability, can overcome the problems that a traditional two-dimensional code is low in information storage content and poor in compatibility and cannot express complicated pictures and scenes; meanwhile, the color two-dimensional code has rich colors and relatively strong visual impact.
Description
Technical field
The invention belongs to computing machine and planar bar code technology field, relate to a kind of encoding and decoding method of color 2 D code, be related specifically to encoding and decoding method that is colored, irregular Quick Response Code.
Background technology
The Quick Response Code of current widespread use, form with the point of black and white, with certain specific geometric figure according to certain rules in the plane (on two-dimensional directional) distribute graphic recording data symbol information chequered with black and white, in horizontal and vertical two orientation expressing information simultaneously, therefore can express a large amount of information in very little area.
Quick Response Code may be used for information transmission, individual business card, network address, advertisement, voucher, mobile payment and other need to transmit the application scenarios of low volume data.Current black and white Quick Response Code, can variable color, embedded picture etc. after post-processed, but there is the problems such as information storage is low, poor compatibility, and be beyond expression complicated picture and scene.
Summary of the invention
In view of this, the object of the present invention is to provide a kind of encoding and decoding method of color 2 D code, the program adopts the method for coloud coding, and the information storage that can overcome conventional two-dimensional code is low, the problem of poor compatibility and be beyond expression complicated picture and scene.
For achieving the above object, the invention provides following technical scheme:
A coding method for color 2 D code, comprises the following steps: step one: needed by Quick Response Code each color of using and corresponding numerical value to carry out one_to_one corresponding; Step 2: the information that will express is converted to single character one by one; Step 3: single character is converted to ASCII character; Step 4: ASCII character is converted to N binary digits; Step 5: digital conversion is corresponded to different colors; Step 6: carry out the color in filling step five with a matrix diagram, forms color 2 D code.
Further, in the method, multiple color can be used to generate Quick Response Code, and the kind of color minimum be 3 kinds.
Present invention also offers a kind of coding/decoding method of color 2 D code, comprise the following steps: step one: two-dimension code pattern is scanned; Step 2: obtain the color lump that figure outermost makes a circle, draws the color composition of this two-dimension code pattern, and then draws color data table according to the corresponding relation of each color and respective value; Step 3: read each color lump one by one, and convert each color lump to numeral; Step 4: digital conversion become ASCII character and be converted to character further, reads color 2 D code information according to character.
Beneficial effect of the present invention is: the encoding and decoding method practicality of color 2 D code provided by the invention is good, and the information storage that can overcome conventional two-dimensional code is low, the problem of poor compatibility and be beyond expression complicated picture and scene.Meanwhile, possess abundant color according to the Quick Response Code that the method generates, color lump can be irregular figure (as: heart, round dot or other different figures), has stronger visual impact and even can comprise art creation.
Accompanying drawing explanation
In order to make object of the present invention, technical scheme and beneficial effect clearly, the invention provides following accompanying drawing and being described:
Fig. 1 is the color 2 D code schematic diagram of 8 kinds of colors;
Fig. 2 is colored Quick Response Code schematic diagram in embodiment.
Embodiment
Below in conjunction with accompanying drawing, the preferred embodiments of the present invention are described in detail.
The invention discloses a kind of encoding and decoding method of color 2 D code, be applicable to printed matter or LCD screen display.Multiple color can be used in the method to carry out Quick Response Code coding, and as 4 kinds, 8 kinds, 16 kinds or 24 kinds of colors, minimum is 3 kinds.Color category quantity can be odd number and also can be even number, prints different with the precision of scanning, do not limit in theory by number of colors according to code figure.Spendable color is not limited only to 4 kinds, 8 kinds, 16 kinds or 24 kinds that have selected, suppose that the color that can correctly print and identify is 256 kinds, color so except 4 kinds, 8 kinds, 16 kinds or 24 kinds also may be used for border or obscures the use of encryption, and capacity can become according to the size of figure.
Coding method comprises the following steps: step one: needed by Quick Response Code each color of using and corresponding numerical value to carry out one_to_one corresponding; Step 2: the information that will express is converted to single character one by one; Step 3: single character is converted to ASCII character; Step 4: ASCII character is converted to N binary digits; Step 5: digital conversion is corresponded to different colors; Step 6: carry out the color in filling step five with a matrix diagram, forms color 2 D code.
Fig. 1 is the color 2 D code schematic diagram of 8 kinds of colors, and as shown in the figure, 8 kinds of colors are respectively with A, B, C, D, E, F, G, H, and 8 letter representations, are placed on the border of figure, define this yard of diagram data color to be: A-H, also defines the size of yard figure simultaneously; In figure, irregular A-H letter represents the color lump of different colours.Thick lines chequered with black and white between color lump are the border between color lump, and the random color beyond 8 colors that A-H can be used to represent is filled.
Embodiment:
In the present embodiment, 8 kinds of colors are adopted to carry out Quick Response Code coding, for " Hello world ".
In an encoding process, first set up the color data table of 8 systems, as shown in table 1:
Color | A | B | C | D | E | F | G | H |
Numerical value | 0 | 1 | 2 | 3 | 4 | 5 | 6 | 7 |
Table 1
According to step 2 to step 5, carry out color 2 D code coding, concrete steps see the following form (table 2):
Table 2
According to the color of upper table, 33 color lumps, fill above-mentioned color with the matrix diagram of a 7X7 altogether, finally form color 2 D code.As shown in Figure 2, wherein, the ABCDEFGH of surrounding represents 8 colors, and bold portion and blank space represent Interval data.
Decode procedure:
1, scanned picture, the general mobile phone camera that uses is taken;
2, obtain the color lump that picture outermost makes a circle, number is even number, show that this picture is made up of 8 colors, draws the color data table of table 1:8 system;
3, color is read one by one:
1) the 1st is read to obtain B;
2) the 2nd is read to obtain B;
3) the 3rd is read to obtain A;
4) the 4th reads separator.
4, read the color lump of the corresponding numerical value of first character is: BBA;
5, carry out backout according to table 2, color lump is converted to character string, obtain: Hello world.
What finally illustrate is, above preferred embodiment is only in order to illustrate technical scheme of the present invention and unrestricted, although by above preferred embodiment to invention has been detailed description, but those skilled in the art are to be understood that, various change can be made to it in the form and details, and not depart from claims of the present invention limited range.
Claims (3)
1. a coding method for color 2 D code, is characterized in that: comprise the following steps:
Step one: needed by Quick Response Code each color of using and corresponding numerical value to carry out one_to_one corresponding;
Step 2: the information that will express is converted to single character one by one;
Step 3: single character is converted to ASCII character;
Step 4: ASCII character is converted to N binary digits;
Step 5: digital conversion is corresponded to different colors;
Step 6: carry out the color in filling step five with a matrix diagram, forms color 2 D code.
2. the coding method of a kind of color 2 D code according to claim 1, is characterized in that: in the method, and multiple color can be used to generate Quick Response Code, and the kind of color minimum be 3 kinds.
3. a coding/decoding method for color 2 D code, is characterized in that: comprise the following steps:
Step one: two-dimension code pattern is scanned;
Step 2: obtain the color lump that figure outermost makes a circle, draws the color composition of this two-dimension code pattern, and then according to each
The corresponding relation of color and respective value draws color data table;
Step 3: read each color lump one by one, and convert each color lump to numeral;
Step 4: digital conversion become ASCII character and be converted to character further, reads color 2 D code information according to character.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201410577744.XA CN104268615A (en) | 2014-10-24 | 2014-10-24 | Encoding method and decoding method for color two-dimensional code |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201410577744.XA CN104268615A (en) | 2014-10-24 | 2014-10-24 | Encoding method and decoding method for color two-dimensional code |
Publications (1)
Publication Number | Publication Date |
---|---|
CN104268615A true CN104268615A (en) | 2015-01-07 |
Family
ID=52160135
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201410577744.XA Pending CN104268615A (en) | 2014-10-24 | 2014-10-24 | Encoding method and decoding method for color two-dimensional code |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN104268615A (en) |
Cited By (11)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN104573610A (en) * | 2015-01-29 | 2015-04-29 | 四川省英联国泰科技有限公司 | Commodity anti-fake method and anti-fake scanning device |
CN104657698A (en) * | 2015-02-10 | 2015-05-27 | 浙江科技学院 | Method for encoding and decoding colored two-dimensional code capable of bearing multiple black and white two-dimensional codes |
CN104850817A (en) * | 2015-06-12 | 2015-08-19 | 矽照光电(厦门)有限公司 | Device for recognizing color higher-order implicit image code |
CN104899630A (en) * | 2015-06-18 | 2015-09-09 | 桂林电子科技大学 | Method of encoding/decoding color QR code |
CN106022430A (en) * | 2016-05-18 | 2016-10-12 | 北京鼎九信息工程研究院有限公司 | Method and device for generating, recognizing and reading synthetic-type color two-dimensional diagram code |
CN106056387A (en) * | 2015-07-20 | 2016-10-26 | 王维德 | Intelligent payment device and method using color identification and code |
CN107169540A (en) * | 2017-05-11 | 2017-09-15 | 北京京东尚科信息技术有限公司 | The information transmission system, method and apparatus |
WO2018002944A1 (en) * | 2016-07-01 | 2018-01-04 | Hewlett-Packard Development Company, L.P. | Converting binary data to images |
WO2018058847A1 (en) * | 2016-09-13 | 2018-04-05 | 江苏图码信息科技有限公司 | Color code product with hand drawn pattern or text and application component |
CN108764000A (en) * | 2016-02-23 | 2018-11-06 | 海信集团有限公司 | Quick Response Code fast decoding method |
CN109063807A (en) * | 2018-09-10 | 2018-12-21 | 上海祥羽投资咨询有限公司 | A kind of generation of three-dimension code, reading and recognition methods |
Citations (6)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN102034127A (en) * | 2009-09-28 | 2011-04-27 | 上海易悠通信息科技有限公司 | Novel high-capacity two-dimensional barcode and system, encoding and decoding methods and applications thereof |
CN102147873A (en) * | 2011-03-21 | 2011-08-10 | 上海彩码信息科技有限公司 | Method and system for generating color code as well as method and system for analyzing color code |
CN102243712A (en) * | 2010-05-14 | 2011-11-16 | 上海彩码信息科技有限公司 | Generation method and system thereof for colored bar code, and analytic method and system thereof for colored bar code |
CN102750564A (en) * | 2012-05-14 | 2012-10-24 | 王安然 | Dynamic two-dimension code and decoding method thereof |
CN103177281A (en) * | 2013-04-12 | 2013-06-26 | 江苏圆坤二维码研究院有限公司 | Two-dimensional code compiling method |
CN103632182A (en) * | 2012-08-22 | 2014-03-12 | 天津网团科技有限公司 | Three-dimensional (3D) image code generating and analyzing methods and device thereof |
-
2014
- 2014-10-24 CN CN201410577744.XA patent/CN104268615A/en active Pending
Patent Citations (6)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN102034127A (en) * | 2009-09-28 | 2011-04-27 | 上海易悠通信息科技有限公司 | Novel high-capacity two-dimensional barcode and system, encoding and decoding methods and applications thereof |
CN102243712A (en) * | 2010-05-14 | 2011-11-16 | 上海彩码信息科技有限公司 | Generation method and system thereof for colored bar code, and analytic method and system thereof for colored bar code |
CN102147873A (en) * | 2011-03-21 | 2011-08-10 | 上海彩码信息科技有限公司 | Method and system for generating color code as well as method and system for analyzing color code |
CN102750564A (en) * | 2012-05-14 | 2012-10-24 | 王安然 | Dynamic two-dimension code and decoding method thereof |
CN103632182A (en) * | 2012-08-22 | 2014-03-12 | 天津网团科技有限公司 | Three-dimensional (3D) image code generating and analyzing methods and device thereof |
CN103177281A (en) * | 2013-04-12 | 2013-06-26 | 江苏圆坤二维码研究院有限公司 | Two-dimensional code compiling method |
Cited By (15)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN104573610A (en) * | 2015-01-29 | 2015-04-29 | 四川省英联国泰科技有限公司 | Commodity anti-fake method and anti-fake scanning device |
CN104657698A (en) * | 2015-02-10 | 2015-05-27 | 浙江科技学院 | Method for encoding and decoding colored two-dimensional code capable of bearing multiple black and white two-dimensional codes |
CN104657698B (en) * | 2015-02-10 | 2017-09-19 | 浙江科技学院 | A kind of color 2 D code decoding method for carrying several black and white Quick Response Codes |
CN104850817A (en) * | 2015-06-12 | 2015-08-19 | 矽照光电(厦门)有限公司 | Device for recognizing color higher-order implicit image code |
CN104899630A (en) * | 2015-06-18 | 2015-09-09 | 桂林电子科技大学 | Method of encoding/decoding color QR code |
CN104899630B (en) * | 2015-06-18 | 2018-04-27 | 桂林电子科技大学 | The coding/decoding method of colored QR codes |
CN106056387A (en) * | 2015-07-20 | 2016-10-26 | 王维德 | Intelligent payment device and method using color identification and code |
CN108764000A (en) * | 2016-02-23 | 2018-11-06 | 海信集团有限公司 | Quick Response Code fast decoding method |
CN106022430A (en) * | 2016-05-18 | 2016-10-12 | 北京鼎九信息工程研究院有限公司 | Method and device for generating, recognizing and reading synthetic-type color two-dimensional diagram code |
CN106022430B (en) * | 2016-05-18 | 2022-01-07 | 北京鼎九信息工程研究院有限公司 | Method and device for generating, recognizing and reading synthetic color two-dimensional graph code |
WO2018002944A1 (en) * | 2016-07-01 | 2018-01-04 | Hewlett-Packard Development Company, L.P. | Converting binary data to images |
WO2018058847A1 (en) * | 2016-09-13 | 2018-04-05 | 江苏图码信息科技有限公司 | Color code product with hand drawn pattern or text and application component |
CN107169540B (en) * | 2017-05-11 | 2020-11-24 | 北京京东尚科信息技术有限公司 | Information transmission system, method and device |
CN107169540A (en) * | 2017-05-11 | 2017-09-15 | 北京京东尚科信息技术有限公司 | The information transmission system, method and apparatus |
CN109063807A (en) * | 2018-09-10 | 2018-12-21 | 上海祥羽投资咨询有限公司 | A kind of generation of three-dimension code, reading and recognition methods |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN104268615A (en) | Encoding method and decoding method for color two-dimensional code | |
US20180341844A1 (en) | Two-dimensional Dot Matrix Barcode Encoding and Identifying Methods | |
CN101699426B (en) | Document format conversion system and method | |
CN103718194B (en) | Including the design code pattern of information decoded by digital device and its operating system | |
CN105095935B (en) | A kind of low-density having merged Chaos Encryption Technology, high coding capacity dot matrix Quick Response Code | |
CN101908155B (en) | Encoding system and method and decoding system and method of two-dimension code | |
CN102750564B (en) | Dynamic two-dimension code and coding/decoding method thereof | |
CN104966115A (en) | Method for filling two-dimensional code through image | |
CN105426945B (en) | Intelligent graphic identifies the coded system and method, decoding system and method for two dimensional code | |
CN1439154A (en) | Automatic optimization of the position of stems of text characters | |
WO2017198189A1 (en) | Generation and reading method and device for colour identified colour two-dimensional figure code | |
CN104143200B (en) | The frame type coding and intelligent identification Method of a kind of additional information of images | |
CN102800243A (en) | Anti-counterfeiting annular code and encoding method thereof | |
US10395155B2 (en) | Billboard containing encoded information | |
CN106446885A (en) | Paper-based Braille recognition method and system | |
CN101908216B (en) | Method and device for realizing vector fonts | |
CN105426944A (en) | Square lattice anti-counterfeit label group, and method and system for reading square lattice anti-counterfeit label group | |
CN110033054A (en) | Personalized handwritten form moving method and system based on collaboration stroke optimization | |
CN110276428A (en) | A kind of four-dimension code encoding and decoding method | |
CN104424498A (en) | Method and device for transforming two-dimensional codes at high speed | |
CN103955730A (en) | Manufacturing method of anti-counterfeiting photo-etched two-dimensional code labels | |
CN104281865A (en) | Method and equipment for generating two-dimensional codes | |
CN102214312A (en) | Two-dimensional code and automatic identification voice playing device using same | |
CN103793740B (en) | Encoding system and method and decoding system and method of micro-colored-drawing two-dimension code | |
CN102542528B (en) | Image conversion processing method and system |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
C06 | Publication | ||
PB01 | Publication | ||
C10 | Entry into substantive examination | ||
SE01 | Entry into force of request for substantive examination | ||
RJ01 | Rejection of invention patent application after publication | ||
RJ01 | Rejection of invention patent application after publication |
Application publication date: 20150107 |