mirror of
https://git.code.sf.net/p/zint/code
synced 2026-07-31 02:19:50 +00:00
GRIDMATRIX: fix byte latch 6 -> 7, & allowing more than one
non-digit in numeral (both caused misencodation); replace `gm_macro_matrix[]` array with calculation (marginally slower but saves ~1.4k); replace `gm_shift_set[]` use with simple compares (performance); change GM_CHINESE/etc defines to numbers so can index into new `gm_shift_set[]` array (simplifies mode switching code); GM_NUMBER -> GM_NUMERAL, modules -> macromodules_per_dim, various other renamings to hopefully more explanatory names; various other changes (mostly performance) test suite: make use of new zxing-cpp diagnostics2 branch Grid Matrix decoder manual: slight clarification of `--gs1nocheck` BWIPP: latest
This commit is contained in:
+501
-320
File diff suppressed because it is too large
Load Diff
@@ -738,7 +738,7 @@ static void test_escape_char_process(const testCtx *const p_ctx) {
|
||||
/* 1*/ { BARCODE_CODABLOCKF, DATA_MODE, -1, "\\0\\E\\a\\b\\t\\n\\v\\f\\r\\L\\e\\F\\G\\R\\N\\x81\\\\", "", 0, 101, "(54) 67 62 44 40 44 47 48 2B 6A 67 62 0B 49 4A 4B 4C 18 6A 67 62 0C 4D 50 5B 5C 20 6A 67", 0, "" },
|
||||
/* 2*/ { BARCODE_CODE16K, DATA_MODE, -1, "\\0\\E\\a\\b\\t\\n\\v\\f\\r\\L\\e\\F\\G\\R\\N\\x81\\\\", "", 0, 70, "(25) 21 64 68 71 72 73 74 75 76 77 80 91 92 93 94 95 101 65 60 103 103 103 103 38 59", 0, "" },
|
||||
/* 3*/ { BARCODE_DOTCODE, DATA_MODE, -1, "\\0\\E\\a\\b\\t\\n\\v\\f\\r\\L\\e\\F\\G\\R\\N\\x81\\\\", "", 0, 29, "65 40 44 47 48 49 4A 4B 4C 4D 50 5B 5C 5D 5E 5F 6E 41 3C", 0, "" },
|
||||
/* 4*/ { BARCODE_GRIDMATRIX, DATA_MODE, -1, "\\0\\E\\a\\b\\t\\n\\v\\f\\r\\L\\e\\F\\G\\R\\N\\x81\\\\", "", 0, 30, "30 20 00 02 01 61 00 48 28 16 0C 06 44 03 31 60 74 3C 1F 40 57 00", 0, "" },
|
||||
/* 4*/ { BARCODE_GRIDMATRIX, DATA_MODE, -1, "\\0\\E\\a\\b\\t\\n\\v\\f\\r\\L\\e\\F\\G\\R\\N\\x81\\\\", "", 0, 30, "38 20 00 02 01 61 00 48 28 16 0C 06 44 03 31 60 74 3C 1F 40 57 00", 0, "" },
|
||||
/* 5*/ { BARCODE_HANXIN, DATA_MODE, -1, "\\0\\E\\a\\b\\t\\n\\v\\f\\r\\L\\e\\F\\G\\R\\N\\x81\\\\", "", 0, 23, "2F 80 10 72 09 28 B3 0D 41 BF CC 00 C3 83 A3 C3 F0 2B 80 00 00", 0, "" },
|
||||
/* 6*/ { BARCODE_MAXICODE, DATA_MODE, -1, "\\0\\E\\a\\b\\t\\n\\v\\f\\r\\L\\e\\F\\G\\R\\N\\x81\\\\", "", 0, 30, "(144) 04 3E 3E 00 04 07 08 09 0A 0B 03 3D 2C 24 19 1E 23 1B 18 0E 0C 0D 10 1E 20 21 22 23", 0, "" },
|
||||
/* 7*/ { BARCODE_PDF417, DATA_MODE, -1, "\\0\\E\\a\\b\\t\\n\\v\\f\\r\\L\\e\\F\\G\\R\\N\\x81\\\\", "", 0, 120, "(27) 19 901 0 23 655 318 98 18 461 639 91 512 29 30 31 129 92 900 900 114 476 670 717 35", 0, "" },
|
||||
|
||||
@@ -4119,7 +4119,7 @@ static const char *testUtilZXingCPPName(int index, const struct zint_symbol *sym
|
||||
{ "", BARCODE_DBAR_EXPSTK_CC, 139, },
|
||||
{ "", BARCODE_CHANNEL, 140, },
|
||||
{ "", BARCODE_CODEONE, 141, },
|
||||
{ "", BARCODE_GRIDMATRIX, 142, },
|
||||
{ "GridMatrix", BARCODE_GRIDMATRIX, 142, },
|
||||
{ "QRCode", BARCODE_UPNQR, 143, },
|
||||
{ "", BARCODE_ULTRA, 144, },
|
||||
{ "RMQRCode", BARCODE_RMQR, 145, },
|
||||
|
||||
@@ -41,6 +41,7 @@ run_zxingcpp_test "test_dotcode" "large"
|
||||
run_zxingcpp_test "test_dotcode" "input"
|
||||
run_zxingcpp_test "test_dotcode" "encode"
|
||||
run_zxingcpp_test "test_dotcode" "encode_segs"
|
||||
run_zxingcpp_test "test_gridmtx"
|
||||
run_zxingcpp_test "test_hanxin"
|
||||
run_zxingcpp_test "test_mailmark" "2d_encode"
|
||||
run_zxingcpp_test "test_maxicode" "large"
|
||||
|
||||
Reference in New Issue
Block a user