module QRCode::Utilities
Extended Modules
Defined in:
qr-code/utilities.crConstant Summary
-
BITS_FOR_MODE =
{MODE[:mode_number] => [10, 12, 14], MODE[:mode_alpha_numk] => [9, 11, 13], MODE[:mode_8bit_byte] => [8, 16, 16]}
-
DEMERIT_POINTS_1 =
3
-
DEMERIT_POINTS_2 =
3
-
DEMERIT_POINTS_3 =
40
-
DEMERIT_POINTS_4 =
10
-
G15 =
((((((1 << 10) | (1 << 8)) | (1 << 5)) | (1 << 4)) | (1 << 2)) | (1 << 1)) | (1 << 0)
-
G15_MASK =
((((1 << 14) | (1 << 12)) | (1 << 10)) | (1 << 4)) | (1 << 1)
-
G18 =
(((((((1 << 12) | (1 << 11)) | (1 << 10)) | (1 << 9)) | (1 << 8)) | (1 << 5)) | (1 << 2)) | (1 << 0)
-
PATTERN_POSITION_TABLE =
[[] of Int32, [6, 18], [6, 22], [6, 26], [6, 30], [6, 34], [6, 22, 38], [6, 24, 42], [6, 26, 46], [6, 28, 50], [6, 30, 54], [6, 32, 58], [6, 34, 62], [6, 26, 46, 66], [6, 26, 48, 70], [6, 26, 50, 74], [6, 30, 54, 78], [6, 30, 56, 82], [6, 30, 58, 86], [6, 34, 62, 90], [6, 28, 50, 72, 94], [6, 26, 50, 74, 98], [6, 30, 54, 78, 102], [6, 28, 54, 80, 106], [6, 32, 58, 84, 110], [6, 30, 58, 86, 114], [6, 34, 62, 90, 118], [6, 26, 50, 74, 98, 122], [6, 30, 54, 78, 102, 126], [6, 26, 52, 78, 104, 130], [6, 30, 56, 82, 108, 134], [6, 34, 60, 86, 112, 138], [6, 30, 58, 86, 114, 142], [6, 34, 62, 90, 118, 146], [6, 30, 54, 78, 102, 126, 150], [6, 24, 50, 76, 102, 128, 154], [6, 28, 54, 80, 106, 132, 158], [6, 32, 58, 84, 110, 136, 162], [6, 26, 54, 82, 110, 138, 166], [6, 30, 58, 86, 114, 142, 170]]
Instance Method Summary
- #demerit_points_1_same_color(modules)
- #demerit_points_2_full_blocks(modules)
-
#demerit_points_3_dangerous_patterns(modules)
ameba:disable Metrics/CyclomaticComplexity
- #demerit_points_4_dark_ratio(modules)
- #get_bch_digit(data)
- #get_bch_format_info(data)
- #get_bch_version(data)
- #get_error_correct_polynomial(error_correct_length)
- #get_length_in_bits(mode, version)
- #get_lost_points(modules)
- #get_mask(mask_pattern, i, j)
- #get_pattern_positions(version)
- #max_size
- #rszf(num : Int32, count : Int32)
- #rszf(num : UInt8, count : Int32)