package com.google.zxing.maxicode.decoder;

import androidx.constraintlayout.core.motion.utils.TypedValues;
import androidx.recyclerview.widget.ItemTouchHelper;
import com.alibaba.fastjson.asm.Opcodes;
import com.cvte.vman.instance.InvokeCmd;
import com.google.zxing.common.BitMatrix;
import com.seewo.vcommons.constants.SeewoConstants;
import com.seewo.vcommons.executor.ButtonActionExecutor;
import org.eclipse.paho.mqttv5.common.packet.MqttReturnCode;

/* JADX INFO: loaded from: classes.dex */
final class BitMatrixParser {
    private static final int[][] BITNR;
    private final BitMatrix bitMatrix;

    static {
        int[] iArr = new int[30];
        // fill-array-data instruction
        iArr[0] = 419;
        iArr[1] = 418;
        iArr[2] = 425;
        iArr[3] = 424;
        iArr[4] = 431;
        iArr[5] = 430;
        iArr[6] = 107;
        iArr[7] = 106;
        iArr[8] = 59;
        iArr[9] = 58;
        iArr[10] = -3;
        iArr[11] = -3;
        iArr[12] = -3;
        iArr[13] = -3;
        iArr[14] = -3;
        iArr[15] = -3;
        iArr[16] = -3;
        iArr[17] = -3;
        iArr[18] = -3;
        iArr[19] = 23;
        iArr[20] = 89;
        iArr[21] = 88;
        iArr[22] = 437;
        iArr[23] = 436;
        iArr[24] = 443;
        iArr[25] = 442;
        iArr[26] = 449;
        iArr[27] = 448;
        iArr[28] = 836;
        iArr[29] = 835;
        BITNR = new int[][]{new int[]{InvokeCmd.CMD_SYSTEMCTRL_SET_REFRESH_RATE, 120, 127, 126, MqttReturnCode.RETURN_CODE_IDENTIFIER_NOT_VALID, MqttReturnCode.RETURN_CODE_UNSUPPORTED_PROTOCOL_VERSION, MqttReturnCode.RETURN_CODE_SERVER_SHUTTING_DOWN, MqttReturnCode.RETURN_CODE_BANNED, MqttReturnCode.RETURN_CODE_PACKET_ID_IN_USE, 144, 151, MqttReturnCode.RETURN_CODE_MESSAGE_RATE_TOO_HIGH, MqttReturnCode.RETURN_CODE_SERVER_MOVED, MqttReturnCode.RETURN_CODE_USE_ANOTHER_SERVER, Opcodes.IF_ICMPGT, 162, Opcodes.RET, 168, 175, 174, Opcodes.PUTFIELD, 180, Opcodes.NEW, 186, Opcodes.INSTANCEOF, Opcodes.CHECKCAST, Opcodes.IFNONNULL, Opcodes.IFNULL, -2, -2}, new int[]{InvokeCmd.CMD_SYSTEMCTRL_SET_SCREENOFF_AUDIO_ENABLE, InvokeCmd.CMD_SYSTEMCTRL_IS_SCREENOFF_AUDIO_SUPPORTED, MqttReturnCode.RETURN_CODE_MALFORMED_CONTROL_PACKET, 128, MqttReturnCode.RETURN_CODE_NOT_AUTHORIZED, MqttReturnCode.RETURN_CODE_BAD_USERNAME_OR_PASSWORD, MqttReturnCode.RETURN_CODE_KEEP_ALIVE_TIMEOUT, MqttReturnCode.RETURN_CODE_BAD_AUTHENTICATION, MqttReturnCode.RETURN_CODE_RECEIVE_MAXIMUM_EXCEEDED, MqttReturnCode.RETURN_CODE_PACKET_ID_NOT_FOUND, 153, MqttReturnCode.RETURN_CODE_ADMINISTRITIVE_ACTION, 159, 158, Opcodes.IF_ACMPEQ, 164, 171, 170, Opcodes.RETURN, Opcodes.ARETURN, Opcodes.INVOKESPECIAL, Opcodes.INVOKEVIRTUAL, 189, Opcodes.NEWARRAY, 195, 194, 201, 200, 816, -3}, new int[]{125, InvokeCmd.CMD_SYSTEMCTRL_IS_SCREENOFF_AUDIO_ENABLE, MqttReturnCode.RETURN_CODE_IMPLEMENTATION_SPECIFIC_ERROR, MqttReturnCode.RETURN_CODE_PROTOCOL_ERROR, MqttReturnCode.RETURN_CODE_SERVER_BUSY, MqttReturnCode.RETURN_CODE_SERVER_UNAVAILABLE, MqttReturnCode.RETURN_CODE_TOPIC_FILTER_NOT_VALID, MqttReturnCode.RETURN_CODE_SESSION_TAKEN_OVER, 149, 148, MqttReturnCode.RETURN_CODE_QOS_NOT_SUPPORTED, 154, 161, 160, Opcodes.GOTO, Opcodes.IF_ACMPNE, 173, 172, 179, Opcodes.GETSTATIC, Opcodes.INVOKEINTERFACE, Opcodes.INVOKESTATIC, 191, 190, 197, 196, 203, 202, 818, 817}, new int[]{283, 282, 277, 276, 271, 270, 265, 264, 259, 258, 253, 252, 247, 246, 241, 240, 235, 234, 229, 228, 223, 222, 217, 216, 211, 210, 205, 204, 819, -3}, new int[]{285, 284, 279, 278, 273, 272, 267, 266, 261, 260, 255, 254, 249, 248, 243, 242, 237, 236, 231, 230, 225, 224, 219, 218, 213, 212, 207, 206, 821, 820}, new int[]{287, 286, 281, 280, 275, 274, 269, 268, 263, 262, 257, 256, 251, ItemTouchHelper.Callback.DEFAULT_SWIPE_ANIMATION_DURATION, 245, 244, 239, 238, 233, 232, 227, 226, 221, 220, 215, 214, 209, 208, 822, -3}, new int[]{289, 288, 295, 294, 301, SeewoConstants.DEFAULT_SLEEP_TIME_5_MINUTE, 307, 306, 313, 312, 319, 318, 325, 324, 331, 330, 337, 336, 343, 342, 349, 348, 355, 354, 361, 360, 367, 366, 824, 823}, new int[]{291, 290, 297, 296, 303, 302, 309, 308, 315, 314, 321, 320, 327, 326, 333, 332, 339, 338, 345, 344, 351, 350, 357, 356, 363, 362, 369, 368, 825, -3}, new int[]{293, 292, 299, 298, 305, 304, 311, 310, 317, 316, 323, 322, 329, 328, 335, 334, 341, 340, 347, 346, 353, 352, 359, 358, 365, 364, 371, 370, 827, 826}, new int[]{409, 408, 403, 402, 397, 396, 391, 390, 79, 78, -2, -2, 13, 12, 37, 36, 2, -1, 44, 43, 109, 108, 385, 384, 379, 378, 373, 372, 828, -3}, new int[]{411, 410, 405, 404, 399, 398, 393, 392, 81, 80, 40, -2, 15, 14, 39, 38, 3, -1, -1, 45, 111, InvokeCmd.CMD_SYSTEMCTRL_GET_PC_STATUS, 387, 386, 381, 380, 375, 374, 830, 829}, new int[]{413, 412, 407, 406, 401, 400, 395, 394, 83, 82, 41, -3, -3, -3, -3, -3, 5, 4, 47, 46, InvokeCmd.CMD_SYSTEMCTRL_MONITOR_NFC_STATE, InvokeCmd.CMD_SYSTEMCTRL_GET_AENA_STATE, 389, 388, 383, 382, 377, 376, 831, -3}, new int[]{415, 414, 421, 420, 427, 426, InvokeCmd.CMD_SYSTEMCTRL_GET_BOOTLOGO_STATE, InvokeCmd.CMD_SYSTEMCTRL_GET_FREEZABLE_APPS, 55, 54, 16, -3, -3, -3, -3, -3, -3, -3, 20, 19, 85, 84, 433, 432, 439, 438, 445, 444, 833, 832}, new int[]{417, TypedValues.Cycle.TYPE_PATH_ROTATE, TypedValues.Cycle.TYPE_WAVE_PERIOD, 422, 429, 428, InvokeCmd.CMD_SYSTEMCTRL_SYNC_SYSTEM_TIME_CHANGE, InvokeCmd.CMD_SYSTEMCTRL_SET_BOOTLOGO_STATE, 57, 56, -3, -3, -3, -3, -3, -3, -3, -3, 22, 21, 87, 86, 435, 434, 441, 440, 447, 446, 834, -3}, iArr, new int[]{481, 480, 475, 474, 469, 468, 48, -2, 30, -3, -3, -3, -3, -3, -3, -3, -3, -3, -3, 0, 53, 52, 463, 462, 457, 456, 451, 450, 837, -3}, new int[]{483, 482, 477, 476, 471, 470, 49, -1, -2, -3, -3, -3, -3, -3, -3, -3, -3, -3, -3, -3, -2, -1, 465, 464, 459, 458, 453, 452, 839, 838}, new int[]{485, 484, 479, 478, 473, 472, 51, 50, 31, -3, -3, -3, -3, -3, -3, -3, -3, -3, -3, 1, -2, 42, 467, 466, 461, 460, 455, 454, 840, -3}, new int[]{487, 486, 493, 492, 499, 498, 97, 96, 61, 60, -3, -3, -3, -3, -3, -3, -3, -3, -3, 26, 91, 90, 505, 504, 511, 510, InvokeCmd.CMD_XBUG_VMAN_FUNTION_CHECK_TIMEOUT_BASE_GET, InvokeCmd.CMD_XBUG_VMAN_FUNTION_CHECK_TIMEOUT_BASE_SET, 842, 841}, new int[]{489, 488, 495, 494, 501, 500, 99, 98, 63, 62, -3, -3, -3, -3, -3, -3, -3, -3, 28, 27, 93, 92, 507, 506, 513, 512, InvokeCmd.CMD_XBUG_GET_LOG_NODE_INFO, InvokeCmd.CMD_XBUG_GET_VMAN_FUNTION_TIME_OUT_LIST, 843, -3}, new int[]{491, 490, 497, 496, 503, 502, 101, 100, 65, 64, 17, -3, -3, -3, -3, -3, -3, -3, 18, 29, 95, 94, 509, 508, InvokeCmd.CMD_XBUG_SET_XBUG_DUMP_CVTE_LOG, 514, 521, 520, 845, 844}, new int[]{559, 558, 553, 552, 547, 546, 541, 540, 73, 72, 32, -3, -3, -3, -3, -3, -3, 10, 67, 66, InvokeCmd.CMD_SYSTEMCTRL_SET_CUSTOMBOOTMEDIA_TYPE, InvokeCmd.CMD_SYSTEMCTRL_GET_CUSTOMBOOTMEDIA_PATH, 535, 534, 529, 528, 523, 522, 846, -3}, new int[]{561, 560, 555, 554, 549, 548, 543, 542, 75, 74, -2, -1, 7, 6, 35, 34, 11, -2, 69, 68, InvokeCmd.CMD_SYSTEMCTRL_CANCEL_GPU_PERFORMANCE, InvokeCmd.CMD_SYSTEMCTRL_KEEP_GPU_PERFORMANCE, 537, 536, 531, 530, 525, 524, 848, 847}, new int[]{563, 562, 557, 556, 551, 550, 545, 544, 77, 76, -2, 33, 9, 8, 25, 24, -1, -2, 71, 70, InvokeCmd.CMD_SYSTEMCTRL_GET_UI_RT_APPS, InvokeCmd.CMD_SYSTEMCTRL_SET_UI_RT_APPS, 539, 538, 533, 532, 527, 526, 849, -3}, new int[]{565, 564, 571, 570, 577, 576, 583, 582, 589, 588, 595, 594, TypedValues.Motion.TYPE_PATH_ROTATE, TypedValues.Motion.TYPE_STAGGER, TypedValues.Motion.TYPE_PATHMOTION_ARC, TypedValues.Motion.TYPE_ANIMATE_CIRCLEANGLE_TO, 613, TypedValues.Motion.TYPE_QUANTIZE_INTERPOLATOR_ID, 619, 618, 625, 624, 631, 630, 637, 636, 643, 642, 851, 850}, new int[]{567, 566, 573, 572, 579, 578, 585, 584, 591, 590, 597, 596, TypedValues.Motion.TYPE_EASING, TypedValues.Motion.TYPE_QUANTIZE_MOTION_PHASE, TypedValues.Motion.TYPE_POLAR_RELATIVETO, TypedValues.Motion.TYPE_DRAW_PATH, 615, 614, 621, 620, 627, 626, 633, 632, 639, 638, 645, 644, 852, -3}, new int[]{569, 568, 575, 574, 581, 580, 587, 586, 593, 592, 599, 598, TypedValues.Motion.TYPE_ANIMATE_RELATIVE_TO, TypedValues.Motion.TYPE_QUANTIZE_INTERPOLATOR, TypedValues.Motion.TYPE_QUANTIZE_INTERPOLATOR_TYPE, TypedValues.Motion.TYPE_QUANTIZE_MOTIONSTEPS, 617, 616, 623, 622, 629, 628, 635, 634, 641, 640, 647, 646, 854, 853}, new int[]{727, 726, 721, 720, 715, 714, 709, 708, 703, 702, 697, 696, 691, 690, 685, 684, 679, 678, 673, 672, 667, 666, 661, 660, 655, 654, 649, 648, 855, -3}, new int[]{729, 728, 723, 722, 717, 716, 711, 710, 705, 704, 699, 698, 693, 692, 687, 686, 681, 680, 675, 674, 669, 668, 663, 662, 657, 656, 651, 650, 857, 856}, new int[]{731, 730, 725, 724, 719, 718, 713, 712, 707, 706, 701, 700, 695, 694, 689, 688, 683, 682, 677, 676, 671, 670, 665, 664, 659, 658, 653, 652, 858, -3}, new int[]{733, 732, 739, 738, 745, 744, 751, 750, 757, 756, 763, 762, 769, 768, 775, 774, 781, 780, 787, 786, 793, 792, 799, 798, 805, 804, 811, 810, 860, 859}, new int[]{735, 734, 741, 740, 747, 746, 753, 752, 759, 758, 765, 764, 771, 770, 777, 776, 783, 782, 789, 788, 795, 794, 801, ButtonActionExecutor.TIME_EXECUTE_DELAYED, 807, 806, 813, 812, 861, -3}, new int[]{737, 736, 743, 742, 749, 748, 755, 754, 761, 760, 767, 766, 773, 772, 779, 778, 785, 784, 791, 790, 797, 796, 803, 802, 809, 808, 815, 814, 863, 862}};
    }

    BitMatrixParser(BitMatrix bitMatrix) {
        this.bitMatrix = bitMatrix;
    }

    byte[] readCodewords() {
        byte[] bArr = new byte[144];
        int height = this.bitMatrix.getHeight();
        int width = this.bitMatrix.getWidth();
        for (int i = 0; i < height; i++) {
            int[] iArr = BITNR[i];
            for (int i2 = 0; i2 < width; i2++) {
                int i3 = iArr[i2];
                if (i3 >= 0 && this.bitMatrix.get(i2, i)) {
                    int i4 = i3 / 6;
                    bArr[i4] = (byte) (((byte) (1 << (5 - (i3 % 6)))) | bArr[i4]);
                }
            }
        }
        return bArr;
    }
}
