package p138.p176.p177.p190.p198.p202;

import android.util.Log;
import android.util.Pair;
import android.util.SparseArray;
import com.google.android.exoplayer2.ParserException;
import java.io.EOFException;
import java.nio.ByteBuffer;
import java.nio.ByteOrder;
import java.util.ArrayList;
import java.util.Arrays;
import java.util.Collections;
import java.util.List;
import java.util.Locale;
import java.util.UUID;
import p000.p001.p002.p003.p004.C0567;
import p138.p139.p143.p144.C2803;
import p138.p176.p177.p190.C3414;
import p138.p176.p177.p190.C3431;
import p138.p176.p177.p190.p194.C3526;
import p138.p176.p177.p190.p198.C3556;
import p138.p176.p177.p190.p198.C3558;
import p138.p176.p177.p190.p198.C3570;
import p138.p176.p177.p190.p198.InterfaceC3561;
import p138.p176.p177.p190.p198.InterfaceC3562;
import p138.p176.p177.p190.p198.InterfaceC3571;
import p138.p176.p177.p190.p198.InterfaceC3575;
import p138.p176.p177.p190.p198.p202.C3591;
import p138.p176.p177.p190.p239.C4132;
import p138.p176.p177.p190.p239.C4134;
import p138.p176.p177.p190.p239.C4136;
import p138.p176.p177.p190.p239.C4140;
import p138.p176.p177.p190.p239.C4150;
import p138.p176.p177.p190.p240.C4158;
import p138.p176.p177.p190.p240.C4159;
import p138.p176.p177.p190.p240.C4165;

/* JADX INFO: renamed from: ދ.ހ.֏.ؠ.ೲ.ޘ.ށ, reason: contains not printable characters */
/* JADX INFO: loaded from: classes.dex */
public class C3596 implements InterfaceC3561 {

    /* JADX INFO: renamed from: ೱ, reason: contains not printable characters */
    public static final byte[] f10689 = {49, 10, 48, 48, 58, 48, 48, 58, 48, 48, 44, 48, 48, 48, 32, 45, 45, 62, 32, 48, 48, 58, 48, 48, 58, 48, 48, 44, 48, 48, 48, 10};

    /* JADX INFO: renamed from: ೲ, reason: contains not printable characters */
    public static final byte[] f10690 = C4150.m6799("Format: Start, End, ReadOrder, Layer, Style, Name, MarginL, MarginR, MarginV, Effect, Text");

    /* JADX INFO: renamed from: ഩ, reason: contains not printable characters */
    public static final byte[] f10691 = {68, 105, 97, 108, 111, 103, 117, 101, 58, 32, 48, 58, 48, 48, 58, 48, 48, 58, 48, 48, 44, 48, 58, 48, 48, 58, 48, 48, 58, 48, 48, 44};

    /* JADX INFO: renamed from: ഺ, reason: contains not printable characters */
    public static final UUID f10692 = new UUID(72057594037932032L, -9223371306706625679L);

    /* JADX INFO: renamed from: ֏, reason: contains not printable characters */
    public final InterfaceC3595 f10693;

    /* JADX INFO: renamed from: ؠ, reason: contains not printable characters */
    public final C3602 f10694;

    /* JADX INFO: renamed from: ހ, reason: contains not printable characters */
    public final SparseArray<C3599> f10695;

    /* JADX INFO: renamed from: ށ, reason: contains not printable characters */
    public final boolean f10696;

    /* JADX INFO: renamed from: ނ, reason: contains not printable characters */
    public final C4140 f10697;

    /* JADX INFO: renamed from: ރ, reason: contains not printable characters */
    public final C4140 f10698;

    /* JADX INFO: renamed from: ބ, reason: contains not printable characters */
    public final C4140 f10699;

    /* JADX INFO: renamed from: ޅ, reason: contains not printable characters */
    public final C4140 f10700;

    /* JADX INFO: renamed from: ކ, reason: contains not printable characters */
    public final C4140 f10701;

    /* JADX INFO: renamed from: އ, reason: contains not printable characters */
    public final C4140 f10702;

    /* JADX INFO: renamed from: ވ, reason: contains not printable characters */
    public final C4140 f10703;

    /* JADX INFO: renamed from: މ, reason: contains not printable characters */
    public final C4140 f10704;

    /* JADX INFO: renamed from: ފ, reason: contains not printable characters */
    public final C4140 f10705;

    /* JADX INFO: renamed from: ދ, reason: contains not printable characters */
    public final C4140 f10706;

    /* JADX INFO: renamed from: ތ, reason: contains not printable characters */
    public ByteBuffer f10707;

    /* JADX INFO: renamed from: ލ, reason: contains not printable characters */
    public long f10708;

    /* JADX INFO: renamed from: ގ, reason: contains not printable characters */
    public long f10709;

    /* JADX INFO: renamed from: ޏ, reason: contains not printable characters */
    public long f10710;

    /* JADX INFO: renamed from: ސ, reason: contains not printable characters */
    public long f10711;

    /* JADX INFO: renamed from: ޑ, reason: contains not printable characters */
    public long f10712;

    /* JADX INFO: renamed from: ޒ, reason: contains not printable characters */
    public C3599 f10713;

    /* JADX INFO: renamed from: ޓ, reason: contains not printable characters */
    public boolean f10714;

    /* JADX INFO: renamed from: ޔ, reason: contains not printable characters */
    public int f10715;

    /* JADX INFO: renamed from: ޕ, reason: contains not printable characters */
    public long f10716;

    /* JADX INFO: renamed from: ޖ, reason: contains not printable characters */
    public boolean f10717;

    /* JADX INFO: renamed from: ޗ, reason: contains not printable characters */
    public long f10718;

    /* JADX INFO: renamed from: ޘ, reason: contains not printable characters */
    public long f10719;

    /* JADX INFO: renamed from: ޙ, reason: contains not printable characters */
    public long f10720;

    /* JADX INFO: renamed from: ޚ, reason: contains not printable characters */
    public C4132 f10721;

    /* JADX INFO: renamed from: ޛ, reason: contains not printable characters */
    public C4132 f10722;

    /* JADX INFO: renamed from: ޜ, reason: contains not printable characters */
    public boolean f10723;

    /* JADX INFO: renamed from: ޝ, reason: contains not printable characters */
    public boolean f10724;

    /* JADX INFO: renamed from: ޞ, reason: contains not printable characters */
    public int f10725;

    /* JADX INFO: renamed from: ޟ, reason: contains not printable characters */
    public long f10726;

    /* JADX INFO: renamed from: ޠ, reason: contains not printable characters */
    public long f10727;

    /* JADX INFO: renamed from: ޡ, reason: contains not printable characters */
    public int f10728;

    /* JADX INFO: renamed from: ޢ, reason: contains not printable characters */
    public int f10729;

    /* JADX INFO: renamed from: ޣ, reason: contains not printable characters */
    public int[] f10730;

    /* JADX INFO: renamed from: ޤ, reason: contains not printable characters */
    public int f10731;

    /* JADX INFO: renamed from: ޥ, reason: contains not printable characters */
    public int f10732;

    /* JADX INFO: renamed from: ޱ, reason: contains not printable characters */
    public int f10733;

    /* JADX INFO: renamed from: ࢠ, reason: contains not printable characters */
    public int f10734;

    /* JADX INFO: renamed from: ࢢ, reason: contains not printable characters */
    public boolean f10735;

    /* JADX INFO: renamed from: ࢣ, reason: contains not printable characters */
    public int f10736;

    /* JADX INFO: renamed from: ࢤ, reason: contains not printable characters */
    public int f10737;

    /* JADX INFO: renamed from: ࢥ, reason: contains not printable characters */
    public int f10738;

    /* JADX INFO: renamed from: ࢦ, reason: contains not printable characters */
    public boolean f10739;

    /* JADX INFO: renamed from: ࢧ, reason: contains not printable characters */
    public boolean f10740;

    /* JADX INFO: renamed from: ࢨ, reason: contains not printable characters */
    public boolean f10741;

    /* JADX INFO: renamed from: ࢩ, reason: contains not printable characters */
    public int f10742;

    /* JADX INFO: renamed from: ࢪ, reason: contains not printable characters */
    public byte f10743;

    /* JADX INFO: renamed from: ࢫ, reason: contains not printable characters */
    public boolean f10744;

    /* JADX INFO: renamed from: ࢬ, reason: contains not printable characters */
    public InterfaceC3562 f10745;

    /* JADX INFO: renamed from: ދ.ހ.֏.ؠ.ೲ.ޘ.ށ$ؠ, reason: contains not printable characters */
    public final class C3598 implements InterfaceC3594 {
        public /* synthetic */ C3598(C3597 c3597) {
        }

        /* JADX WARN: Can't fix incorrect switch cases order, some code will duplicate */
        /* JADX WARN: Removed duplicated region for block: B:161:0x0345  */
        /* JADX WARN: Removed duplicated region for block: B:254:0x04a2  */
        /* JADX WARN: Removed duplicated region for block: B:281:0x054a  */
        /* JADX WARN: Removed duplicated region for block: B:285:0x0572  */
        /* JADX WARN: Removed duplicated region for block: B:377:0x076b  */
        /* JADX WARN: Removed duplicated region for block: B:378:0x076d  */
        /* JADX WARN: Removed duplicated region for block: B:381:0x0775  */
        /* JADX WARN: Removed duplicated region for block: B:382:0x0797  */
        /* JADX WARN: Removed duplicated region for block: B:461:0x0935  */
        /* JADX WARN: Removed duplicated region for block: B:481:0x09f5  */
        /* JADX INFO: renamed from: ֏, reason: contains not printable characters */
        /*
            Code decompiled incorrectly, please refer to instructions dump.
        */
        public void m5927(int i) throws ParserException {
            String str;
            Object obj;
            Object obj2;
            String str2;
            Object obj3;
            String str3;
            Object obj4;
            Object obj5;
            String str4;
            Object obj6;
            String str5;
            Object obj7;
            String str6;
            Object obj8;
            String str7;
            Object obj9;
            Object obj10;
            String str8;
            boolean z;
            C3596 c3596;
            byte b;
            String str9;
            List<byte[]> listSingletonList;
            String str10;
            List<byte[]> list;
            Pair pair;
            int i2;
            ArrayList arrayList;
            String str11;
            String str12;
            int i3;
            int i4;
            boolean z2;
            int iM6741;
            List<byte[]> list2;
            List<byte[]> list3;
            List list4;
            C3431 c3431M5588;
            int i5;
            int i6;
            C4159 c4159;
            int i7;
            byte[] bArr;
            int i8;
            InterfaceC3571 c3573;
            C4132 c4132;
            int i9;
            C4132 c41322;
            int i10;
            C3596 c35962 = C3596.this;
            if (c35962 == null) {
                throw null;
            }
            int i11 = 0;
            if (i == 160) {
                if (c35962.f10725 != 2) {
                    return;
                }
                int i12 = 0;
                for (int i13 = 0; i13 < c35962.f10729; i13++) {
                    i12 += c35962.f10730[i13];
                }
                C3599 c3599 = c35962.f10695.get(c35962.f10731);
                int i14 = 0;
                while (i14 < c35962.f10729) {
                    long j = c35962.f10726 + ((long) ((c3599.f10751 * i14) / 1000));
                    int i15 = c35962.f10733;
                    if (i14 == 0 && !c35962.f10735) {
                        i15 |= 1;
                    }
                    int i16 = c35962.f10730[i14];
                    int i17 = i12 - i16;
                    c35962.m5925(c3599, j, i15, i16, i17);
                    i14++;
                    i12 = i17;
                }
                c35962.f10725 = 0;
                return;
            }
            if (i != 174) {
                if (i == 19899) {
                    int i18 = c35962.f10715;
                    if (i18 != -1) {
                        long j2 = c35962.f10716;
                        if (j2 != -1) {
                            if (i18 == 475249515) {
                                c35962.f10718 = j2;
                                return;
                            }
                            return;
                        }
                    }
                    throw new ParserException("Mandatory element SeekID or SeekPosition not found");
                }
                if (i == 25152) {
                    C3599 c35992 = c35962.f10713;
                    if (c35992.f10753) {
                        if (c35992.f10755 == null) {
                            throw new ParserException("Encrypted Track found but ContentEncKeyID was not found");
                        }
                        c35992.f10757 = new C3526(null, true, new C3526.C3528(C3414.f9972, null, "video/webm", c35962.f10713.f10755.f10600));
                        return;
                    }
                    return;
                }
                if (i == 28032) {
                    C3599 c35993 = c35962.f10713;
                    if (c35993.f10753 && c35993.f10754 != null) {
                        throw new ParserException("Combining encryption and compression is not supported");
                    }
                    return;
                }
                if (i == 357149030) {
                    if (c35962.f10710 == -9223372036854775807L) {
                        c35962.f10710 = 1000000L;
                    }
                    long j3 = c35962.f10711;
                    if (j3 != -9223372036854775807L) {
                        c35962.f10712 = c35962.m5922(j3);
                        return;
                    }
                    return;
                }
                if (i == 374648427) {
                    if (c35962.f10695.size() == 0) {
                        throw new ParserException("No valid tracks were found");
                    }
                    c35962.f10745.mo5892();
                    return;
                }
                if (i == 475249515 && !c35962.f10714) {
                    InterfaceC3562 interfaceC3562 = c35962.f10745;
                    if (c35962.f10709 == -1 || c35962.f10712 == -9223372036854775807L || (c4132 = c35962.f10721) == null || (i9 = c4132.f13197) == 0 || (c41322 = c35962.f10722) == null || c41322.f13197 != i9) {
                        c35962.f10721 = null;
                        c35962.f10722 = null;
                        c3573 = new InterfaceC3571.C3573(c35962.f10712, 0L);
                    } else {
                        int[] iArrCopyOf = new int[i9];
                        long[] jArrCopyOf = new long[i9];
                        long[] jArrCopyOf2 = new long[i9];
                        long[] jArrCopyOf3 = new long[i9];
                        for (int i19 = 0; i19 < i9; i19++) {
                            jArrCopyOf3[i19] = c35962.f10721.m6647(i19);
                            jArrCopyOf[i19] = c35962.f10722.m6647(i19) + c35962.f10709;
                        }
                        while (true) {
                            i10 = i9 - 1;
                            if (i11 >= i10) {
                                break;
                            }
                            int i20 = i11 + 1;
                            iArrCopyOf[i11] = (int) (jArrCopyOf[i20] - jArrCopyOf[i11]);
                            jArrCopyOf2[i11] = jArrCopyOf3[i20] - jArrCopyOf3[i11];
                            i11 = i20;
                        }
                        iArrCopyOf[i10] = (int) ((c35962.f10709 + c35962.f10708) - jArrCopyOf[i10]);
                        jArrCopyOf2[i10] = c35962.f10712 - jArrCopyOf3[i10];
                        long j4 = jArrCopyOf2[i10];
                        if (j4 <= 0) {
                            Log.w("MatroskaExtractor", "Discarding last cue point with unexpected duration: " + j4);
                            iArrCopyOf = Arrays.copyOf(iArrCopyOf, i10);
                            jArrCopyOf = Arrays.copyOf(jArrCopyOf, i10);
                            jArrCopyOf2 = Arrays.copyOf(jArrCopyOf2, i10);
                            jArrCopyOf3 = Arrays.copyOf(jArrCopyOf3, i10);
                        }
                        c35962.f10721 = null;
                        c35962.f10722 = null;
                        c3573 = new C3556(iArrCopyOf, jArrCopyOf, jArrCopyOf2, jArrCopyOf3);
                    }
                    interfaceC3562.mo5893(c3573);
                    c35962.f10714 = true;
                    return;
                }
                return;
            }
            String str13 = c35962.f10713.f10748;
            String str14 = "S_VOBSUB";
            String str15 = "A_TRUEHD";
            if (!"V_VP8".equals(str13) && !"V_VP9".equals(str13) && !"V_AV1".equals(str13) && !"V_MPEG2".equals(str13) && !"V_MPEG4/ISO/SP".equals(str13) && !"V_MPEG4/ISO/ASP".equals(str13) && !"V_MPEG4/ISO/AP".equals(str13) && !"V_MPEG4/ISO/AVC".equals(str13) && !"V_MPEGH/ISO/HEVC".equals(str13) && !"V_MS/VFW/FOURCC".equals(str13) && !"V_THEORA".equals(str13) && !"A_OPUS".equals(str13) && !"A_VORBIS".equals(str13) && !"A_AAC".equals(str13)) {
                if ("A_MPEG/L2".equals(str13)) {
                    obj5 = "V_MPEG4/ISO/AP";
                    str4 = "S_DVBSUB";
                    obj4 = "A_MPEG/L2";
                    str = "A_DTS/EXPRESS";
                    obj = "A_MPEG/L3";
                    obj2 = "V_MPEG4/ISO/SP";
                    str2 = "A_AC3";
                    obj3 = "A_VORBIS";
                    str3 = "A_DTS";
                    obj6 = "A_MS/ACM";
                    str5 = "S_TEXT/UTF8";
                    obj7 = "V_MPEG4/ISO/ASP";
                    str6 = "S_TEXT/ASS";
                    obj8 = "V_MPEG4/ISO/AVC";
                    str7 = "S_HDMV/PGS";
                    obj9 = "A_DTS/LOSSLESS";
                    obj10 = "V_MS/VFW/FOURCC";
                    str8 = "A_PCM/INT/LIT";
                } else {
                    obj5 = "V_MPEG4/ISO/AP";
                    if ("A_MPEG/L3".equals(str13)) {
                        obj2 = "V_MPEG4/ISO/SP";
                        str2 = "A_AC3";
                    } else {
                        obj2 = "V_MPEG4/ISO/SP";
                        str2 = "A_AC3";
                        if (!str2.equals(str13)) {
                            obj3 = "A_VORBIS";
                            if (!"A_EAC3".equals(str13)) {
                                if (str15.equals(str13)) {
                                    str15 = str15;
                                } else {
                                    str15 = str15;
                                    str3 = "A_DTS";
                                    if (str3.equals(str13)) {
                                        obj4 = "A_MPEG/L2";
                                        str = "A_DTS/EXPRESS";
                                    } else {
                                        obj4 = "A_MPEG/L2";
                                        str = "A_DTS/EXPRESS";
                                        if (!str.equals(str13)) {
                                            obj = "A_MPEG/L3";
                                            if ("A_DTS/LOSSLESS".equals(str13)) {
                                                obj10 = "V_MS/VFW/FOURCC";
                                            } else {
                                                obj10 = "V_MS/VFW/FOURCC";
                                                if (!"A_FLAC".equals(str13) && !"A_MS/ACM".equals(str13)) {
                                                    str8 = "A_PCM/INT/LIT";
                                                    if (!str8.equals(str13)) {
                                                        obj6 = "A_MS/ACM";
                                                        str5 = "S_TEXT/UTF8";
                                                        if (!str5.equals(str13)) {
                                                            obj7 = "V_MPEG4/ISO/ASP";
                                                            str6 = "S_TEXT/ASS";
                                                            if (!str6.equals(str13)) {
                                                                obj8 = "V_MPEG4/ISO/AVC";
                                                                if (str14.equals(str13)) {
                                                                    str14 = str14;
                                                                } else {
                                                                    str14 = str14;
                                                                    str7 = "S_HDMV/PGS";
                                                                    if (str7.equals(str13)) {
                                                                        obj9 = "A_DTS/LOSSLESS";
                                                                        str4 = "S_DVBSUB";
                                                                    } else {
                                                                        obj9 = "A_DTS/LOSSLESS";
                                                                        str4 = "S_DVBSUB";
                                                                        if (!str4.equals(str13)) {
                                                                            z = false;
                                                                        }
                                                                    }
                                                                }
                                                            }
                                                            str7 = "S_HDMV/PGS";
                                                            obj9 = "A_DTS/LOSSLESS";
                                                            str4 = "S_DVBSUB";
                                                        }
                                                        obj8 = "V_MPEG4/ISO/AVC";
                                                        str7 = "S_HDMV/PGS";
                                                        obj9 = "A_DTS/LOSSLESS";
                                                        str4 = "S_DVBSUB";
                                                    }
                                                    obj7 = "V_MPEG4/ISO/ASP";
                                                    str6 = "S_TEXT/ASS";
                                                    obj8 = "V_MPEG4/ISO/AVC";
                                                    str7 = "S_HDMV/PGS";
                                                    obj9 = "A_DTS/LOSSLESS";
                                                    str4 = "S_DVBSUB";
                                                }
                                                obj6 = "A_MS/ACM";
                                                str5 = "S_TEXT/UTF8";
                                                obj7 = "V_MPEG4/ISO/ASP";
                                                str6 = "S_TEXT/ASS";
                                                obj8 = "V_MPEG4/ISO/AVC";
                                                str7 = "S_HDMV/PGS";
                                                obj9 = "A_DTS/LOSSLESS";
                                                str4 = "S_DVBSUB";
                                            }
                                            str8 = "A_PCM/INT/LIT";
                                            obj6 = "A_MS/ACM";
                                            str5 = "S_TEXT/UTF8";
                                            obj7 = "V_MPEG4/ISO/ASP";
                                            str6 = "S_TEXT/ASS";
                                            obj8 = "V_MPEG4/ISO/AVC";
                                            str7 = "S_HDMV/PGS";
                                            obj9 = "A_DTS/LOSSLESS";
                                            str4 = "S_DVBSUB";
                                        }
                                    }
                                    obj = "A_MPEG/L3";
                                }
                            }
                            if (z) {
                                String str16 = str4;
                                C3599 c35994 = c35962.f10713;
                                InterfaceC3562 interfaceC35622 = c35962.f10745;
                                int i21 = c35994.f10749;
                                String str17 = c35994.f10748;
                                switch (str17.hashCode()) {
                                    case -2095576542:
                                        b = str17.equals(obj5) ? (byte) 6 : (byte) -1;
                                        break;
                                    case -2095575984:
                                        if (str17.equals(obj2)) {
                                            b = 4;
                                            break;
                                        }
                                        break;
                                    case -1985379776:
                                        if (str17.equals(obj6)) {
                                            b = 23;
                                            break;
                                        }
                                        break;
                                    case -1784763192:
                                        if (str17.equals(str15)) {
                                            b = 18;
                                            break;
                                        }
                                        break;
                                    case -1730367663:
                                        if (str17.equals(obj3)) {
                                            b = 11;
                                            break;
                                        }
                                        break;
                                    case -1482641358:
                                        if (str17.equals(obj4)) {
                                            b = 14;
                                            break;
                                        }
                                        break;
                                    case -1482641357:
                                        if (str17.equals(obj)) {
                                            b = 15;
                                            break;
                                        }
                                        break;
                                    case -1373388978:
                                        if (str17.equals(obj10)) {
                                            b = 9;
                                            break;
                                        }
                                        break;
                                    case -933872740:
                                        if (str17.equals(str16)) {
                                            b = 29;
                                            break;
                                        }
                                        break;
                                    case -538363189:
                                        if (str17.equals(obj7)) {
                                            b = 5;
                                            break;
                                        }
                                        break;
                                    case -538363109:
                                        if (str17.equals(obj8)) {
                                            b = 7;
                                            break;
                                        }
                                        break;
                                    case -425012669:
                                        if (str17.equals(str14)) {
                                            b = 27;
                                            break;
                                        }
                                        break;
                                    case -356037306:
                                        if (str17.equals(obj9)) {
                                            b = 21;
                                            break;
                                        }
                                        break;
                                    case 62923557:
                                        if (str17.equals("A_AAC")) {
                                            b = 13;
                                            break;
                                        }
                                        break;
                                    case 62923603:
                                        if (str17.equals(str2)) {
                                            b = 16;
                                            break;
                                        }
                                        break;
                                    case 62927045:
                                        if (str17.equals(str3)) {
                                            b = 19;
                                            break;
                                        }
                                        break;
                                    case 82318131:
                                        if (str17.equals("V_AV1")) {
                                            b = 2;
                                            break;
                                        }
                                        break;
                                    case 82338133:
                                        if (str17.equals("V_VP8")) {
                                            b = 0;
                                            break;
                                        }
                                        break;
                                    case 82338134:
                                        if (str17.equals("V_VP9")) {
                                            b = 1;
                                            break;
                                        }
                                        break;
                                    case 99146302:
                                        if (str17.equals(str7)) {
                                            b = 28;
                                            break;
                                        }
                                        break;
                                    case 444813526:
                                        if (str17.equals("V_THEORA")) {
                                            b = 10;
                                            break;
                                        }
                                        break;
                                    case 542569478:
                                        if (str17.equals(str)) {
                                            b = 20;
                                            break;
                                        }
                                        break;
                                    case 725957860:
                                        if (str17.equals(str8)) {
                                            b = 24;
                                            break;
                                        }
                                        break;
                                    case 738597099:
                                        if (str17.equals(str6)) {
                                            b = 26;
                                            break;
                                        }
                                        break;
                                    case 855502857:
                                        if (str17.equals("V_MPEGH/ISO/HEVC")) {
                                            b = 8;
                                            break;
                                        }
                                        break;
                                    case 1422270023:
                                        if (str17.equals(str5)) {
                                            b = 25;
                                            break;
                                        }
                                        break;
                                    case 1809237540:
                                        if (str17.equals("V_MPEG2")) {
                                            b = 3;
                                            break;
                                        }
                                        break;
                                    case 1950749482:
                                        if (str17.equals("A_EAC3")) {
                                            b = 17;
                                            break;
                                        }
                                        break;
                                    case 1950789798:
                                        if (str17.equals("A_FLAC")) {
                                            b = 22;
                                            break;
                                        }
                                        break;
                                    case 1951062397:
                                        if (str17.equals("A_OPUS")) {
                                            b = 12;
                                            break;
                                        }
                                        break;
                                }
                                String str18 = "video/x-unknown";
                                switch (b) {
                                    case 0:
                                        str9 = "video/x-vnd.on2.vp8";
                                        list = null;
                                        list3 = list;
                                        str10 = str9;
                                        iM6741 = -1;
                                        list2 = list3;
                                        i4 = iM6741;
                                        str12 = str10;
                                        i3 = -1;
                                        list4 = list2;
                                        int i22 = (c35994.f10792 ? 1 : 0) | 0 | (c35994.f10791 ? 2 : 0);
                                        if (C4134.m6657(str12)) {
                                            c3431M5588 = C3431.m5584(Integer.toString(i21), str12, (String) null, -1, i3, c35994.f10785, c35994.f10787, i4, (List<byte[]>) list4, c35994.f10757, i22, c35994.f10793);
                                            i5 = 1;
                                        } else if (C4134.m6659(str12)) {
                                            if (c35994.f10762 == 0) {
                                                int i23 = c35994.f10760;
                                                i6 = -1;
                                                if (i23 == -1) {
                                                    i23 = c35994.f10758;
                                                }
                                                c35994.f10760 = i23;
                                                int i24 = c35994.f10761;
                                                if (i24 == -1) {
                                                    i24 = c35994.f10759;
                                                }
                                                c35994.f10761 = i24;
                                            } else {
                                                i6 = -1;
                                            }
                                            float f = (c35994.f10760 == i6 || (i8 = c35994.f10761) == i6) ? -1.0f : (c35994.f10759 * r0) / (c35994.f10758 * i8);
                                            if (c35994.f10769) {
                                                if (c35994.f10775 == -1.0f || c35994.f10776 == -1.0f || c35994.f10777 == -1.0f || c35994.f10778 == -1.0f || c35994.f10779 == -1.0f || c35994.f10780 == -1.0f || c35994.f10781 == -1.0f || c35994.f10782 == -1.0f || c35994.f10783 == -1.0f || c35994.f10784 == -1.0f) {
                                                    bArr = null;
                                                } else {
                                                    bArr = new byte[25];
                                                    ByteBuffer byteBufferOrder = ByteBuffer.wrap(bArr).order(ByteOrder.LITTLE_ENDIAN);
                                                    byteBufferOrder.put((byte) 0);
                                                    byteBufferOrder.putShort((short) ((c35994.f10775 * 50000.0f) + 0.5f));
                                                    byteBufferOrder.putShort((short) ((c35994.f10776 * 50000.0f) + 0.5f));
                                                    byteBufferOrder.putShort((short) ((c35994.f10777 * 50000.0f) + 0.5f));
                                                    byteBufferOrder.putShort((short) ((c35994.f10778 * 50000.0f) + 0.5f));
                                                    byteBufferOrder.putShort((short) ((c35994.f10779 * 50000.0f) + 0.5f));
                                                    byteBufferOrder.putShort((short) ((c35994.f10780 * 50000.0f) + 0.5f));
                                                    byteBufferOrder.putShort((short) ((c35994.f10781 * 50000.0f) + 0.5f));
                                                    byteBufferOrder.putShort((short) ((c35994.f10782 * 50000.0f) + 0.5f));
                                                    byteBufferOrder.putShort((short) (c35994.f10783 + 0.5f));
                                                    byteBufferOrder.putShort((short) (c35994.f10784 + 0.5f));
                                                    byteBufferOrder.putShort((short) c35994.f10773);
                                                    byteBufferOrder.putShort((short) c35994.f10774);
                                                }
                                                c4159 = new C4159(c35994.f10770, c35994.f10772, c35994.f10771, bArr);
                                            } else {
                                                c4159 = null;
                                            }
                                            int i25 = "htc_video_rotA-000".equals(c35994.f10747) ? 0 : "htc_video_rotA-090".equals(c35994.f10747) ? 90 : "htc_video_rotA-180".equals(c35994.f10747) ? 180 : "htc_video_rotA-270".equals(c35994.f10747) ? 270 : -1;
                                            if (c35994.f10763 == 0 && Float.compare(c35994.f10764, 0.0f) == 0 && Float.compare(c35994.f10765, 0.0f) == 0) {
                                                if (Float.compare(c35994.f10766, 0.0f) == 0) {
                                                    i7 = 0;
                                                } else if (Float.compare(c35994.f10765, 90.0f) == 0) {
                                                    i7 = 90;
                                                } else if (Float.compare(c35994.f10765, -180.0f) == 0 || Float.compare(c35994.f10765, 180.0f) == 0) {
                                                    i7 = 180;
                                                } else if (Float.compare(c35994.f10765, -90.0f) == 0) {
                                                    i7 = 270;
                                                }
                                                c3431M5588 = C3431.m5582(Integer.toString(i21), str12, (String) null, -1, i3, c35994.f10758, c35994.f10759, -1.0f, (List<byte[]>) list4, i7, f, c35994.f10767, c35994.f10768, c4159, c35994.f10757);
                                                i5 = 2;
                                            } else {
                                                i7 = i25;
                                                c3431M5588 = C3431.m5582(Integer.toString(i21), str12, (String) null, -1, i3, c35994.f10758, c35994.f10759, -1.0f, (List<byte[]>) list4, i7, f, c35994.f10767, c35994.f10768, c4159, c35994.f10757);
                                                i5 = 2;
                                            }
                                        } else {
                                            if ("application/x-subrip".equals(str12)) {
                                                c3431M5588 = C3431.m5579(Integer.toString(i21), str12, i22, c35994.f10793, c35994.f10757);
                                            } else if ("text/x-ssa".equals(str12)) {
                                                ArrayList arrayList2 = new ArrayList(2);
                                                arrayList2.add(C3596.f10690);
                                                arrayList2.add(c35994.f10756);
                                                c3431M5588 = C3431.m5586(Integer.toString(i21), str12, (String) null, -1, i22, c35994.f10793, -1, c35994.f10757, Long.MAX_VALUE, arrayList2);
                                            } else {
                                                if (!"application/vobsub".equals(str12) && !"application/pgs".equals(str12) && !"application/dvbsubs".equals(str12)) {
                                                    throw new ParserException("Unexpected MIME type.");
                                                }
                                                c3431M5588 = C3431.m5588(Integer.toString(i21), str12, (String) null, -1, i22, (List<byte[]>) list4, c35994.f10793, c35994.f10757);
                                            }
                                            i5 = 3;
                                        }
                                        InterfaceC3575 interfaceC3575Mo5891 = interfaceC35622.mo5891(c35994.f10749, i5);
                                        c35994.f10794 = interfaceC3575Mo5891;
                                        interfaceC3575Mo5891.mo5884(c3431M5588);
                                        c3596 = c35962;
                                        SparseArray<C3599> sparseArray = c3596.f10695;
                                        C3599 c35995 = c3596.f10713;
                                        sparseArray.put(c35995.f10749, c35995);
                                        break;
                                    case 1:
                                        str9 = "video/x-vnd.on2.vp9";
                                        list = null;
                                        list3 = list;
                                        str10 = str9;
                                        iM6741 = -1;
                                        list2 = list3;
                                        i4 = iM6741;
                                        str12 = str10;
                                        i3 = -1;
                                        list4 = list2;
                                        int i222 = (c35994.f10792 ? 1 : 0) | 0 | (c35994.f10791 ? 2 : 0);
                                        if (C4134.m6657(str12)) {
                                        }
                                        InterfaceC3575 interfaceC3575Mo58912 = interfaceC35622.mo5891(c35994.f10749, i5);
                                        c35994.f10794 = interfaceC3575Mo58912;
                                        interfaceC3575Mo58912.mo5884(c3431M5588);
                                        c3596 = c35962;
                                        SparseArray<C3599> sparseArray2 = c3596.f10695;
                                        C3599 c359952 = c3596.f10713;
                                        sparseArray2.put(c359952.f10749, c359952);
                                        break;
                                    case 2:
                                        str9 = "video/av01";
                                        list = null;
                                        list3 = list;
                                        str10 = str9;
                                        iM6741 = -1;
                                        list2 = list3;
                                        i4 = iM6741;
                                        str12 = str10;
                                        i3 = -1;
                                        list4 = list2;
                                        int i2222 = (c35994.f10792 ? 1 : 0) | 0 | (c35994.f10791 ? 2 : 0);
                                        if (C4134.m6657(str12)) {
                                        }
                                        InterfaceC3575 interfaceC3575Mo589122 = interfaceC35622.mo5891(c35994.f10749, i5);
                                        c35994.f10794 = interfaceC3575Mo589122;
                                        interfaceC3575Mo589122.mo5884(c3431M5588);
                                        c3596 = c35962;
                                        SparseArray<C3599> sparseArray22 = c3596.f10695;
                                        C3599 c3599522 = c3596.f10713;
                                        sparseArray22.put(c3599522.f10749, c3599522);
                                        break;
                                    case 3:
                                        str9 = "video/mpeg2";
                                        list = null;
                                        list3 = list;
                                        str10 = str9;
                                        iM6741 = -1;
                                        list2 = list3;
                                        i4 = iM6741;
                                        str12 = str10;
                                        i3 = -1;
                                        list4 = list2;
                                        int i22222 = (c35994.f10792 ? 1 : 0) | 0 | (c35994.f10791 ? 2 : 0);
                                        if (C4134.m6657(str12)) {
                                        }
                                        InterfaceC3575 interfaceC3575Mo5891222 = interfaceC35622.mo5891(c35994.f10749, i5);
                                        c35994.f10794 = interfaceC3575Mo5891222;
                                        interfaceC3575Mo5891222.mo5884(c3431M5588);
                                        c3596 = c35962;
                                        SparseArray<C3599> sparseArray222 = c3596.f10695;
                                        C3599 c35995222 = c3596.f10713;
                                        sparseArray222.put(c35995222.f10749, c35995222);
                                        break;
                                    case 4:
                                    case 5:
                                    case 6:
                                        byte[] bArr2 = c35994.f10756;
                                        listSingletonList = bArr2 == null ? null : Collections.singletonList(bArr2);
                                        str10 = "video/mp4v-es";
                                        list3 = listSingletonList;
                                        iM6741 = -1;
                                        list2 = list3;
                                        i4 = iM6741;
                                        str12 = str10;
                                        i3 = -1;
                                        list4 = list2;
                                        int i222222 = (c35994.f10792 ? 1 : 0) | 0 | (c35994.f10791 ? 2 : 0);
                                        if (C4134.m6657(str12)) {
                                        }
                                        InterfaceC3575 interfaceC3575Mo58912222 = interfaceC35622.mo5891(c35994.f10749, i5);
                                        c35994.f10794 = interfaceC3575Mo58912222;
                                        interfaceC3575Mo58912222.mo5884(c3431M5588);
                                        c3596 = c35962;
                                        SparseArray<C3599> sparseArray2222 = c3596.f10695;
                                        C3599 c359952222 = c3596.f10713;
                                        sparseArray2222.put(c359952222.f10749, c359952222);
                                        break;
                                    case 7:
                                        C4158 c4158M6812 = C4158.m6812(new C4140(c35994.f10756));
                                        list = c4158M6812.f13292;
                                        c35994.f10795 = c4158M6812.f13293;
                                        str9 = "video/avc";
                                        list3 = list;
                                        str10 = str9;
                                        iM6741 = -1;
                                        list2 = list3;
                                        i4 = iM6741;
                                        str12 = str10;
                                        i3 = -1;
                                        list4 = list2;
                                        int i2222222 = (c35994.f10792 ? 1 : 0) | 0 | (c35994.f10791 ? 2 : 0);
                                        if (C4134.m6657(str12)) {
                                        }
                                        InterfaceC3575 interfaceC3575Mo589122222 = interfaceC35622.mo5891(c35994.f10749, i5);
                                        c35994.f10794 = interfaceC3575Mo589122222;
                                        interfaceC3575Mo589122222.mo5884(c3431M5588);
                                        c3596 = c35962;
                                        SparseArray<C3599> sparseArray22222 = c3596.f10695;
                                        C3599 c3599522222 = c3596.f10713;
                                        sparseArray22222.put(c3599522222.f10749, c3599522222);
                                        break;
                                    case 8:
                                        C4165 c4165M6819 = C4165.m6819(new C4140(c35994.f10756));
                                        list = c4165M6819.f13312;
                                        c35994.f10795 = c4165M6819.f13313;
                                        str9 = "video/hevc";
                                        list3 = list;
                                        str10 = str9;
                                        iM6741 = -1;
                                        list2 = list3;
                                        i4 = iM6741;
                                        str12 = str10;
                                        i3 = -1;
                                        list4 = list2;
                                        int i22222222 = (c35994.f10792 ? 1 : 0) | 0 | (c35994.f10791 ? 2 : 0);
                                        if (C4134.m6657(str12)) {
                                        }
                                        InterfaceC3575 interfaceC3575Mo5891222222 = interfaceC35622.mo5891(c35994.f10749, i5);
                                        c35994.f10794 = interfaceC3575Mo5891222222;
                                        interfaceC3575Mo5891222222.mo5884(c3431M5588);
                                        c3596 = c35962;
                                        SparseArray<C3599> sparseArray222222 = c3596.f10695;
                                        C3599 c35995222222 = c3596.f10713;
                                        sparseArray222222.put(c35995222222.f10749, c35995222222);
                                        break;
                                    case 9:
                                        C4140 c4140 = new C4140(c35994.f10756);
                                        try {
                                            c4140.m6695(16);
                                            long jM6696 = c4140.m6696();
                                            if (jM6696 == 1482049860) {
                                                pair = new Pair("video/divx", null);
                                            } else if (jM6696 == 859189832) {
                                                pair = new Pair("video/3gpp", null);
                                            } else {
                                                if (jM6696 == 826496599) {
                                                    byte[] bArr3 = c4140.f13227;
                                                    for (int i26 = c4140.f13228 + 20; i26 < bArr3.length - 4; i26++) {
                                                        if (bArr3[i26] == 0 && bArr3[i26 + 1] == 0 && bArr3[i26 + 2] == 1 && bArr3[i26 + 3] == 15) {
                                                            pair = new Pair("video/wvc1", Collections.singletonList(Arrays.copyOfRange(bArr3, i26, bArr3.length)));
                                                        }
                                                    }
                                                    throw new ParserException("Failed to find FourCC VC1 initialization data");
                                                }
                                                Log.w("MatroskaExtractor", "Unknown FourCC. Setting mimeType to video/x-unknown");
                                                pair = new Pair("video/x-unknown", null);
                                            }
                                            str10 = (String) pair.first;
                                            listSingletonList = (List) pair.second;
                                            list3 = listSingletonList;
                                            iM6741 = -1;
                                            list2 = list3;
                                            i4 = iM6741;
                                            str12 = str10;
                                            i3 = -1;
                                            list4 = list2;
                                            int i222222222 = (c35994.f10792 ? 1 : 0) | 0 | (c35994.f10791 ? 2 : 0);
                                            if (C4134.m6657(str12)) {
                                            }
                                            InterfaceC3575 interfaceC3575Mo58912222222 = interfaceC35622.mo5891(c35994.f10749, i5);
                                            c35994.f10794 = interfaceC3575Mo58912222222;
                                            interfaceC3575Mo58912222222.mo5884(c3431M5588);
                                            c3596 = c35962;
                                            SparseArray<C3599> sparseArray2222222 = c3596.f10695;
                                            C3599 c359952222222 = c3596.f10713;
                                            sparseArray2222222.put(c359952222222.f10749, c359952222222);
                                        } catch (ArrayIndexOutOfBoundsException unused) {
                                            throw new ParserException("Error parsing FourCC private data");
                                        }
                                        break;
                                    case 10:
                                        listSingletonList = null;
                                        str10 = str18;
                                        list3 = listSingletonList;
                                        iM6741 = -1;
                                        list2 = list3;
                                        i4 = iM6741;
                                        str12 = str10;
                                        i3 = -1;
                                        list4 = list2;
                                        int i2222222222 = (c35994.f10792 ? 1 : 0) | 0 | (c35994.f10791 ? 2 : 0);
                                        if (C4134.m6657(str12)) {
                                        }
                                        InterfaceC3575 interfaceC3575Mo589122222222 = interfaceC35622.mo5891(c35994.f10749, i5);
                                        c35994.f10794 = interfaceC3575Mo589122222222;
                                        interfaceC3575Mo589122222222.mo5884(c3431M5588);
                                        c3596 = c35962;
                                        SparseArray<C3599> sparseArray22222222 = c3596.f10695;
                                        C3599 c3599522222222 = c3596.f10713;
                                        sparseArray22222222.put(c3599522222222.f10749, c3599522222222);
                                        break;
                                    case 11:
                                        byte[] bArr4 = c35994.f10756;
                                        try {
                                            if (bArr4[0] != 2) {
                                                throw new ParserException("Error parsing vorbis codec private");
                                            }
                                            int i27 = 1;
                                            int i28 = 0;
                                            while (bArr4[i27] == -1) {
                                                i28 += 255;
                                                i27++;
                                            }
                                            int i29 = i27 + 1;
                                            int i30 = i28 + bArr4[i27];
                                            int i31 = 0;
                                            while (bArr4[i29] == -1) {
                                                i31 += 255;
                                                i29++;
                                            }
                                            int i32 = i29 + 1;
                                            int i33 = i31 + bArr4[i29];
                                            if (bArr4[i32] != 1) {
                                                throw new ParserException("Error parsing vorbis codec private");
                                            }
                                            byte[] bArr5 = new byte[i30];
                                            System.arraycopy(bArr4, i32, bArr5, 0, i30);
                                            int i34 = i32 + i30;
                                            if (bArr4[i34] != 3) {
                                                throw new ParserException("Error parsing vorbis codec private");
                                            }
                                            int i35 = i34 + i33;
                                            if (bArr4[i35] != 5) {
                                                throw new ParserException("Error parsing vorbis codec private");
                                            }
                                            byte[] bArr6 = new byte[bArr4.length - i35];
                                            System.arraycopy(bArr4, i35, bArr6, 0, bArr4.length - i35);
                                            ArrayList arrayList3 = new ArrayList(2);
                                            arrayList3.add(bArr5);
                                            arrayList3.add(bArr6);
                                            i2 = 8192;
                                            arrayList = arrayList3;
                                            str11 = "audio/vorbis";
                                            str12 = str11;
                                            i3 = i2;
                                            i4 = -1;
                                            list4 = arrayList;
                                            int i22222222222 = (c35994.f10792 ? 1 : 0) | 0 | (c35994.f10791 ? 2 : 0);
                                            if (C4134.m6657(str12)) {
                                            }
                                            InterfaceC3575 interfaceC3575Mo5891222222222 = interfaceC35622.mo5891(c35994.f10749, i5);
                                            c35994.f10794 = interfaceC3575Mo5891222222222;
                                            interfaceC3575Mo5891222222222.mo5884(c3431M5588);
                                            c3596 = c35962;
                                            SparseArray<C3599> sparseArray222222222 = c3596.f10695;
                                            C3599 c35995222222222 = c3596.f10713;
                                            sparseArray222222222.put(c35995222222222.f10749, c35995222222222);
                                        } catch (ArrayIndexOutOfBoundsException unused2) {
                                            throw new ParserException("Error parsing vorbis codec private");
                                        }
                                        break;
                                    case 12:
                                        ArrayList arrayList4 = new ArrayList(3);
                                        arrayList4.add(c35994.f10756);
                                        arrayList4.add(ByteBuffer.allocate(8).order(ByteOrder.LITTLE_ENDIAN).putLong(c35994.f10788).array());
                                        arrayList4.add(ByteBuffer.allocate(8).order(ByteOrder.LITTLE_ENDIAN).putLong(c35994.f10789).array());
                                        i2 = 5760;
                                        str11 = "audio/opus";
                                        arrayList = arrayList4;
                                        str12 = str11;
                                        i3 = i2;
                                        i4 = -1;
                                        list4 = arrayList;
                                        int i222222222222 = (c35994.f10792 ? 1 : 0) | 0 | (c35994.f10791 ? 2 : 0);
                                        if (C4134.m6657(str12)) {
                                        }
                                        InterfaceC3575 interfaceC3575Mo58912222222222 = interfaceC35622.mo5891(c35994.f10749, i5);
                                        c35994.f10794 = interfaceC3575Mo58912222222222;
                                        interfaceC3575Mo58912222222222.mo5884(c3431M5588);
                                        c3596 = c35962;
                                        SparseArray<C3599> sparseArray2222222222 = c3596.f10695;
                                        C3599 c359952222222222 = c3596.f10713;
                                        sparseArray2222222222.put(c359952222222222.f10749, c359952222222222);
                                        break;
                                    case 13:
                                        listSingletonList = Collections.singletonList(c35994.f10756);
                                        str10 = "audio/mp4a-latm";
                                        list3 = listSingletonList;
                                        iM6741 = -1;
                                        list2 = list3;
                                        i4 = iM6741;
                                        str12 = str10;
                                        i3 = -1;
                                        list4 = list2;
                                        int i2222222222222 = (c35994.f10792 ? 1 : 0) | 0 | (c35994.f10791 ? 2 : 0);
                                        if (C4134.m6657(str12)) {
                                        }
                                        InterfaceC3575 interfaceC3575Mo589122222222222 = interfaceC35622.mo5891(c35994.f10749, i5);
                                        c35994.f10794 = interfaceC3575Mo589122222222222;
                                        interfaceC3575Mo589122222222222.mo5884(c3431M5588);
                                        c3596 = c35962;
                                        SparseArray<C3599> sparseArray22222222222 = c3596.f10695;
                                        C3599 c3599522222222222 = c3596.f10713;
                                        sparseArray22222222222.put(c3599522222222222.f10749, c3599522222222222);
                                        break;
                                    case 14:
                                        str11 = "audio/mpeg-L2";
                                        i2 = 4096;
                                        arrayList = null;
                                        str12 = str11;
                                        i3 = i2;
                                        i4 = -1;
                                        list4 = arrayList;
                                        int i22222222222222 = (c35994.f10792 ? 1 : 0) | 0 | (c35994.f10791 ? 2 : 0);
                                        if (C4134.m6657(str12)) {
                                        }
                                        InterfaceC3575 interfaceC3575Mo5891222222222222 = interfaceC35622.mo5891(c35994.f10749, i5);
                                        c35994.f10794 = interfaceC3575Mo5891222222222222;
                                        interfaceC3575Mo5891222222222222.mo5884(c3431M5588);
                                        c3596 = c35962;
                                        SparseArray<C3599> sparseArray222222222222 = c3596.f10695;
                                        C3599 c35995222222222222 = c3596.f10713;
                                        sparseArray222222222222.put(c35995222222222222.f10749, c35995222222222222);
                                        break;
                                    case 15:
                                        str11 = "audio/mpeg";
                                        i2 = 4096;
                                        arrayList = null;
                                        str12 = str11;
                                        i3 = i2;
                                        i4 = -1;
                                        list4 = arrayList;
                                        int i222222222222222 = (c35994.f10792 ? 1 : 0) | 0 | (c35994.f10791 ? 2 : 0);
                                        if (C4134.m6657(str12)) {
                                        }
                                        InterfaceC3575 interfaceC3575Mo58912222222222222 = interfaceC35622.mo5891(c35994.f10749, i5);
                                        c35994.f10794 = interfaceC3575Mo58912222222222222;
                                        interfaceC3575Mo58912222222222222.mo5884(c3431M5588);
                                        c3596 = c35962;
                                        SparseArray<C3599> sparseArray2222222222222 = c3596.f10695;
                                        C3599 c359952222222222222 = c3596.f10713;
                                        sparseArray2222222222222.put(c359952222222222222.f10749, c359952222222222222);
                                        break;
                                    case 16:
                                        str9 = "audio/ac3";
                                        list = null;
                                        list3 = list;
                                        str10 = str9;
                                        iM6741 = -1;
                                        list2 = list3;
                                        i4 = iM6741;
                                        str12 = str10;
                                        i3 = -1;
                                        list4 = list2;
                                        int i2222222222222222 = (c35994.f10792 ? 1 : 0) | 0 | (c35994.f10791 ? 2 : 0);
                                        if (C4134.m6657(str12)) {
                                        }
                                        InterfaceC3575 interfaceC3575Mo589122222222222222 = interfaceC35622.mo5891(c35994.f10749, i5);
                                        c35994.f10794 = interfaceC3575Mo589122222222222222;
                                        interfaceC3575Mo589122222222222222.mo5884(c3431M5588);
                                        c3596 = c35962;
                                        SparseArray<C3599> sparseArray22222222222222 = c3596.f10695;
                                        C3599 c3599522222222222222 = c3596.f10713;
                                        sparseArray22222222222222.put(c3599522222222222222.f10749, c3599522222222222222);
                                        break;
                                    case 17:
                                        str9 = "audio/eac3";
                                        list = null;
                                        list3 = list;
                                        str10 = str9;
                                        iM6741 = -1;
                                        list2 = list3;
                                        i4 = iM6741;
                                        str12 = str10;
                                        i3 = -1;
                                        list4 = list2;
                                        int i22222222222222222 = (c35994.f10792 ? 1 : 0) | 0 | (c35994.f10791 ? 2 : 0);
                                        if (C4134.m6657(str12)) {
                                        }
                                        InterfaceC3575 interfaceC3575Mo5891222222222222222 = interfaceC35622.mo5891(c35994.f10749, i5);
                                        c35994.f10794 = interfaceC3575Mo5891222222222222222;
                                        interfaceC3575Mo5891222222222222222.mo5884(c3431M5588);
                                        c3596 = c35962;
                                        SparseArray<C3599> sparseArray222222222222222 = c3596.f10695;
                                        C3599 c35995222222222222222 = c3596.f10713;
                                        sparseArray222222222222222.put(c35995222222222222222.f10749, c35995222222222222222);
                                        break;
                                    case 18:
                                        c35994.f10790 = new C3600();
                                        str9 = "audio/true-hd";
                                        list = null;
                                        list3 = list;
                                        str10 = str9;
                                        iM6741 = -1;
                                        list2 = list3;
                                        i4 = iM6741;
                                        str12 = str10;
                                        i3 = -1;
                                        list4 = list2;
                                        int i222222222222222222 = (c35994.f10792 ? 1 : 0) | 0 | (c35994.f10791 ? 2 : 0);
                                        if (C4134.m6657(str12)) {
                                        }
                                        InterfaceC3575 interfaceC3575Mo58912222222222222222 = interfaceC35622.mo5891(c35994.f10749, i5);
                                        c35994.f10794 = interfaceC3575Mo58912222222222222222;
                                        interfaceC3575Mo58912222222222222222.mo5884(c3431M5588);
                                        c3596 = c35962;
                                        SparseArray<C3599> sparseArray2222222222222222 = c3596.f10695;
                                        C3599 c359952222222222222222 = c3596.f10713;
                                        sparseArray2222222222222222.put(c359952222222222222222.f10749, c359952222222222222222);
                                        break;
                                    case 19:
                                    case 20:
                                        str9 = "audio/vnd.dts";
                                        list = null;
                                        list3 = list;
                                        str10 = str9;
                                        iM6741 = -1;
                                        list2 = list3;
                                        i4 = iM6741;
                                        str12 = str10;
                                        i3 = -1;
                                        list4 = list2;
                                        int i2222222222222222222 = (c35994.f10792 ? 1 : 0) | 0 | (c35994.f10791 ? 2 : 0);
                                        if (C4134.m6657(str12)) {
                                        }
                                        InterfaceC3575 interfaceC3575Mo589122222222222222222 = interfaceC35622.mo5891(c35994.f10749, i5);
                                        c35994.f10794 = interfaceC3575Mo589122222222222222222;
                                        interfaceC3575Mo589122222222222222222.mo5884(c3431M5588);
                                        c3596 = c35962;
                                        SparseArray<C3599> sparseArray22222222222222222 = c3596.f10695;
                                        C3599 c3599522222222222222222 = c3596.f10713;
                                        sparseArray22222222222222222.put(c3599522222222222222222.f10749, c3599522222222222222222);
                                        break;
                                    case 21:
                                        str9 = "audio/vnd.dts.hd";
                                        list = null;
                                        list3 = list;
                                        str10 = str9;
                                        iM6741 = -1;
                                        list2 = list3;
                                        i4 = iM6741;
                                        str12 = str10;
                                        i3 = -1;
                                        list4 = list2;
                                        int i22222222222222222222 = (c35994.f10792 ? 1 : 0) | 0 | (c35994.f10791 ? 2 : 0);
                                        if (C4134.m6657(str12)) {
                                        }
                                        InterfaceC3575 interfaceC3575Mo5891222222222222222222 = interfaceC35622.mo5891(c35994.f10749, i5);
                                        c35994.f10794 = interfaceC3575Mo5891222222222222222222;
                                        interfaceC3575Mo5891222222222222222222.mo5884(c3431M5588);
                                        c3596 = c35962;
                                        SparseArray<C3599> sparseArray222222222222222222 = c3596.f10695;
                                        C3599 c35995222222222222222222 = c3596.f10713;
                                        sparseArray222222222222222222.put(c35995222222222222222222.f10749, c35995222222222222222222);
                                        break;
                                    case 22:
                                        listSingletonList = Collections.singletonList(c35994.f10756);
                                        str10 = "audio/flac";
                                        list3 = listSingletonList;
                                        iM6741 = -1;
                                        list2 = list3;
                                        i4 = iM6741;
                                        str12 = str10;
                                        i3 = -1;
                                        list4 = list2;
                                        int i222222222222222222222 = (c35994.f10792 ? 1 : 0) | 0 | (c35994.f10791 ? 2 : 0);
                                        if (C4134.m6657(str12)) {
                                        }
                                        InterfaceC3575 interfaceC3575Mo58912222222222222222222 = interfaceC35622.mo5891(c35994.f10749, i5);
                                        c35994.f10794 = interfaceC3575Mo58912222222222222222222;
                                        interfaceC3575Mo58912222222222222222222.mo5884(c3431M5588);
                                        c3596 = c35962;
                                        SparseArray<C3599> sparseArray2222222222222222222 = c3596.f10695;
                                        C3599 c359952222222222222222222 = c3596.f10713;
                                        sparseArray2222222222222222222.put(c359952222222222222222222.f10749, c359952222222222222222222);
                                        break;
                                    case 23:
                                        C4140 c41402 = new C4140(c35994.f10756);
                                        try {
                                            int iM6698 = c41402.m6698();
                                            if (iM6698 != 1) {
                                                if (iM6698 == 65534) {
                                                    c41402.m6693(24);
                                                    if (c41402.m6699() == C3596.f10692.getMostSignificantBits()) {
                                                        if (c41402.m6699() == C3596.f10692.getLeastSignificantBits()) {
                                                        }
                                                        if (z2) {
                                                            iM6741 = C4150.m6741(c35994.f10786);
                                                            if (iM6741 == 0) {
                                                                StringBuilder sbM4889 = C2803.m4889("Unsupported PCM bit depth: ");
                                                                sbM4889.append(c35994.f10786);
                                                                sbM4889.append(". Setting mimeType to ");
                                                                sbM4889.append("audio/x-unknown");
                                                                Log.w("MatroskaExtractor", sbM4889.toString());
                                                            }
                                                            str10 = "audio/raw";
                                                            list2 = null;
                                                            i4 = iM6741;
                                                            str12 = str10;
                                                            i3 = -1;
                                                            list4 = list2;
                                                            int i2222222222222222222222 = (c35994.f10792 ? 1 : 0) | 0 | (c35994.f10791 ? 2 : 0);
                                                            if (C4134.m6657(str12)) {
                                                            }
                                                            InterfaceC3575 interfaceC3575Mo589122222222222222222222 = interfaceC35622.mo5891(c35994.f10749, i5);
                                                            c35994.f10794 = interfaceC3575Mo589122222222222222222222;
                                                            interfaceC3575Mo589122222222222222222222.mo5884(c3431M5588);
                                                            c3596 = c35962;
                                                            SparseArray<C3599> sparseArray22222222222222222222 = c3596.f10695;
                                                            C3599 c3599522222222222222222222 = c3596.f10713;
                                                            sparseArray22222222222222222222.put(c3599522222222222222222222.f10749, c3599522222222222222222222);
                                                        } else {
                                                            C2803.m4901("Non-PCM MS/ACM is unsupported. Setting mimeType to ", "audio/x-unknown", "MatroskaExtractor");
                                                        }
                                                        str18 = "audio/x-unknown";
                                                        listSingletonList = null;
                                                        str10 = str18;
                                                        list3 = listSingletonList;
                                                        iM6741 = -1;
                                                        list2 = list3;
                                                        i4 = iM6741;
                                                        str12 = str10;
                                                        i3 = -1;
                                                        list4 = list2;
                                                        int i22222222222222222222222 = (c35994.f10792 ? 1 : 0) | 0 | (c35994.f10791 ? 2 : 0);
                                                        if (C4134.m6657(str12)) {
                                                        }
                                                        InterfaceC3575 interfaceC3575Mo5891222222222222222222222 = interfaceC35622.mo5891(c35994.f10749, i5);
                                                        c35994.f10794 = interfaceC3575Mo5891222222222222222222222;
                                                        interfaceC3575Mo5891222222222222222222222.mo5884(c3431M5588);
                                                        c3596 = c35962;
                                                        SparseArray<C3599> sparseArray222222222222222222222 = c3596.f10695;
                                                        C3599 c35995222222222222222222222 = c3596.f10713;
                                                        sparseArray222222222222222222222.put(c35995222222222222222222222.f10749, c35995222222222222222222222);
                                                    }
                                                }
                                                z2 = false;
                                                if (z2) {
                                                }
                                                str18 = "audio/x-unknown";
                                                listSingletonList = null;
                                                str10 = str18;
                                                list3 = listSingletonList;
                                                iM6741 = -1;
                                                list2 = list3;
                                                i4 = iM6741;
                                                str12 = str10;
                                                i3 = -1;
                                                list4 = list2;
                                                int i222222222222222222222222 = (c35994.f10792 ? 1 : 0) | 0 | (c35994.f10791 ? 2 : 0);
                                                if (C4134.m6657(str12)) {
                                                }
                                                InterfaceC3575 interfaceC3575Mo58912222222222222222222222 = interfaceC35622.mo5891(c35994.f10749, i5);
                                                c35994.f10794 = interfaceC3575Mo58912222222222222222222222;
                                                interfaceC3575Mo58912222222222222222222222.mo5884(c3431M5588);
                                                c3596 = c35962;
                                                SparseArray<C3599> sparseArray2222222222222222222222 = c3596.f10695;
                                                C3599 c359952222222222222222222222 = c3596.f10713;
                                                sparseArray2222222222222222222222.put(c359952222222222222222222222.f10749, c359952222222222222222222222);
                                                break;
                                            }
                                            z2 = true;
                                            if (z2) {
                                            }
                                            str18 = "audio/x-unknown";
                                            listSingletonList = null;
                                            str10 = str18;
                                            list3 = listSingletonList;
                                            iM6741 = -1;
                                            list2 = list3;
                                            i4 = iM6741;
                                            str12 = str10;
                                            i3 = -1;
                                            list4 = list2;
                                            int i2222222222222222222222222 = (c35994.f10792 ? 1 : 0) | 0 | (c35994.f10791 ? 2 : 0);
                                            if (C4134.m6657(str12)) {
                                            }
                                            InterfaceC3575 interfaceC3575Mo589122222222222222222222222 = interfaceC35622.mo5891(c35994.f10749, i5);
                                            c35994.f10794 = interfaceC3575Mo589122222222222222222222222;
                                            interfaceC3575Mo589122222222222222222222222.mo5884(c3431M5588);
                                            c3596 = c35962;
                                            SparseArray<C3599> sparseArray22222222222222222222222 = c3596.f10695;
                                            C3599 c3599522222222222222222222222 = c3596.f10713;
                                            sparseArray22222222222222222222222.put(c3599522222222222222222222222.f10749, c3599522222222222222222222222);
                                        } catch (ArrayIndexOutOfBoundsException unused3) {
                                            throw new ParserException("Error parsing MS/ACM codec private");
                                        }
                                        break;
                                    case 24:
                                        iM6741 = C4150.m6741(c35994.f10786);
                                        if (iM6741 == 0) {
                                            StringBuilder sbM48892 = C2803.m4889("Unsupported PCM bit depth: ");
                                            sbM48892.append(c35994.f10786);
                                            sbM48892.append(". Setting mimeType to ");
                                            sbM48892.append("audio/x-unknown");
                                            Log.w("MatroskaExtractor", sbM48892.toString());
                                            str18 = "audio/x-unknown";
                                            listSingletonList = null;
                                            str10 = str18;
                                            list3 = listSingletonList;
                                            iM6741 = -1;
                                            list2 = list3;
                                            i4 = iM6741;
                                            str12 = str10;
                                            i3 = -1;
                                            list4 = list2;
                                            int i22222222222222222222222222 = (c35994.f10792 ? 1 : 0) | 0 | (c35994.f10791 ? 2 : 0);
                                            if (C4134.m6657(str12)) {
                                            }
                                            InterfaceC3575 interfaceC3575Mo5891222222222222222222222222 = interfaceC35622.mo5891(c35994.f10749, i5);
                                            c35994.f10794 = interfaceC3575Mo5891222222222222222222222222;
                                            interfaceC3575Mo5891222222222222222222222222.mo5884(c3431M5588);
                                            c3596 = c35962;
                                            SparseArray<C3599> sparseArray222222222222222222222222 = c3596.f10695;
                                            C3599 c35995222222222222222222222222 = c3596.f10713;
                                            sparseArray222222222222222222222222.put(c35995222222222222222222222222.f10749, c35995222222222222222222222222);
                                        }
                                        str10 = "audio/raw";
                                        list2 = null;
                                        i4 = iM6741;
                                        str12 = str10;
                                        i3 = -1;
                                        list4 = list2;
                                        int i222222222222222222222222222 = (c35994.f10792 ? 1 : 0) | 0 | (c35994.f10791 ? 2 : 0);
                                        if (C4134.m6657(str12)) {
                                        }
                                        InterfaceC3575 interfaceC3575Mo58912222222222222222222222222 = interfaceC35622.mo5891(c35994.f10749, i5);
                                        c35994.f10794 = interfaceC3575Mo58912222222222222222222222222;
                                        interfaceC3575Mo58912222222222222222222222222.mo5884(c3431M5588);
                                        c3596 = c35962;
                                        SparseArray<C3599> sparseArray2222222222222222222222222 = c3596.f10695;
                                        C3599 c359952222222222222222222222222 = c3596.f10713;
                                        sparseArray2222222222222222222222222.put(c359952222222222222222222222222.f10749, c359952222222222222222222222222);
                                        break;
                                    case 25:
                                        str18 = "application/x-subrip";
                                        listSingletonList = null;
                                        str10 = str18;
                                        list3 = listSingletonList;
                                        iM6741 = -1;
                                        list2 = list3;
                                        i4 = iM6741;
                                        str12 = str10;
                                        i3 = -1;
                                        list4 = list2;
                                        int i2222222222222222222222222222 = (c35994.f10792 ? 1 : 0) | 0 | (c35994.f10791 ? 2 : 0);
                                        if (C4134.m6657(str12)) {
                                        }
                                        InterfaceC3575 interfaceC3575Mo589122222222222222222222222222 = interfaceC35622.mo5891(c35994.f10749, i5);
                                        c35994.f10794 = interfaceC3575Mo589122222222222222222222222222;
                                        interfaceC3575Mo589122222222222222222222222222.mo5884(c3431M5588);
                                        c3596 = c35962;
                                        SparseArray<C3599> sparseArray22222222222222222222222222 = c3596.f10695;
                                        C3599 c3599522222222222222222222222222 = c3596.f10713;
                                        sparseArray22222222222222222222222222.put(c3599522222222222222222222222222.f10749, c3599522222222222222222222222222);
                                        break;
                                    case 26:
                                        str18 = "text/x-ssa";
                                        listSingletonList = null;
                                        str10 = str18;
                                        list3 = listSingletonList;
                                        iM6741 = -1;
                                        list2 = list3;
                                        i4 = iM6741;
                                        str12 = str10;
                                        i3 = -1;
                                        list4 = list2;
                                        int i22222222222222222222222222222 = (c35994.f10792 ? 1 : 0) | 0 | (c35994.f10791 ? 2 : 0);
                                        if (C4134.m6657(str12)) {
                                        }
                                        InterfaceC3575 interfaceC3575Mo5891222222222222222222222222222 = interfaceC35622.mo5891(c35994.f10749, i5);
                                        c35994.f10794 = interfaceC3575Mo5891222222222222222222222222222;
                                        interfaceC3575Mo5891222222222222222222222222222.mo5884(c3431M5588);
                                        c3596 = c35962;
                                        SparseArray<C3599> sparseArray222222222222222222222222222 = c3596.f10695;
                                        C3599 c35995222222222222222222222222222 = c3596.f10713;
                                        sparseArray222222222222222222222222222.put(c35995222222222222222222222222222.f10749, c35995222222222222222222222222222);
                                        break;
                                    case 27:
                                        listSingletonList = Collections.singletonList(c35994.f10756);
                                        str10 = "application/vobsub";
                                        list3 = listSingletonList;
                                        iM6741 = -1;
                                        list2 = list3;
                                        i4 = iM6741;
                                        str12 = str10;
                                        i3 = -1;
                                        list4 = list2;
                                        int i222222222222222222222222222222 = (c35994.f10792 ? 1 : 0) | 0 | (c35994.f10791 ? 2 : 0);
                                        if (C4134.m6657(str12)) {
                                        }
                                        InterfaceC3575 interfaceC3575Mo58912222222222222222222222222222 = interfaceC35622.mo5891(c35994.f10749, i5);
                                        c35994.f10794 = interfaceC3575Mo58912222222222222222222222222222;
                                        interfaceC3575Mo58912222222222222222222222222222.mo5884(c3431M5588);
                                        c3596 = c35962;
                                        SparseArray<C3599> sparseArray2222222222222222222222222222 = c3596.f10695;
                                        C3599 c359952222222222222222222222222222 = c3596.f10713;
                                        sparseArray2222222222222222222222222222.put(c359952222222222222222222222222222.f10749, c359952222222222222222222222222222);
                                        break;
                                    case 28:
                                        str9 = "application/pgs";
                                        list = null;
                                        list3 = list;
                                        str10 = str9;
                                        iM6741 = -1;
                                        list2 = list3;
                                        i4 = iM6741;
                                        str12 = str10;
                                        i3 = -1;
                                        list4 = list2;
                                        int i2222222222222222222222222222222 = (c35994.f10792 ? 1 : 0) | 0 | (c35994.f10791 ? 2 : 0);
                                        if (C4134.m6657(str12)) {
                                        }
                                        InterfaceC3575 interfaceC3575Mo589122222222222222222222222222222 = interfaceC35622.mo5891(c35994.f10749, i5);
                                        c35994.f10794 = interfaceC3575Mo589122222222222222222222222222222;
                                        interfaceC3575Mo589122222222222222222222222222222.mo5884(c3431M5588);
                                        c3596 = c35962;
                                        SparseArray<C3599> sparseArray22222222222222222222222222222 = c3596.f10695;
                                        C3599 c3599522222222222222222222222222222 = c3596.f10713;
                                        sparseArray22222222222222222222222222222.put(c3599522222222222222222222222222222.f10749, c3599522222222222222222222222222222);
                                        break;
                                    case 29:
                                        byte[] bArr7 = c35994.f10756;
                                        listSingletonList = Collections.singletonList(new byte[]{bArr7[0], bArr7[1], bArr7[2], bArr7[3]});
                                        str10 = "application/dvbsubs";
                                        list3 = listSingletonList;
                                        iM6741 = -1;
                                        list2 = list3;
                                        i4 = iM6741;
                                        str12 = str10;
                                        i3 = -1;
                                        list4 = list2;
                                        int i22222222222222222222222222222222 = (c35994.f10792 ? 1 : 0) | 0 | (c35994.f10791 ? 2 : 0);
                                        if (C4134.m6657(str12)) {
                                        }
                                        InterfaceC3575 interfaceC3575Mo5891222222222222222222222222222222 = interfaceC35622.mo5891(c35994.f10749, i5);
                                        c35994.f10794 = interfaceC3575Mo5891222222222222222222222222222222;
                                        interfaceC3575Mo5891222222222222222222222222222222.mo5884(c3431M5588);
                                        c3596 = c35962;
                                        SparseArray<C3599> sparseArray222222222222222222222222222222 = c3596.f10695;
                                        C3599 c35995222222222222222222222222222222 = c3596.f10713;
                                        sparseArray222222222222222222222222222222.put(c35995222222222222222222222222222222.f10749, c35995222222222222222222222222222222);
                                        break;
                                    default:
                                        throw new ParserException("Unrecognized codec identifier.");
                                }
                            } else {
                                c3596 = c35962;
                            }
                            c3596.f10713 = null;
                        }
                        str3 = "A_DTS";
                        obj4 = "A_MPEG/L2";
                        str = "A_DTS/EXPRESS";
                        obj = "A_MPEG/L3";
                    }
                    obj3 = "A_VORBIS";
                    str3 = "A_DTS";
                    obj4 = "A_MPEG/L2";
                    str = "A_DTS/EXPRESS";
                    obj = "A_MPEG/L3";
                }
                z = true;
                if (z) {
                }
                c3596.f10713 = null;
            }
            str = "A_DTS/EXPRESS";
            obj = "A_MPEG/L3";
            obj2 = "V_MPEG4/ISO/SP";
            str2 = "A_AC3";
            obj3 = "A_VORBIS";
            str3 = "A_DTS";
            obj4 = "A_MPEG/L2";
            obj5 = "V_MPEG4/ISO/AP";
            str4 = "S_DVBSUB";
            obj6 = "A_MS/ACM";
            str5 = "S_TEXT/UTF8";
            obj7 = "V_MPEG4/ISO/ASP";
            str6 = "S_TEXT/ASS";
            obj8 = "V_MPEG4/ISO/AVC";
            str7 = "S_HDMV/PGS";
            obj9 = "A_DTS/LOSSLESS";
            obj10 = "V_MS/VFW/FOURCC";
            str8 = "A_PCM/INT/LIT";
            z = true;
            if (z) {
            }
            c3596.f10713 = null;
        }
    }

    /* JADX INFO: renamed from: ދ.ހ.֏.ؠ.ೲ.ޘ.ށ$ހ, reason: contains not printable characters */
    public static final class C3599 {

        /* JADX INFO: renamed from: ֏, reason: contains not printable characters */
        public String f10747;

        /* JADX INFO: renamed from: ؠ, reason: contains not printable characters */
        public String f10748;

        /* JADX INFO: renamed from: ހ, reason: contains not printable characters */
        public int f10749;

        /* JADX INFO: renamed from: ށ, reason: contains not printable characters */
        public int f10750;

        /* JADX INFO: renamed from: ނ, reason: contains not printable characters */
        public int f10751;

        /* JADX INFO: renamed from: ރ, reason: contains not printable characters */
        public int f10752;

        /* JADX INFO: renamed from: ބ, reason: contains not printable characters */
        public boolean f10753;

        /* JADX INFO: renamed from: ޅ, reason: contains not printable characters */
        public byte[] f10754;

        /* JADX INFO: renamed from: ކ, reason: contains not printable characters */
        public InterfaceC3575.C3576 f10755;

        /* JADX INFO: renamed from: އ, reason: contains not printable characters */
        public byte[] f10756;

        /* JADX INFO: renamed from: ވ, reason: contains not printable characters */
        public C3526 f10757;

        /* JADX INFO: renamed from: ࢣ, reason: contains not printable characters */
        public C3600 f10790;

        /* JADX INFO: renamed from: ࢤ, reason: contains not printable characters */
        public boolean f10791;

        /* JADX INFO: renamed from: ࢧ, reason: contains not printable characters */
        public InterfaceC3575 f10794;

        /* JADX INFO: renamed from: ࢨ, reason: contains not printable characters */
        public int f10795;

        /* JADX INFO: renamed from: މ, reason: contains not printable characters */
        public int f10758 = -1;

        /* JADX INFO: renamed from: ފ, reason: contains not printable characters */
        public int f10759 = -1;

        /* JADX INFO: renamed from: ދ, reason: contains not printable characters */
        public int f10760 = -1;

        /* JADX INFO: renamed from: ތ, reason: contains not printable characters */
        public int f10761 = -1;

        /* JADX INFO: renamed from: ލ, reason: contains not printable characters */
        public int f10762 = 0;

        /* JADX INFO: renamed from: ގ, reason: contains not printable characters */
        public int f10763 = -1;

        /* JADX INFO: renamed from: ޏ, reason: contains not printable characters */
        public float f10764 = 0.0f;

        /* JADX INFO: renamed from: ސ, reason: contains not printable characters */
        public float f10765 = 0.0f;

        /* JADX INFO: renamed from: ޑ, reason: contains not printable characters */
        public float f10766 = 0.0f;

        /* JADX INFO: renamed from: ޒ, reason: contains not printable characters */
        public byte[] f10767 = null;

        /* JADX INFO: renamed from: ޓ, reason: contains not printable characters */
        public int f10768 = -1;

        /* JADX INFO: renamed from: ޔ, reason: contains not printable characters */
        public boolean f10769 = false;

        /* JADX INFO: renamed from: ޕ, reason: contains not printable characters */
        public int f10770 = -1;

        /* JADX INFO: renamed from: ޖ, reason: contains not printable characters */
        public int f10771 = -1;

        /* JADX INFO: renamed from: ޗ, reason: contains not printable characters */
        public int f10772 = -1;

        /* JADX INFO: renamed from: ޘ, reason: contains not printable characters */
        public int f10773 = 1000;

        /* JADX INFO: renamed from: ޙ, reason: contains not printable characters */
        public int f10774 = 200;

        /* JADX INFO: renamed from: ޚ, reason: contains not printable characters */
        public float f10775 = -1.0f;

        /* JADX INFO: renamed from: ޛ, reason: contains not printable characters */
        public float f10776 = -1.0f;

        /* JADX INFO: renamed from: ޜ, reason: contains not printable characters */
        public float f10777 = -1.0f;

        /* JADX INFO: renamed from: ޝ, reason: contains not printable characters */
        public float f10778 = -1.0f;

        /* JADX INFO: renamed from: ޞ, reason: contains not printable characters */
        public float f10779 = -1.0f;

        /* JADX INFO: renamed from: ޟ, reason: contains not printable characters */
        public float f10780 = -1.0f;

        /* JADX INFO: renamed from: ޠ, reason: contains not printable characters */
        public float f10781 = -1.0f;

        /* JADX INFO: renamed from: ޡ, reason: contains not printable characters */
        public float f10782 = -1.0f;

        /* JADX INFO: renamed from: ޢ, reason: contains not printable characters */
        public float f10783 = -1.0f;

        /* JADX INFO: renamed from: ޣ, reason: contains not printable characters */
        public float f10784 = -1.0f;

        /* JADX INFO: renamed from: ޤ, reason: contains not printable characters */
        public int f10785 = 1;

        /* JADX INFO: renamed from: ޥ, reason: contains not printable characters */
        public int f10786 = -1;

        /* JADX INFO: renamed from: ޱ, reason: contains not printable characters */
        public int f10787 = 8000;

        /* JADX INFO: renamed from: ࢠ, reason: contains not printable characters */
        public long f10788 = 0;

        /* JADX INFO: renamed from: ࢢ, reason: contains not printable characters */
        public long f10789 = 0;

        /* JADX INFO: renamed from: ࢥ, reason: contains not printable characters */
        public boolean f10792 = true;

        /* JADX INFO: renamed from: ࢦ, reason: contains not printable characters */
        public String f10793 = "eng";

        public C3599() {
        }

        public /* synthetic */ C3599(C3597 c3597) {
        }
    }

    /* JADX INFO: renamed from: ދ.ހ.֏.ؠ.ೲ.ޘ.ށ$ށ, reason: contains not printable characters */
    public static final class C3600 {

        /* JADX INFO: renamed from: ֏, reason: contains not printable characters */
        public final byte[] f10796 = new byte[10];

        /* JADX INFO: renamed from: ؠ, reason: contains not printable characters */
        public boolean f10797;

        /* JADX INFO: renamed from: ހ, reason: contains not printable characters */
        public int f10798;

        /* JADX INFO: renamed from: ށ, reason: contains not printable characters */
        public long f10799;

        /* JADX INFO: renamed from: ނ, reason: contains not printable characters */
        public int f10800;

        /* JADX INFO: renamed from: ރ, reason: contains not printable characters */
        public int f10801;

        /* JADX INFO: renamed from: ބ, reason: contains not printable characters */
        public int f10802;

        /* JADX INFO: renamed from: ֏, reason: contains not printable characters */
        public void m5928(C3599 c3599) {
            if (this.f10798 > 0) {
                c3599.f10794.mo5883(this.f10799, this.f10800, this.f10801, this.f10802, c3599.f10755);
                this.f10798 = 0;
            }
        }
    }

    public C3596(int i) {
        C3591 c3591 = new C3591();
        this.f10709 = -1L;
        this.f10710 = -9223372036854775807L;
        this.f10711 = -9223372036854775807L;
        this.f10712 = -9223372036854775807L;
        this.f10718 = -1L;
        this.f10719 = -1L;
        this.f10720 = -9223372036854775807L;
        this.f10693 = c3591;
        c3591.f10683 = new C3598(null);
        this.f10696 = (i & 1) == 0;
        this.f10694 = new C3602();
        this.f10695 = new SparseArray<>();
        this.f10699 = new C4140(4);
        this.f10700 = new C4140(ByteBuffer.allocate(4).putInt(-1).array());
        this.f10701 = new C4140(4);
        this.f10697 = new C4140(C4136.f13203);
        this.f10698 = new C4140(4);
        this.f10702 = new C4140();
        this.f10703 = new C4140();
        this.f10704 = new C4140(8);
        this.f10705 = new C4140();
        this.f10706 = new C4140();
    }

    /* JADX INFO: renamed from: ֏, reason: contains not printable characters */
    public static byte[] m5918(long j, String str, long j2) {
        C0567.m1896(j != -9223372036854775807L);
        int i = (int) (j / 3600000000L);
        long j3 = j - (((long) (i * 3600)) * 1000000);
        int i2 = (int) (j3 / 60000000);
        long j4 = j3 - (((long) (i2 * 60)) * 1000000);
        int i3 = (int) (j4 / 1000000);
        return C4150.m6799(String.format(Locale.US, str, Integer.valueOf(i), Integer.valueOf(i2), Integer.valueOf(i3), Integer.valueOf((int) ((j4 - (((long) i3) * 1000000)) / j2))));
    }

    /* JADX INFO: renamed from: ֏, reason: contains not printable characters */
    public static int[] m5919(int[] iArr, int i) {
        return iArr == null ? new int[i] : iArr.length >= i ? iArr : new int[Math.max(iArr.length * 2, i)];
    }

    /* JADX WARN: Code restructure failed: missing block: B:192:0x03c6, code lost:
    
        throw new com.google.android.exoplayer2.ParserException("EBML lacing sample size out of range.");
     */
    /* JADX WARN: Code restructure failed: missing block: B:339:0x062b, code lost:
    
        throw new com.google.android.exoplayer2.ParserException(p138.p139.p143.p144.C2803.m4875("DocTypeReadVersion ", r2, " not supported"));
     */
    /* JADX WARN: Code restructure failed: missing block: B:461:0x0810, code lost:
    
        r5 = true;
        r3 = r3;
     */
    /* JADX WARN: Code restructure failed: missing block: B:462:0x0812, code lost:
    
        if (r5 == false) goto L476;
     */
    /* JADX WARN: Code restructure failed: missing block: B:463:0x0814, code lost:
    
        r6 = r29.f10563;
     */
    /* JADX WARN: Code restructure failed: missing block: B:464:0x0818, code lost:
    
        if (r28.f10717 == false) goto L466;
     */
    /* JADX WARN: Code restructure failed: missing block: B:465:0x081a, code lost:
    
        r28.f10719 = r6;
        r30.f10591 = r28.f10718;
        r28.f10717 = r3;
     */
    /* JADX WARN: Code restructure failed: missing block: B:467:0x0829, code lost:
    
        if (r28.f10714 == false) goto L472;
     */
    /* JADX WARN: Code restructure failed: missing block: B:468:0x082b, code lost:
    
        r3 = r28.f10719;
     */
    /* JADX WARN: Code restructure failed: missing block: B:469:0x0831, code lost:
    
        if (r3 == (-1)) goto L472;
     */
    /* JADX WARN: Code restructure failed: missing block: B:470:0x0833, code lost:
    
        r30.f10591 = r3;
        r28.f10719 = -1;
     */
    /* JADX WARN: Code restructure failed: missing block: B:471:0x0837, code lost:
    
        r3 = true;
     */
    /* JADX WARN: Code restructure failed: missing block: B:472:0x0839, code lost:
    
        r3 = false;
     */
    /* JADX WARN: Code restructure failed: missing block: B:473:0x083a, code lost:
    
        if (r3 == false) goto L524;
     */
    /* JADX WARN: Code restructure failed: missing block: B:474:0x083c, code lost:
    
        return 1;
     */
    /* JADX WARN: Code restructure failed: missing block: B:482:0x0855, code lost:
    
        if (r5 != false) goto L492;
     */
    /* JADX WARN: Code restructure failed: missing block: B:483:0x0857, code lost:
    
        r1 = 0;
     */
    /* JADX WARN: Code restructure failed: missing block: B:485:0x085e, code lost:
    
        if (r1 >= r28.f10695.size()) goto L544;
     */
    /* JADX WARN: Code restructure failed: missing block: B:486:0x0860, code lost:
    
        r2 = r28.f10695.valueAt(r1);
        r3 = r2.f10790;
     */
    /* JADX WARN: Code restructure failed: missing block: B:487:0x086a, code lost:
    
        if (r3 == null) goto L546;
     */
    /* JADX WARN: Code restructure failed: missing block: B:488:0x086c, code lost:
    
        r3.m5928(r2);
     */
    /* JADX WARN: Code restructure failed: missing block: B:489:0x086f, code lost:
    
        r1 = r1 + 1;
     */
    /* JADX WARN: Code restructure failed: missing block: B:490:0x0872, code lost:
    
        return -1;
     */
    /* JADX WARN: Code restructure failed: missing block: B:492:0x0874, code lost:
    
        return 0;
     */
    /* JADX WARN: Multi-variable type inference failed */
    /* JADX WARN: Removed duplicated region for block: B:392:0x06f6  */
    /* JADX WARN: Type inference failed for: r3v100 */
    /* JADX WARN: Type inference failed for: r3v121 */
    /* JADX WARN: Type inference failed for: r3v122 */
    /* JADX WARN: Type inference failed for: r3v123 */
    /* JADX WARN: Type inference failed for: r3v124 */
    /* JADX WARN: Type inference failed for: r3v125 */
    /* JADX WARN: Type inference failed for: r3v127 */
    /* JADX WARN: Type inference failed for: r3v4 */
    /* JADX WARN: Type inference failed for: r3v42 */
    /* JADX WARN: Type inference failed for: r3v62 */
    /* JADX WARN: Type inference failed for: r3v71 */
    /* JADX WARN: Type inference failed for: r3v93, types: [boolean] */
    /* JADX WARN: Type inference failed for: r4v139 */
    /* JADX WARN: Type inference failed for: r4v63, types: [int] */
    /* JADX WARN: Type inference failed for: r4v70 */
    /* JADX WARN: Type inference failed for: r6v21, types: [int[]] */
    /* JADX WARN: Type inference fix 'apply assigned field type' failed
    java.lang.UnsupportedOperationException: ArgType.getObject(), call class: class jadx.core.dex.instructions.args.ArgType$UnknownArg
    	at jadx.core.dex.instructions.args.ArgType.getObject(ArgType.java:593)
    	at jadx.core.dex.attributes.nodes.ClassTypeVarsAttr.getTypeVarsMapFor(ClassTypeVarsAttr.java:35)
    	at jadx.core.dex.nodes.utils.TypeUtils.replaceClassGenerics(TypeUtils.java:177)
    	at jadx.core.dex.visitors.typeinference.FixTypesVisitor.insertExplicitUseCast(FixTypesVisitor.java:397)
    	at jadx.core.dex.visitors.typeinference.FixTypesVisitor.tryFieldTypeWithNewCasts(FixTypesVisitor.java:359)
    	at jadx.core.dex.visitors.typeinference.FixTypesVisitor.applyFieldType(FixTypesVisitor.java:309)
    	at jadx.core.dex.visitors.typeinference.FixTypesVisitor.visit(FixTypesVisitor.java:94)
     */
    @Override // p138.p176.p177.p190.p198.InterfaceC3561
    /* JADX INFO: renamed from: ֏ */
    /*
        Code decompiled incorrectly, please refer to instructions dump.
    */
    public final int mo5886(C3558 c3558, C3570 c3570) throws ParserException, InterruptedException, EOFException {
        int i;
        int i2;
        ?? r3;
        String str;
        C3591 c3591;
        boolean z;
        C3591 c35912;
        long j;
        int[] iArr;
        boolean z2 = false;
        this.f10724 = false;
        boolean z3 = true;
        boolean z4 = true;
        while (true) {
            int i3 = -1;
            if (z4 && !this.f10724) {
                C3591 c35913 = (C3591) this.f10693;
                C0567.m1856(c35913.f10683);
                boolean z5 = z2;
                boolean z6 = z3;
                while (true) {
                    if (c35913.f10681.isEmpty() || c3558.f10563 < c35913.f10681.peek().f10688) {
                        if (c35913.f10684 == 0) {
                            long jM5932 = c35913.f10682.m5932(c3558, z6, z5, 4);
                            if (jM5932 == -2) {
                                c3558.f10565 = z5 ? 1 : 0;
                                while (true) {
                                    c3558.m5875(c35913.f10680, z5 ? 1 : 0, 4, z5);
                                    int iM5930 = C3602.m5930(c35913.f10680[z5 ? 1 : 0]);
                                    if (iM5930 != i3 && iM5930 <= 4) {
                                        int iM5931 = (int) C3602.m5931(c35913.f10680, iM5930, z5);
                                        if (C3596.this == null) {
                                            throw null;
                                        }
                                        if (iM5931 == 357149030 || iM5931 == 524531317 || iM5931 == 475249515 || iM5931 == 374648427) {
                                            c3558.m5878(iM5930);
                                            jM5932 = iM5931;
                                        }
                                    }
                                    c3558.m5878(z6 ? 1 : 0);
                                }
                            }
                            if (jM5932 == -1) {
                                z4 = false;
                                ?? r32 = z5;
                            } else {
                                c35913.f10685 = (int) jM5932;
                                c35913.f10684 = z6 ? 1 : 0;
                            }
                        }
                        if (c35913.f10684 == z6) {
                            c35913.f10686 = c35913.f10682.m5932(c3558, z5, z6, 8);
                            c35913.f10684 = 2;
                        }
                        InterfaceC3594 interfaceC3594 = c35913.f10683;
                        int i4 = c35913.f10685;
                        if (C3596.this == null) {
                            throw null;
                        }
                        switch (i4) {
                            case 131:
                            case 136:
                            case 155:
                            case 159:
                            case 176:
                            case 179:
                            case 186:
                            case 215:
                            case 231:
                            case 238:
                            case 241:
                            case 251:
                            case 16980:
                            case 17029:
                            case 17143:
                            case 18401:
                            case 18408:
                            case 20529:
                            case 20530:
                            case 21420:
                            case 21432:
                            case 21680:
                            case 21682:
                            case 21690:
                            case 21930:
                            case 21945:
                            case 21946:
                            case 21947:
                            case 21948:
                            case 21949:
                            case 21998:
                            case 22186:
                            case 22203:
                            case 25188:
                            case 30321:
                            case 2352003:
                            case 2807729:
                                i = 2;
                                break;
                            case 134:
                            case 17026:
                            case 21358:
                            case 2274716:
                                i = 3;
                                break;
                            case 160:
                            case 166:
                            case 174:
                            case 183:
                            case 187:
                            case 224:
                            case 225:
                            case 18407:
                            case 19899:
                            case 20532:
                            case 20533:
                            case 21936:
                            case 21968:
                            case 25152:
                            case 28032:
                            case 30113:
                            case 30320:
                            case 290298740:
                            case 357149030:
                            case 374648427:
                            case 408125543:
                            case 440786851:
                            case 475249515:
                            case 524531317:
                                i = 1;
                                break;
                            case 161:
                            case 163:
                            case 165:
                            case 16981:
                            case 18402:
                            case 21419:
                            case 25506:
                            case 30322:
                                i = 4;
                                break;
                            case 181:
                            case 17545:
                            case 21969:
                            case 21970:
                            case 21971:
                            case 21972:
                            case 21973:
                            case 21974:
                            case 21975:
                            case 21976:
                            case 21977:
                            case 21978:
                            case 30323:
                            case 30324:
                            case 30325:
                                i = 5;
                                break;
                            default:
                                i = 0;
                                break;
                        }
                        if (i == 0) {
                            c3558.m5878((int) c35913.f10686);
                            z5 = false;
                            c35913.f10684 = 0;
                            z6 = true;
                            i3 = -1;
                        } else if (i != z6) {
                            if (i == 2) {
                                long j2 = c35913.f10686;
                                if (j2 > 8) {
                                    StringBuilder sbM4889 = C2803.m4889("Invalid integer size: ");
                                    sbM4889.append(c35913.f10686);
                                    throw new ParserException(sbM4889.toString());
                                }
                                InterfaceC3594 interfaceC35942 = c35913.f10683;
                                int i5 = c35913.f10685;
                                long jM5917 = c35913.m5917(c3558, (int) j2);
                                C3596 c3596 = C3596.this;
                                if (c3596 == null) {
                                    throw null;
                                }
                                if (i5 != 20529) {
                                    if (i5 != 20530) {
                                        switch (i5) {
                                            case 131:
                                                c3596.f10713.f10750 = (int) jM5917;
                                                break;
                                            case 136:
                                                c3596.f10713.f10792 = jM5917 == 1;
                                                break;
                                            case 155:
                                                c3596.f10727 = c3596.m5922(jM5917);
                                                break;
                                            case 159:
                                                c3596.f10713.f10785 = (int) jM5917;
                                                break;
                                            case 176:
                                                c3596.f10713.f10758 = (int) jM5917;
                                                break;
                                            case 179:
                                                c3596.f10721.m6648(c3596.m5922(jM5917));
                                                break;
                                            case 186:
                                                c3596.f10713.f10759 = (int) jM5917;
                                                break;
                                            case 215:
                                                c3596.f10713.f10749 = (int) jM5917;
                                                break;
                                            case 231:
                                                c3596.f10720 = c3596.m5922(jM5917);
                                                break;
                                            case 238:
                                                c3596.f10734 = (int) jM5917;
                                                break;
                                            case 241:
                                                if (!c3596.f10723) {
                                                    c3596.f10722.m6648(jM5917);
                                                    c3596.f10723 = true;
                                                }
                                                break;
                                            case 251:
                                                c3596.f10735 = true;
                                                break;
                                            case 16980:
                                                if (jM5917 != 3) {
                                                    throw new ParserException(C2803.m4875("ContentCompAlgo ", jM5917, " not supported"));
                                                }
                                                break;
                                            case 17029:
                                                if (jM5917 < 1 || jM5917 > 2) {
                                                }
                                                break;
                                            case 17143:
                                                if (jM5917 != 1) {
                                                    throw new ParserException(C2803.m4875("EBMLReadVersion ", jM5917, " not supported"));
                                                }
                                                break;
                                            case 18401:
                                                if (jM5917 != 5) {
                                                    throw new ParserException(C2803.m4875("ContentEncAlgo ", jM5917, " not supported"));
                                                }
                                                break;
                                            case 18408:
                                                if (jM5917 != 1) {
                                                    throw new ParserException(C2803.m4875("AESSettingsCipherMode ", jM5917, " not supported"));
                                                }
                                                break;
                                            case 21420:
                                                c3596.f10716 = jM5917 + c3596.f10709;
                                                break;
                                            case 21432:
                                                int i6 = (int) jM5917;
                                                if (i6 == 0) {
                                                    c3596.f10713.f10768 = 0;
                                                } else if (i6 == 1) {
                                                    c3596.f10713.f10768 = 2;
                                                } else if (i6 == 3) {
                                                    c3596.f10713.f10768 = 1;
                                                } else if (i6 == 15) {
                                                    c3596.f10713.f10768 = 3;
                                                }
                                                break;
                                            case 21680:
                                                c3596.f10713.f10760 = (int) jM5917;
                                                break;
                                            case 21682:
                                                c3596.f10713.f10762 = (int) jM5917;
                                                break;
                                            case 21690:
                                                c3596.f10713.f10761 = (int) jM5917;
                                                break;
                                            case 21930:
                                                c3596.f10713.f10791 = jM5917 == 1;
                                                break;
                                            case 21998:
                                                c3596.f10713.f10752 = (int) jM5917;
                                                break;
                                            case 22186:
                                                c3596.f10713.f10788 = jM5917;
                                                break;
                                            case 22203:
                                                c3596.f10713.f10789 = jM5917;
                                                break;
                                            case 25188:
                                                c3596.f10713.f10786 = (int) jM5917;
                                                break;
                                            case 30321:
                                                int i7 = (int) jM5917;
                                                if (i7 == 0) {
                                                    c3596.f10713.f10763 = 0;
                                                } else if (i7 == 1) {
                                                    c3596.f10713.f10763 = 1;
                                                } else if (i7 == 2) {
                                                    c3596.f10713.f10763 = 2;
                                                } else if (i7 == 3) {
                                                    c3596.f10713.f10763 = 3;
                                                }
                                                break;
                                            case 2352003:
                                                c3596.f10713.f10751 = (int) jM5917;
                                                break;
                                            case 2807729:
                                                c3596.f10710 = jM5917;
                                                break;
                                            default:
                                                switch (i5) {
                                                    case 21945:
                                                        int i8 = (int) jM5917;
                                                        if (i8 == 1) {
                                                            c3596.f10713.f10772 = 2;
                                                        } else if (i8 == 2) {
                                                            c3596.f10713.f10772 = 1;
                                                        }
                                                        break;
                                                    case 21946:
                                                        int i9 = (int) jM5917;
                                                        if (i9 == 1) {
                                                            c3596.f10713.f10771 = 3;
                                                            break;
                                                        } else if (i9 == 16) {
                                                            c3596.f10713.f10771 = 6;
                                                            break;
                                                        } else if (i9 == 18) {
                                                            c3596.f10713.f10771 = 7;
                                                            break;
                                                        } else if (i9 == 6 || i9 == 7) {
                                                        }
                                                        break;
                                                    case 21947:
                                                        C3599 c3599 = c3596.f10713;
                                                        c3599.f10769 = true;
                                                        int i10 = (int) jM5917;
                                                        if (i10 == 1) {
                                                            c3599.f10770 = 1;
                                                        } else if (i10 == 9) {
                                                            c3599.f10770 = 6;
                                                        } else if (i10 == 4 || i10 == 5 || i10 == 6 || i10 == 7) {
                                                            c3596.f10713.f10770 = 2;
                                                        }
                                                        break;
                                                    case 21948:
                                                        c3596.f10713.f10773 = (int) jM5917;
                                                        break;
                                                    case 21949:
                                                        c3596.f10713.f10774 = (int) jM5917;
                                                        break;
                                                }
                                                break;
                                        }
                                    } else if (jM5917 != 1) {
                                        throw new ParserException(C2803.m4875("ContentEncodingScope ", jM5917, " not supported"));
                                    }
                                } else if (jM5917 != 0) {
                                    throw new ParserException(C2803.m4875("ContentEncodingOrder ", jM5917, " not supported"));
                                }
                                c35913.f10684 = 0;
                            } else if (i == 3) {
                                long j3 = c35913.f10686;
                                if (j3 > 2147483647L) {
                                    StringBuilder sbM48892 = C2803.m4889("String element size: ");
                                    sbM48892.append(c35913.f10686);
                                    throw new ParserException(sbM48892.toString());
                                }
                                InterfaceC3594 interfaceC35943 = c35913.f10683;
                                int i11 = c35913.f10685;
                                int i12 = (int) j3;
                                if (i12 == 0) {
                                    str = "";
                                } else {
                                    byte[] bArr = new byte[i12];
                                    c3558.m5877(bArr, 0, i12, false);
                                    while (i12 > 0) {
                                        int i13 = i12 - 1;
                                        if (bArr[i13] == 0) {
                                            i12 = i13;
                                        } else {
                                            str = new String(bArr, 0, i12);
                                        }
                                    }
                                    str = new String(bArr, 0, i12);
                                }
                                C3596 c35962 = C3596.this;
                                if (c35962 == null) {
                                    throw null;
                                }
                                if (i11 == 134) {
                                    c35962.f10713.f10748 = str;
                                } else if (i11 != 17026) {
                                    if (i11 == 21358) {
                                        c35962.f10713.f10747 = str;
                                    } else if (i11 == 2274716) {
                                        c35962.f10713.f10793 = str;
                                    }
                                } else if (!"webm".equals(str) && !"matroska".equals(str)) {
                                    throw new ParserException(C2803.m4880("DocType ", str, " not supported"));
                                }
                                c35913.f10684 = 0;
                            } else if (i == 4) {
                                InterfaceC3594 interfaceC35944 = c35913.f10683;
                                int i14 = c35913.f10685;
                                int i15 = (int) c35913.f10686;
                                C3596 c35963 = C3596.this;
                                if (c35963 == null) {
                                    throw null;
                                }
                                if (i14 == 161 || i14 == 163) {
                                    if (c35963.f10725 == 0) {
                                        c35963.f10731 = (int) c35963.f10694.m5932(c3558, z5, z6, 8);
                                        c35963.f10732 = c35963.f10694.f10808;
                                        c35963.f10727 = -9223372036854775807L;
                                        c35963.f10725 = z6 ? 1 : 0;
                                        c35963.f10699.m6709();
                                    }
                                    C3599 c35992 = c35963.f10695.get(c35963.f10731);
                                    if (c35992 == null) {
                                        c3558.m5878(i15 - c35963.f10732);
                                        c35963.f10725 = z5 ? 1 : 0;
                                    } else {
                                        if (c35963.f10725 == z6) {
                                            c35963.m5923(c3558, 3);
                                            int i16 = (c35963.f10699.f13227[2] & 6) >> (z6 ? 1 : 0);
                                            byte b = 255;
                                            if (i16 == 0) {
                                                c35963.f10729 = z6 ? 1 : 0;
                                                int[] iArrM5919 = m5919(c35963.f10730, z6 ? 1 : 0);
                                                c35963.f10730 = iArrM5919;
                                                iArrM5919[z5 ? 1 : 0] = (i15 - c35963.f10732) - 3;
                                            } else {
                                                c35963.m5923(c3558, 4);
                                                int i17 = (c35963.f10699.f13227[3] & 255) + (z6 ? 1 : 0);
                                                c35963.f10729 = i17;
                                                int[] iArrM59192 = m5919(c35963.f10730, i17);
                                                c35963.f10730 = iArrM59192;
                                                if (i16 == 2) {
                                                    int i18 = (i15 - c35963.f10732) - 4;
                                                    int i19 = c35963.f10729;
                                                    Arrays.fill(iArrM59192, z5 ? 1 : 0, i19, i18 / i19);
                                                } else if (i16 == z6) {
                                                    int i20 = 4;
                                                    int i21 = 0;
                                                    int i22 = 0;
                                                    boolean z7 = z6;
                                                    while (true) {
                                                        int i23 = c35963.f10729 + i3;
                                                        if (i21 < i23) {
                                                            c35963.f10730[i21] = z5 ? 1 : 0;
                                                            ?? r4 = z7;
                                                            while (true) {
                                                                i20 += r4;
                                                                c35963.m5923(c3558, i20);
                                                                int i24 = c35963.f10699.f13227[i20 - 1] & 255;
                                                                iArr = c35963.f10730;
                                                                iArr[i21] = iArr[i21] + i24;
                                                                if (i24 != 255) {
                                                                    break;
                                                                }
                                                                r4 = 1;
                                                            }
                                                            i22 += iArr[i21];
                                                            i21++;
                                                            z7 = true;
                                                        } else {
                                                            c35963.f10730[i23] = ((i15 - c35963.f10732) - i20) - i22;
                                                        }
                                                    }
                                                } else {
                                                    if (i16 != 3) {
                                                        throw new ParserException(C2803.m4871("Unexpected lacing value: ", i16));
                                                    }
                                                    int i25 = 0;
                                                    int i26 = 4;
                                                    int i27 = 0;
                                                    ?? r33 = z5;
                                                    while (true) {
                                                        int i28 = c35963.f10729 + i3;
                                                        if (i25 < i28) {
                                                            c35963.f10730[i25] = r33;
                                                            i26++;
                                                            c35963.m5923(c3558, i26);
                                                            int i29 = i26 - 1;
                                                            if (c35963.f10699.f13227[i29] == 0) {
                                                                throw new ParserException("No valid varint length mask found");
                                                            }
                                                            int i30 = 8;
                                                            int i31 = 0;
                                                            while (true) {
                                                                if (i31 < i30) {
                                                                    int i32 = 1 << (7 - i31);
                                                                    if ((c35963.f10699.f13227[i29] & i32) != 0) {
                                                                        i26 += i31;
                                                                        c35963.m5923(c3558, i26);
                                                                        int i33 = i29 + 1;
                                                                        j = (~i32) & c35963.f10699.f13227[i29] & b;
                                                                        while (true) {
                                                                            int i34 = i33;
                                                                            if (i34 < i26) {
                                                                                i33 = i34 + 1;
                                                                                j = (j << 8) | ((long) (c35963.f10699.f13227[i34] & 255));
                                                                                c35913 = c35913;
                                                                            } else {
                                                                                c35912 = c35913;
                                                                                if (i25 > 0) {
                                                                                    j -= (1 << ((i31 * 7) + 6)) - 1;
                                                                                }
                                                                            }
                                                                        }
                                                                    } else {
                                                                        i31++;
                                                                        i30 = 8;
                                                                        b = 255;
                                                                    }
                                                                } else {
                                                                    c35912 = c35913;
                                                                    j = 0;
                                                                }
                                                            }
                                                            if (j >= -2147483648L && j <= 2147483647L) {
                                                                int i35 = (int) j;
                                                                int[] iArr2 = c35963.f10730;
                                                                if (i25 != 0) {
                                                                    i35 += iArr2[i25 - 1];
                                                                }
                                                                iArr2[i25] = i35;
                                                                i27 += c35963.f10730[i25];
                                                                i25++;
                                                                r33 = 0;
                                                                i3 = -1;
                                                                c35913 = c35912;
                                                                b = 255;
                                                            }
                                                        } else {
                                                            c3591 = c35913;
                                                            c35963.f10730[i28] = ((i15 - c35963.f10732) - i26) - i27;
                                                        }
                                                    }
                                                }
                                            }
                                            c3591 = c35913;
                                            byte[] bArr2 = c35963.f10699.f13227;
                                            c35963.f10726 = c35963.m5922((bArr2[1] & 255) | (bArr2[0] << 8)) + c35963.f10720;
                                            c35963.f10733 = ((c35963.f10699.f13227[2] & 8) == 8 ? Integer.MIN_VALUE : 0) | ((c35992.f10750 == 2 || (i14 == 163 && (c35963.f10699.f13227[2] & 128) == 128)) ? 1 : 0);
                                            c35963.f10725 = 2;
                                            c35963.f10728 = 0;
                                        } else {
                                            c3591 = c35913;
                                        }
                                        if (i14 == 163) {
                                            while (true) {
                                                int i36 = c35963.f10728;
                                                if (i36 < c35963.f10729) {
                                                    c35963.m5925(c35992, ((long) ((c35963.f10728 * c35992.f10751) / 1000)) + c35963.f10726, c35963.f10733, c35963.m5921(c3558, c35992, c35963.f10730[i36]), 0);
                                                    c35963.f10728++;
                                                } else {
                                                    z = false;
                                                    c35963.f10725 = 0;
                                                }
                                            }
                                        } else {
                                            while (true) {
                                                int i37 = c35963.f10728;
                                                if (i37 < c35963.f10729) {
                                                    int[] iArr3 = c35963.f10730;
                                                    iArr3[i37] = c35963.m5921(c3558, c35992, iArr3[i37]);
                                                    c35963.f10728++;
                                                } else {
                                                    z = false;
                                                }
                                            }
                                        }
                                        c3591.f10684 = z ? 1 : 0;
                                        r3 = z;
                                    }
                                } else if (i14 != 165) {
                                    if (i14 == 16981) {
                                        byte[] bArr3 = new byte[i15];
                                        c35963.f10713.f10754 = bArr3;
                                        c3558.m5877(bArr3, z5 ? 1 : 0, i15, z5);
                                    } else if (i14 == 18402) {
                                        byte[] bArr4 = new byte[i15];
                                        c3558.m5877(bArr4, z5 ? 1 : 0, i15, z5);
                                        c35963.f10713.f10755 = new InterfaceC3575.C3576(z6 ? 1 : 0, bArr4, z5 ? 1 : 0, z5 ? 1 : 0);
                                    } else if (i14 == 21419) {
                                        Arrays.fill(c35963.f10701.f13227, z5 ? (byte) 1 : (byte) 0);
                                        c3558.m5877(c35963.f10701.f13227, 4 - i15, i15, z5);
                                        c35963.f10701.m6693(z5 ? 1 : 0);
                                        c35963.f10715 = (int) c35963.f10701.m6703();
                                    } else if (i14 == 25506) {
                                        byte[] bArr5 = new byte[i15];
                                        c35963.f10713.f10756 = bArr5;
                                        c3558.m5877(bArr5, z5 ? 1 : 0, i15, z5);
                                    } else {
                                        if (i14 != 30322) {
                                            throw new ParserException(C2803.m4871("Unexpected id: ", i14));
                                        }
                                        byte[] bArr6 = new byte[i15];
                                        c35963.f10713.f10767 = bArr6;
                                        c3558.m5877(bArr6, z5 ? 1 : 0, i15, z5);
                                    }
                                } else if (c35963.f10725 == 2) {
                                    C3599 c35993 = c35963.f10695.get(c35963.f10731);
                                    if (c35963.f10734 == 4 && "V_VP9".equals(c35993.f10748)) {
                                        C4140 c4140 = c35963.f10706;
                                        byte[] bArr7 = c4140.f13227;
                                        if (bArr7.length < i15) {
                                            bArr7 = new byte[i15];
                                        }
                                        c4140.f13227 = bArr7;
                                        c4140.f13229 = i15;
                                        c4140.f13228 = z5 ? 1 : 0;
                                        c3558.m5877(c35963.f10706.f13227, z5 ? 1 : 0, i15, z5);
                                    } else {
                                        c3558.m5878(i15);
                                    }
                                }
                                c3591 = c35913;
                                z = z5;
                                c3591.f10684 = z ? 1 : 0;
                                r3 = z;
                            } else {
                                if (i != 5) {
                                    throw new ParserException(C2803.m4871("Invalid element type ", i));
                                }
                                long j4 = c35913.f10686;
                                if (j4 != 4 && j4 != 8) {
                                    StringBuilder sbM48893 = C2803.m4889("Invalid float size: ");
                                    sbM48893.append(c35913.f10686);
                                    throw new ParserException(sbM48893.toString());
                                }
                                InterfaceC3594 interfaceC35945 = c35913.f10683;
                                int i38 = c35913.f10685;
                                int i39 = (int) c35913.f10686;
                                double dIntBitsToFloat = i39 == 4 ? Float.intBitsToFloat((int) r12) : Double.longBitsToDouble(c35913.m5917(c3558, i39));
                                C3596 c35964 = C3596.this;
                                if (c35964 == null) {
                                    throw null;
                                }
                                if (i38 == 181) {
                                    c35964.f10713.f10787 = (int) dIntBitsToFloat;
                                } else if (i38 != 17545) {
                                    switch (i38) {
                                        case 21969:
                                            c35964.f10713.f10775 = (float) dIntBitsToFloat;
                                            break;
                                        case 21970:
                                            c35964.f10713.f10776 = (float) dIntBitsToFloat;
                                            break;
                                        case 21971:
                                            c35964.f10713.f10777 = (float) dIntBitsToFloat;
                                            break;
                                        case 21972:
                                            c35964.f10713.f10778 = (float) dIntBitsToFloat;
                                            break;
                                        case 21973:
                                            c35964.f10713.f10779 = (float) dIntBitsToFloat;
                                            break;
                                        case 21974:
                                            c35964.f10713.f10780 = (float) dIntBitsToFloat;
                                            break;
                                        case 21975:
                                            c35964.f10713.f10781 = (float) dIntBitsToFloat;
                                            break;
                                        case 21976:
                                            c35964.f10713.f10782 = (float) dIntBitsToFloat;
                                            break;
                                        case 21977:
                                            c35964.f10713.f10783 = (float) dIntBitsToFloat;
                                            break;
                                        case 21978:
                                            c35964.f10713.f10784 = (float) dIntBitsToFloat;
                                            break;
                                        default:
                                            switch (i38) {
                                                case 30323:
                                                    c35964.f10713.f10764 = (float) dIntBitsToFloat;
                                                    break;
                                                case 30324:
                                                    c35964.f10713.f10765 = (float) dIntBitsToFloat;
                                                    break;
                                                case 30325:
                                                    c35964.f10713.f10766 = (float) dIntBitsToFloat;
                                                    break;
                                            }
                                            break;
                                    }
                                } else {
                                    c35964.f10711 = (long) dIntBitsToFloat;
                                }
                                c35913.f10684 = z5 ? 1 : 0;
                                r3 = z5;
                            }
                            r3 = 0;
                        } else {
                            long j5 = c3558.f10563;
                            c35913.f10681.push(new C3591.C3593(c35913.f10685, c35913.f10686 + j5, null));
                            InterfaceC3594 interfaceC35946 = c35913.f10683;
                            int i40 = c35913.f10685;
                            long j6 = c35913.f10686;
                            C3596 c35965 = C3596.this;
                            if (c35965 == null) {
                                throw null;
                            }
                            if (i40 == 160) {
                                i2 = 0;
                                c35965.f10735 = false;
                            } else if (i40 == 174) {
                                i2 = 0;
                                c35965.f10713 = new C3599(null);
                            } else if (i40 != 187) {
                                if (i40 == 19899) {
                                    c35965.f10715 = -1;
                                    c35965.f10716 = -1L;
                                } else if (i40 == 20533) {
                                    c35965.f10713.f10753 = true;
                                } else if (i40 == 21968) {
                                    c35965.f10713.f10769 = true;
                                } else if (i40 == 408125543) {
                                    long j7 = c35965.f10709;
                                    if (j7 != -1 && j7 != j5) {
                                        throw new ParserException("Multiple Segment elements not supported");
                                    }
                                    c35965.f10709 = j5;
                                    c35965.f10708 = j6;
                                } else if (i40 == 475249515) {
                                    c35965.f10721 = new C4132();
                                    c35965.f10722 = new C4132();
                                } else if (i40 == 524531317 && !c35965.f10714) {
                                    if (!c35965.f10696 || c35965.f10718 == -1) {
                                        c35965.f10745.mo5893(new InterfaceC3571.C3573(c35965.f10712, 0L));
                                        c35965.f10714 = true;
                                    } else {
                                        c35965.f10717 = true;
                                    }
                                }
                                i2 = 0;
                            } else {
                                i2 = 0;
                                c35965.f10723 = false;
                            }
                            c35913.f10684 = i2;
                            r3 = i2;
                        }
                    } else {
                        ((C3598) c35913.f10683).m5927(c35913.f10681.pop().f10687);
                        r3 = z5;
                    }
                }
            }
            z2 = false;
            z3 = true;
        }
    }

    /* JADX INFO: renamed from: ֏, reason: contains not printable characters */
    public final int m5920(C3558 c3558, InterfaceC3575 interfaceC3575, int i) {
        int iM6679 = this.f10702.m6679();
        if (iM6679 <= 0) {
            return interfaceC3575.mo5882(c3558, i, false);
        }
        int iMin = Math.min(i, iM6679);
        interfaceC3575.mo5885(this.f10702, iMin);
        return iMin;
    }

    /* JADX INFO: renamed from: ֏, reason: contains not printable characters */
    public final int m5921(C3558 c3558, C3599 c3599, int i) throws InterruptedException, ParserException, EOFException {
        int i2;
        int i3;
        if ("S_TEXT/UTF8".equals(c3599.f10748)) {
            m5924(c3558, f10689, i);
            int i4 = this.f10737;
            m5926();
            return i4;
        }
        if ("S_TEXT/ASS".equals(c3599.f10748)) {
            m5924(c3558, f10691, i);
            int i5 = this.f10737;
            m5926();
            return i5;
        }
        InterfaceC3575 interfaceC3575 = c3599.f10794;
        if (!this.f10739) {
            if (c3599.f10753) {
                this.f10733 &= -1073741825;
                if (!this.f10740) {
                    c3558.m5877(this.f10699.f13227, 0, 1, false);
                    this.f10736++;
                    byte[] bArr = this.f10699.f13227;
                    if ((bArr[0] & 128) == 128) {
                        throw new ParserException("Extension bit is set in signal byte");
                    }
                    this.f10743 = bArr[0];
                    this.f10740 = true;
                }
                if ((this.f10743 & 1) == 1) {
                    boolean z = (this.f10743 & 2) == 2;
                    this.f10733 |= 1073741824;
                    if (!this.f10744) {
                        c3558.m5877(this.f10704.f13227, 0, 8, false);
                        this.f10736 += 8;
                        this.f10744 = true;
                        this.f10699.f13227[0] = (byte) ((z ? 128 : 0) | 8);
                        this.f10699.m6693(0);
                        interfaceC3575.mo5885(this.f10699, 1);
                        this.f10737++;
                        this.f10704.m6693(0);
                        interfaceC3575.mo5885(this.f10704, 8);
                        this.f10737 += 8;
                    }
                    if (z) {
                        if (!this.f10741) {
                            c3558.m5877(this.f10699.f13227, 0, 1, false);
                            this.f10736++;
                            this.f10699.m6693(0);
                            this.f10742 = this.f10699.m6702();
                            this.f10741 = true;
                        }
                        int i6 = this.f10742 * 4;
                        this.f10699.m6689(i6);
                        c3558.m5877(this.f10699.f13227, 0, i6, false);
                        this.f10736 += i6;
                        short s = (short) ((this.f10742 / 2) + 1);
                        int i7 = (s * 6) + 2;
                        ByteBuffer byteBuffer = this.f10707;
                        if (byteBuffer == null || byteBuffer.capacity() < i7) {
                            this.f10707 = ByteBuffer.allocate(i7);
                        }
                        this.f10707.position(0);
                        this.f10707.putShort(s);
                        int i8 = 0;
                        int i9 = 0;
                        while (true) {
                            i3 = this.f10742;
                            if (i8 >= i3) {
                                break;
                            }
                            int iM6705 = this.f10699.m6705();
                            if (i8 % 2 == 0) {
                                this.f10707.putShort((short) (iM6705 - i9));
                            } else {
                                this.f10707.putInt(iM6705 - i9);
                            }
                            i8++;
                            i9 = iM6705;
                        }
                        int i10 = (i - this.f10736) - i9;
                        if (i3 % 2 == 1) {
                            this.f10707.putInt(i10);
                        } else {
                            this.f10707.putShort((short) i10);
                            this.f10707.putInt(0);
                        }
                        this.f10705.m6684(this.f10707.array(), i7);
                        interfaceC3575.mo5885(this.f10705, i7);
                        this.f10737 += i7;
                    }
                }
            } else {
                byte[] bArr2 = c3599.f10754;
                if (bArr2 != null) {
                    this.f10702.m6684(bArr2, bArr2.length);
                }
            }
            if (c3599.f10752 > 0) {
                this.f10733 |= 268435456;
                this.f10706.m6709();
                this.f10699.m6689(4);
                C4140 c4140 = this.f10699;
                byte[] bArr3 = c4140.f13227;
                bArr3[0] = (byte) ((i >> 24) & 255);
                bArr3[1] = (byte) ((i >> 16) & 255);
                bArr3[2] = (byte) ((i >> 8) & 255);
                bArr3[3] = (byte) (i & 255);
                interfaceC3575.mo5885(c4140, 4);
                this.f10737 += 4;
            }
            this.f10739 = true;
        }
        int i11 = i + this.f10702.f13229;
        if (!"V_MPEG4/ISO/AVC".equals(c3599.f10748) && !"V_MPEGH/ISO/HEVC".equals(c3599.f10748)) {
            if (c3599.f10790 != null) {
                C0567.m1932(this.f10702.f13229 == 0);
                C3600 c3600 = c3599.f10790;
                if (!c3600.f10797) {
                    c3558.m5875(c3600.f10796, 0, 10, false);
                    c3558.f10565 = 0;
                    byte[] bArr4 = c3600.f10796;
                    if (bArr4[4] == -8 && bArr4[5] == 114 && bArr4[6] == 111 && (bArr4[7] & 254) == 186) {
                        i2 = 40 << ((bArr4[(bArr4[7] & 255) == 187 ? '\t' : '\b'] >> 4) & 7);
                    } else {
                        i2 = 0;
                    }
                    if (i2 != 0) {
                        c3600.f10797 = true;
                    }
                }
            }
            while (true) {
                int i12 = this.f10736;
                if (i12 >= i11) {
                    break;
                }
                int iM5920 = m5920(c3558, interfaceC3575, i11 - i12);
                this.f10736 += iM5920;
                this.f10737 += iM5920;
            }
        } else {
            byte[] bArr5 = this.f10698.f13227;
            bArr5[0] = 0;
            bArr5[1] = 0;
            bArr5[2] = 0;
            int i13 = c3599.f10795;
            int i14 = 4 - i13;
            while (this.f10736 < i11) {
                int i15 = this.f10738;
                if (i15 == 0) {
                    int iMin = Math.min(i13, this.f10702.m6679());
                    c3558.m5877(bArr5, i14 + iMin, i13 - iMin, false);
                    if (iMin > 0) {
                        C4140 c41402 = this.f10702;
                        System.arraycopy(c41402.f13227, c41402.f13228, bArr5, i14, iMin);
                        c41402.f13228 += iMin;
                    }
                    this.f10736 += i13;
                    this.f10698.m6693(0);
                    this.f10738 = this.f10698.m6705();
                    this.f10697.m6693(0);
                    interfaceC3575.mo5885(this.f10697, 4);
                    this.f10737 += 4;
                } else {
                    int iM59202 = m5920(c3558, interfaceC3575, i15);
                    this.f10736 += iM59202;
                    this.f10737 += iM59202;
                    this.f10738 -= iM59202;
                }
            }
        }
        if ("A_VORBIS".equals(c3599.f10748)) {
            this.f10700.m6693(0);
            interfaceC3575.mo5885(this.f10700, 4);
            this.f10737 += 4;
        }
        int i16 = this.f10737;
        m5926();
        return i16;
    }

    /* JADX INFO: renamed from: ֏, reason: contains not printable characters */
    public final long m5922(long j) throws ParserException {
        long j2 = this.f10710;
        if (j2 != -9223372036854775807L) {
            return C4150.m6797(j, j2, 1000L);
        }
        throw new ParserException("Can't scale timecode prior to timecodeScale being set.");
    }

    @Override // p138.p176.p177.p190.p198.InterfaceC3561
    /* JADX INFO: renamed from: ֏ */
    public final void mo5887() {
    }

    @Override // p138.p176.p177.p190.p198.InterfaceC3561
    /* JADX INFO: renamed from: ֏ */
    public void mo5888(long j, long j2) {
        this.f10720 = -9223372036854775807L;
        this.f10725 = 0;
        C3591 c3591 = (C3591) this.f10693;
        c3591.f10684 = 0;
        c3591.f10681.clear();
        C3602 c3602 = c3591.f10682;
        c3602.f10807 = 0;
        c3602.f10808 = 0;
        C3602 c36022 = this.f10694;
        c36022.f10807 = 0;
        c36022.f10808 = 0;
        m5926();
        for (int i = 0; i < this.f10695.size(); i++) {
            C3600 c3600 = this.f10695.valueAt(i).f10790;
            if (c3600 != null) {
                c3600.f10797 = false;
                c3600.f10798 = 0;
            }
        }
    }

    /* JADX INFO: renamed from: ֏, reason: contains not printable characters */
    public final void m5923(C3558 c3558, int i) throws InterruptedException, EOFException {
        C4140 c4140 = this.f10699;
        if (c4140.f13229 >= i) {
            return;
        }
        byte[] bArr = c4140.f13227;
        if (bArr.length < i) {
            c4140.m6684(Arrays.copyOf(bArr, Math.max(bArr.length * 2, i)), this.f10699.f13229);
        }
        C4140 c41402 = this.f10699;
        byte[] bArr2 = c41402.f13227;
        int i2 = c41402.f13229;
        c3558.m5877(bArr2, i2, i - i2, false);
        this.f10699.m6691(i);
    }

    /* JADX INFO: renamed from: ֏, reason: contains not printable characters */
    public final void m5924(C3558 c3558, byte[] bArr, int i) throws InterruptedException, EOFException {
        int length = bArr.length + i;
        C4140 c4140 = this.f10703;
        byte[] bArr2 = c4140.f13227;
        if (bArr2.length < length) {
            c4140.f13227 = Arrays.copyOf(bArr, length + i);
        } else {
            System.arraycopy(bArr, 0, bArr2, 0, bArr.length);
        }
        c3558.m5877(this.f10703.f13227, bArr.length, i, false);
        this.f10703.m6689(length);
    }

    @Override // p138.p176.p177.p190.p198.InterfaceC3561
    /* JADX INFO: renamed from: ֏ */
    public final void mo5889(InterfaceC3562 interfaceC3562) {
        this.f10745 = interfaceC3562;
    }

    /* JADX WARN: Removed duplicated region for block: B:35:0x0093  */
    /* JADX WARN: Removed duplicated region for block: B:37:0x0096  */
    /* JADX WARN: Removed duplicated region for block: B:41:0x00a9  */
    /* JADX WARN: Removed duplicated region for block: B:45:0x00cb  */
    /* JADX INFO: renamed from: ֏, reason: contains not printable characters */
    /*
        Code decompiled incorrectly, please refer to instructions dump.
    */
    public final void m5925(C3599 c3599, long j, int i, int i2, int i3) {
        byte b;
        byte[] bArrM5918;
        int i4;
        int i5;
        int i6 = i;
        C3600 c3600 = c3599.f10790;
        if (c3600 != null) {
            if (c3600.f10797) {
                int i7 = c3600.f10798;
                c3600.f10798 = i7 + 1;
                if (i7 == 0) {
                    c3600.f10799 = j;
                    c3600.f10800 = i6;
                    c3600.f10801 = 0;
                }
                c3600.f10801 += i2;
                c3600.f10802 = i3;
                if (c3600.f10798 >= 16) {
                    c3600.m5928(c3599);
                }
            }
        } else if ("S_TEXT/UTF8".equals(c3599.f10748) || "S_TEXT/ASS".equals(c3599.f10748)) {
            if (this.f10729 > 1) {
                Log.w("MatroskaExtractor", "Skipping subtitle sample in laced block.");
            } else {
                long j2 = this.f10727;
                if (j2 == -9223372036854775807L) {
                    Log.w("MatroskaExtractor", "Skipping subtitle sample with no duration.");
                } else {
                    String str = c3599.f10748;
                    byte[] bArr = this.f10703.f13227;
                    int iHashCode = str.hashCode();
                    if (iHashCode != 738597099) {
                        b = (iHashCode == 1422270023 && str.equals("S_TEXT/UTF8")) ? (byte) 0 : (byte) -1;
                        if (b != 0) {
                            bArrM5918 = m5918(j2, "%02d:%02d:%02d,%03d", 1000L);
                            i4 = 19;
                        } else {
                            if (b != 1) {
                                throw new IllegalArgumentException();
                            }
                            bArrM5918 = m5918(j2, "%01d:%02d:%02d:%02d", 10000L);
                            i4 = 21;
                        }
                        System.arraycopy(bArrM5918, 0, bArr, i4, bArrM5918.length);
                        InterfaceC3575 interfaceC3575 = c3599.f10794;
                        C4140 c4140 = this.f10703;
                        interfaceC3575.mo5885(c4140, c4140.f13229);
                        i5 = i2 + this.f10703.f13229;
                        if ((268435456 & i6) != 0) {
                            if (this.f10729 > 1) {
                                i6 &= -268435457;
                            } else {
                                C4140 c41402 = this.f10706;
                                int i8 = c41402.f13229;
                                c3599.f10794.mo5885(c41402, i8);
                                i5 += i8;
                            }
                        }
                        c3599.f10794.mo5883(j, i6, i5, i3, c3599.f10755);
                    } else {
                        if (str.equals("S_TEXT/ASS")) {
                            b = 1;
                        }
                        if (b != 0) {
                        }
                        System.arraycopy(bArrM5918, 0, bArr, i4, bArrM5918.length);
                        InterfaceC3575 interfaceC35752 = c3599.f10794;
                        C4140 c41403 = this.f10703;
                        interfaceC35752.mo5885(c41403, c41403.f13229);
                        i5 = i2 + this.f10703.f13229;
                        if ((268435456 & i6) != 0) {
                        }
                        c3599.f10794.mo5883(j, i6, i5, i3, c3599.f10755);
                    }
                }
            }
            i5 = i2;
            if ((268435456 & i6) != 0) {
            }
            c3599.f10794.mo5883(j, i6, i5, i3, c3599.f10755);
        } else {
            i5 = i2;
            if ((268435456 & i6) != 0) {
            }
            c3599.f10794.mo5883(j, i6, i5, i3, c3599.f10755);
        }
        this.f10724 = true;
    }

    @Override // p138.p176.p177.p190.p198.InterfaceC3561
    /* JADX INFO: renamed from: ֏ */
    public final boolean mo5890(C3558 c3558) throws InterruptedException, EOFException {
        C3601 c3601 = new C3601();
        long j = c3558.f10562;
        long j2 = 1024;
        if (j != -1 && j <= 1024) {
            j2 = j;
        }
        int i = (int) j2;
        c3558.m5875(c3601.f10803.f13227, 0, 4, false);
        c3601.f10804 = 4;
        for (long jM6703 = c3601.f10803.m6703(); jM6703 != 440786851; jM6703 = ((long) (c3601.f10803.f13227[0] & 255)) | ((jM6703 << 8) & (-256))) {
            int i2 = c3601.f10804 + 1;
            c3601.f10804 = i2;
            if (i2 == i) {
                return false;
            }
            c3558.m5875(c3601.f10803.f13227, 0, 1, false);
        }
        long jM5929 = c3601.m5929(c3558);
        long j3 = c3601.f10804;
        if (jM5929 == Long.MIN_VALUE) {
            return false;
        }
        if (j != -1 && j3 + jM5929 >= j) {
            return false;
        }
        while (true) {
            long j4 = c3601.f10804;
            long j5 = j3 + jM5929;
            if (j4 >= j5) {
                return j4 == j5;
            }
            if (c3601.m5929(c3558) == Long.MIN_VALUE) {
                return false;
            }
            long jM59292 = c3601.m5929(c3558);
            if (jM59292 < 0 || jM59292 > 2147483647L) {
                return false;
            }
            if (jM59292 != 0) {
                int i3 = (int) jM59292;
                c3558.m5874(i3, false);
                c3601.f10804 += i3;
            }
        }
    }

    /* JADX INFO: renamed from: ؠ, reason: contains not printable characters */
    public final void m5926() {
        this.f10736 = 0;
        this.f10737 = 0;
        this.f10738 = 0;
        this.f10739 = false;
        this.f10740 = false;
        this.f10741 = false;
        this.f10742 = 0;
        this.f10743 = (byte) 0;
        this.f10744 = false;
        this.f10702.m6709();
    }
}
