二维码RS数据纠错算法C版Word文档格式.docx
《二维码RS数据纠错算法C版Word文档格式.docx》由会员分享,可在线阅读,更多相关《二维码RS数据纠错算法C版Word文档格式.docx(24页珍藏版)》请在冰豆网上搜索。
//数据码(字数L,M,Q,H)(总码字-RS码字)
intncAlignPoint;
//校正点数
intnAlignPoint[6];
//校正图形中心坐标
RS_BLOCKINFORS_BlockInfo1[4];
//纠错块信息
RS_BLOCKINFORS_BlockInfo2[4];
BYTEBitnum;
//剩余位
}QR_VERSIONINFO,*LPQR_VERSIONINFO;
////////////////////////////////////////////////////
//QRcode相关信息
QR_VERSIONINFOQR_VersonInfo[]={{0,//Ver.0
0,0,0,0,0,
1,14},
{1,//Ver.1
26,19,16,13,9,//数据码字数
0,0,0,0,0,0,0,//校正图形中心坐标
//纠错块1
1,26,19,2,
1,26,16,4,
1,26,13,6,
1,26,9,8,
//纠错块2
0,0,0,0,
//剩余位
0},
{2,//Ver.2
44,34,28,22,16,
1,18,0,0,0,0,0,
1,44,34,4,
1,44,28,8,
1,44,22,11,
1,44,16,14,
},
{3,//Ver.3
70,55,44,34,26,
1,22,0,0,0,0,0,
1,70,55,7,
1,70,44,13,
2,35,17,9,
2,35,13,11,
0,0,0,0},
{4,//Ver.4
100,80,64,48,36,
1,26,0,0,0,0,0,
1,100,80,10,
2,50,32,9,
2,50,24,13,
4,25,9,8,
{5,//Ver.5
134,108,86,62,46,
1,30,0,0,0,0,0,
1,1
34,108,13,
2,67,43,12,
2,33,15,9,
2,33,11,11,
2,34,16,9,
2,34,12,11},
{6,//Ver.6
172,136,108,76,60,
1,34,0,0,0,0,0,
2,86,68,9,
4,43,27,8,
4,43,19,12,
4,43,15,14,
0,0,0,0,
0,0,0,0},
{7,//Ver.7
196,156,124,88,66,
2,22,38,0,0,0,0,
2,98,78,10,
4,49,31,9,
2,32,14,9,
4,39,13,13,
4,33,15,9,
1,40,14,13},
{8,//Ver.8
242,194,154,110,86,
2,24,42,0,0,0,0,
2,121,97,12,
2,60,38,11,
4,40,18,11,
4,40,14,13,
2,61,39,11,
2,41,19,11,
2,41,15,13},
{9,//Ver.9
292,232,182,132,100,
2,26,46,0,0,0,0,
2,146,116,15,
3,58,36,11,
4,36,16,10,
4,36,12,12,
2,59,37,11,
4,37,17,10,
4,37,13,12},
{10,//Ver.10
346,274,216,154,122,
2,28,50,0,0,0,0,
2,86,68,9,
4,69,43,13,
6,43,19,12,
6,43,15,14,
2,87,69,9,
2,44,20,12,
2,44,16,14},
{11,//Ver.11
404,324,254,180,140,
2,30,54,0,0,0,0,
4,101,81,10,
1,80,50,15,
4,50,22,14,
3,36,12,12,
4,81,51,15,
4,51,23,14,
8,37,13,12},
{12,//Ver.12
466,370,290,206,158,
2,32,58,0,0,0,0,
2,116,92,12,
6,58,36,11,
4,46,20,13,
7,42,14,14,
2,117,93,12,
6,47,21,13,
4,43,15,14},
{13,//Ver.13
532,428,334,244,180,
2,34,62,0,0,0,0,
4,133,107,13,
8,59,37,11,
8,44,20,12,
12,33,11,11,
1,60,38,11,
4,45,21,12,
4,34,12,11,},
{14,//Ver.14
581,461,365,261,197,
3,26,46,66,0,0,0,
3,145,115,15,
4,64,40,12,
11,36,16,10,
11,36,12,12,
1,146,116,15,
5,65,41,12,
5,37,17,10,
5,37,13,12},
{15,//Ver.15
655,523,415,295,223,
3,26,48,70,0,0,0,
5,109,87,11,
5,54,24,15,
1,110,88,11,
5,66,42,12,
7,55,25,15,
7,37,13,12,},
{16,//Ver.16
733,589,453,325,253,
3,26,50,74,0,0,0,
5,122,98,12,
7,73,45,14,
15,43,19,12,
3,45,15,15,
1,123,99,12,
3,74,46,14,
13,46,16,15},
{17,//Ver.17
815,647,507,367,283,
3,30,54,78,0,0,0,
1,135,107,14,
10,74,46,14,
1,50,22,14,
2,42,14,14,
5,136,108,14,
1,75,47,14,
15,51,23,14,
17,43,15,14,},
{18,//Ver.18
901,721,563,397,313,
3,30,56,82,0,0,0,
5,150,120,15,
9,69,43,13,
17,50,22,14,
1,151,121,15,
4,70,44,13,
1,51,23,14,
19,43,15,14,},
{19,//Ver.19
991,795,627,445,341,
3,30,58,86,0,0,0,
3,141,113,14,
3,70,44,13,
17,47,21,13,
9,39,13,13,
4,142,114,14,
11,71,45,13,
4,48,22,13,
16,40,14,13,},
{20,//Ver.20
1085,861,669,485,385,
3,34,62,90,0,0,0,
3,135,107,14,
3,67,41,13,
15,54,24,15,
15,43,15,14,
13,68,42,13,
5,55,25,15,
10,44,16,14,},
{21,//Ver.21
1156,932,714,512,406,
4,28,50,72,94,0,0,
4,144,116,14,
17,68,42,13,
19,46,16,15,
4,145,117,14,
6,51,23,14,
6,47,17,15},
{22,//Ver.22
1258,1006,78