package defpackage;

import android.os.SystemClock;
import androidx.media3.datasource.HttpDataSource$InvalidResponseCodeException;
import androidx.media3.exoplayer.source.BehindLiveWindowException;
import j$.util.Objects;
import java.io.IOException;
import java.util.ArrayList;
import java.util.HashMap;
import java.util.HashSet;
import java.util.List;
import java.util.Map;

/* JADX INFO: renamed from: ᵭⁱᵠ, reason: contains not printable characters */
/* JADX INFO: loaded from: classes3.dex */
public final class C4187 implements InterfaceC0968 {

    /* JADX INFO: renamed from: ʽˈˋ, reason: contains not printable characters */
    public final ᵥᵵᵶᵩ f15969;

    /* JADX INFO: renamed from: ˊᵫᵗ, reason: contains not printable characters */
    public final C2676 f15970;

    /* JADX INFO: renamed from: ˋˈ, reason: contains not printable characters */
    public boolean f15971;

    /* JADX INFO: renamed from: ːˏᵟᵯ, reason: contains not printable characters */
    public final int[] f15972;

    /* JADX INFO: renamed from: ᵝᵶ, reason: contains not printable characters */
    public BehindLiveWindowException f15973;

    /* JADX INFO: renamed from: ᵨᵣ, reason: contains not printable characters */
    public final InterfaceC1070 f15974;

    /* JADX INFO: renamed from: ᵮᵣᵗˈ, reason: contains not printable characters */
    public int f15975;

    /* JADX INFO: renamed from: ᵱᵽʡᵚ, reason: contains not printable characters */
    public InterfaceC2380 f15976;

    /* JADX INFO: renamed from: ᵲᵶᵳˈ, reason: contains not printable characters */
    public final InterfaceC3244 f15977;

    /* JADX INFO: renamed from: ᵵᵽ, reason: contains not printable characters */
    public final int f15978;

    /* JADX INFO: renamed from: ᵶᵥᵝ, reason: contains not printable characters */
    public C2906 f15979;

    /* JADX INFO: renamed from: ᵷᵺʾᵖ, reason: contains not printable characters */
    public final int f15980;

    /* JADX INFO: renamed from: ᵻʽᵯ, reason: contains not printable characters */
    public final C2693[] f15981;

    /* JADX INFO: renamed from: ᵻˈᵦʼ, reason: contains not printable characters */
    public final long f15982;

    /* JADX WARN: Multi-variable type inference failed */
    /* JADX WARN: Type inference failed for: r0v0, types: [java.lang.Object, ᵭⁱᵠ] */
    public C4187(ˁʢᵛ r21, InterfaceC3244 interfaceC3244, C2906 c2906, ᵥᵵᵶᵩ r24, int i, int[] iArr, InterfaceC2380 interfaceC2380, int i2, InterfaceC1070 interfaceC1070, long j, int i3, boolean z, ArrayList arrayList, C2676 c2676) {
        C5286 c5286;
        C2693[] c2693Arr;
        AbstractC0841 abstractC0841;
        int i4;
        InterfaceC4291 c4461;
        C3511 c3511;
        ?? obj = new Object();
        obj.f15977 = interfaceC3244;
        obj.f15979 = c2906;
        obj.f15969 = r24;
        obj.f15972 = iArr;
        obj.f15976 = interfaceC2380;
        obj.f15980 = i2;
        obj.f15974 = interfaceC1070;
        obj.f15975 = i;
        obj.f15982 = j;
        obj.f15978 = i3;
        C2676 c26762 = c2676;
        obj.f15970 = c26762;
        long jM6972 = c2906.m6972(i);
        ArrayList arrayListM9119 = obj.m9119();
        obj.f15981 = new C2693[interfaceC2380.length()];
        int i5 = 0;
        int i6 = 0;
        C4187 c4187 = obj;
        while (i6 < c4187.f15981.length) {
            AbstractC0841 abstractC08412 = (AbstractC0841) arrayListM9119.get(interfaceC2380.mo3741(i6));
            C1318 c1318 = r24.ʿᵿʽᵞ(abstractC08412.f3742);
            C2693[] c2693Arr2 = c4187.f15981;
            C1318 c13182 = c1318 == null ? (C1318) abstractC08412.f3742.get(i5) : c1318;
            C5286 c52862 = abstractC08412.f3740;
            r21.getClass();
            String str = c52862.f19972;
            if (!AbstractC4208.m9129(str)) {
                if (str != null && (str.startsWith("video/webm") || str.startsWith("audio/webm") || str.startsWith("application/webm") || str.startsWith("video/x-matroska") || str.startsWith("audio/x-matroska") || str.startsWith("application/x-matroska"))) {
                    i4 = i6;
                    abstractC0841 = abstractC08412;
                    c5286 = c52862;
                    c2693Arr = c2693Arr2;
                    c4461 = new C2889((ᵱᵻᵧᵷ) r21.ᵔᵖᵹᵫ, r21.ˌᴵ ? 1 : 3);
                } else if (Objects.equals(str, "image/jpeg")) {
                    c4461 = new C5560(1);
                } else if (Objects.equals(str, "image/png")) {
                    c4461 = new C5560((byte) 0, 1);
                } else {
                    int i7 = z ? 4 : 0;
                    c5286 = c52862;
                    c2693Arr = c2693Arr2;
                    abstractC0841 = abstractC08412;
                    i4 = i6;
                    c4461 = new C4461((ᵱᵻᵧᵷ) r21.ᵔᵖᵹᵫ, (r21.ˌᴵ ? i7 : i7 | 32) | C4461.m9499(r21.ᵜᵪʾ), null, null, arrayList, c26762);
                }
                c3511 = new C3511(c4461, i2, c5286);
                long j2 = jM6972;
                c2693Arr[i4] = new C2693(j2, abstractC0841, c13182, c3511, 0L, abstractC0841.mo2987());
                i6 = i4 + 1;
                c4187 = this;
                c26762 = c2676;
                jM6972 = j2;
                i5 = 0;
            } else if (r21.ˌᴵ) {
                c4461 = new C1229(((ᵱᵻᵧᵷ) r21.ᵔᵖᵹᵫ).ᵱʡˏ(c52862), c52862);
            } else {
                c3511 = null;
                i4 = i6;
                abstractC0841 = abstractC08412;
                c2693Arr = c2693Arr2;
                long j22 = jM6972;
                c2693Arr[i4] = new C2693(j22, abstractC0841, c13182, c3511, 0L, abstractC0841.mo2987());
                i6 = i4 + 1;
                c4187 = this;
                c26762 = c2676;
                jM6972 = j22;
                i5 = 0;
            }
            i4 = i6;
            abstractC0841 = abstractC08412;
            c5286 = c52862;
            c2693Arr = c2693Arr2;
            c3511 = new C3511(c4461, i2, c5286);
            long j222 = jM6972;
            c2693Arr[i4] = new C2693(j222, abstractC0841, c13182, c3511, 0L, abstractC0841.mo2987());
            i6 = i4 + 1;
            c4187 = this;
            c26762 = c2676;
            jM6972 = j222;
            i5 = 0;
        }
    }

    @Override // defpackage.InterfaceC0968
    /* JADX INFO: renamed from: ʽˈˋ */
    public final void mo3281() throws BehindLiveWindowException {
        BehindLiveWindowException behindLiveWindowException = this.f15973;
        if (behindLiveWindowException != null) {
            throw behindLiveWindowException;
        }
        this.f15977.mo7395();
    }

    @Override // defpackage.InterfaceC0968
    /* JADX INFO: renamed from: ˊᵫᵗ */
    public final int mo3282(long j, List list) {
        return (this.f15973 != null || this.f15976.length() < 2) ? list.size() : this.f15976.mo3743(j, list);
    }

    /* JADX WARN: Removed duplicated region for block: B:17:0x0054  */
    @Override // defpackage.InterfaceC0968
    /* JADX INFO: renamed from: ːˏᵟᵯ */
    /*
        Code decompiled incorrectly, please refer to instructions dump.
    */
    public final long mo3283(long j, C3318 c3318) {
        long jM6501;
        long j2 = j;
        C2693[] c2693Arr = this.f15981;
        int length = c2693Arr.length;
        int i = 0;
        while (i < length) {
            C2693 c2693 = c2693Arr[i];
            InterfaceC1674 interfaceC1674 = c2693.f10370;
            long j3 = c2693.f10371;
            InterfaceC1674 interfaceC16742 = c2693.f10370;
            if (interfaceC1674 != null) {
                long jM6500 = c2693.m6500();
                if (jM6500 != 0) {
                    interfaceC16742.getClass();
                    long jMo3001 = interfaceC16742.mo3001(j2, c2693.f10368) + j3;
                    long jM65012 = c2693.m6501(jMo3001);
                    if (jM65012 >= j2) {
                        jM6501 = jM65012;
                    } else {
                        if (jM6500 != -1) {
                            interfaceC16742.getClass();
                            if (jMo3001 < ((interfaceC16742.mo3006() + j3) + jM6500) - 1) {
                            }
                        }
                        jM6501 = c2693.m6501(jMo3001 + 1);
                    }
                    return c3318.m7597(j2, jM65012, jM6501);
                }
            }
            i++;
            j2 = j;
        }
        return j;
    }

    @Override // defpackage.InterfaceC0968
    /* JADX INFO: renamed from: ᵨᵣ */
    public final void mo3284(AbstractC1900 abstractC1900) {
        if (abstractC1900 instanceof C3907) {
            int iMo3744 = this.f15976.mo3744(((C3907) abstractC1900).f7531);
            C2693[] c2693Arr = this.f15981;
            C2693 c2693 = c2693Arr[iMo3744];
            if (c2693.f10370 == null) {
                C3511 c3511 = c2693.f10369;
                c3511.getClass();
                C0053 c0053M8013 = c3511.m8013();
                if (c0053M8013 != null) {
                    AbstractC0841 abstractC0841 = c2693.f10366;
                    c2693Arr[iMo3744] = new C2693(c2693.f10368, abstractC0841, c2693.f10367, c2693.f10369, c2693.f10371, new C1705(c0053M8013, abstractC0841.f3741, 1));
                }
            }
        }
        C2676 c2676 = this.f15970;
        if (c2676 != null) {
            long j = c2676.f10341;
            if (j == -9223372036854775807L || abstractC1900.f7528 > j) {
                c2676.f10341 = abstractC1900.f7528;
            }
            c2676.f10339.f17594 = true;
        }
    }

    /* JADX INFO: renamed from: ᵱᵽʡᵚ, reason: contains not printable characters */
    public final C2693 m9118(int i) {
        C2693[] c2693Arr = this.f15981;
        C2693 c2693 = c2693Arr[i];
        C1318 c1318 = this.f15969.ʿᵿʽᵞ(c2693.f10366.f3742);
        if (c1318 == null || c1318.equals(c2693.f10367)) {
            return c2693;
        }
        C2693 c26932 = new C2693(c2693.f10368, c2693.f10366, c1318, c2693.f10369, c2693.f10371, c2693.f10370);
        c2693Arr[i] = c26932;
        return c26932;
    }

    @Override // defpackage.InterfaceC0968
    /* JADX INFO: renamed from: ᵲᵶᵳˈ */
    public final void mo3285() {
        for (C2693 c2693 : this.f15981) {
            C3511 c3511 = c2693.f10369;
            if (c3511 != null) {
                c3511.f13484.mo1256();
            }
        }
    }

    @Override // defpackage.InterfaceC0968
    /* JADX INFO: renamed from: ᵵᵽ */
    public final boolean mo3286(AbstractC1900 abstractC1900, boolean z, C1785 c1785, C1013 c1013) {
        long jMax;
        if (z) {
            C2676 c2676 = this.f15970;
            if (c2676 != null) {
                long j = c2676.f10341;
                boolean z2 = j != -9223372036854775807L && j < abstractC1900.f7526;
                C4627 c4627 = c2676.f10339;
                if (c4627.f17601.f11185) {
                    if (!c4627.f17596) {
                        if (z2) {
                            if (c4627.f17594) {
                                c4627.f17596 = true;
                                c4627.f17594 = false;
                                C4002 c4002 = c4627.f17598.f20032;
                                c4002.f15336.removeCallbacks(c4002.f15363);
                                c4002.m8791();
                                return true;
                            }
                        }
                    }
                    return true;
                }
            }
            boolean z3 = this.f15979.f11185;
            C2693[] c2693Arr = this.f15981;
            if (!z3 && (abstractC1900 instanceof AbstractC4352)) {
                IOException iOException = (IOException) c1785.f7162;
                if ((iOException instanceof HttpDataSource$InvalidResponseCodeException) && ((HttpDataSource$InvalidResponseCodeException) iOException).f560 == 404) {
                    C2693 c2693 = c2693Arr[this.f15976.mo3744(abstractC1900.f7531)];
                    long jM6500 = c2693.m6500();
                    if (jM6500 != -1 && jM6500 != 0) {
                        InterfaceC1674 interfaceC1674 = c2693.f10370;
                        interfaceC1674.getClass();
                        if (((AbstractC4352) abstractC1900).mo3274() > ((interfaceC1674.mo3006() + c2693.f10371) + jM6500) - 1) {
                            this.f15971 = true;
                            return true;
                        }
                    }
                }
            }
            C2693 c26932 = c2693Arr[this.f15976.mo3744(abstractC1900.f7531)];
            AbstractC0841 abstractC0841 = c26932.f10366;
            C1318 c1318 = c26932.f10367;
            AbstractC4509 abstractC4509 = abstractC0841.f3742;
            ᵥᵵᵶᵩ r4 = this.f15969;
            C1318 c13182 = r4.ʿᵿʽᵞ(abstractC4509);
            if (c13182 == null || c1318.equals(c13182)) {
                InterfaceC2380 interfaceC2380 = this.f15976;
                AbstractC4509 abstractC45092 = c26932.f10366.f3742;
                long jElapsedRealtime = SystemClock.elapsedRealtime();
                int length = interfaceC2380.length();
                int i = 0;
                for (int i2 = 0; i2 < length; i2++) {
                    if (interfaceC2380.mo3737(jElapsedRealtime, i2)) {
                        i++;
                    }
                }
                HashSet hashSet = new HashSet();
                for (int i3 = 0; i3 < abstractC45092.size(); i3++) {
                    hashSet.add(Integer.valueOf(((C1318) abstractC45092.get(i3)).f5497));
                }
                int size = hashSet.size();
                HashSet hashSet2 = new HashSet();
                ArrayList arrayList = r4.ᵝᵶ(abstractC45092);
                for (int i4 = 0; i4 < arrayList.size(); i4++) {
                    hashSet2.add(Integer.valueOf(((C1318) arrayList.get(i4)).f5497));
                }
                C4973 c4973 = new C4973(size, size - hashSet2.size(), length, i);
                if (c4973.m10283(2) || c4973.m10283(1)) {
                    c1013.getClass();
                    C0655 c0655M3344 = C1013.m3344(c4973, c1785);
                    if (c0655M3344 != null) {
                        long j2 = c0655M3344.f3093;
                        int i5 = c0655M3344.f3092;
                        if (c4973.m10283(i5)) {
                            if (i5 == 2) {
                                InterfaceC2380 interfaceC23802 = this.f15976;
                                return interfaceC23802.mo3739(j2, interfaceC23802.mo3744(abstractC1900.f7531));
                            }
                            if (i5 == 1) {
                                long jElapsedRealtime2 = SystemClock.elapsedRealtime() + j2;
                                String str = c1318.f5496;
                                HashMap map = (HashMap) r4.ᵜᵪʾ;
                                if (map.containsKey(str)) {
                                    Long l = (Long) map.get(str);
                                    String str2 = AbstractC0956.f4222;
                                    jMax = Math.max(jElapsedRealtime2, l.longValue());
                                } else {
                                    jMax = jElapsedRealtime2;
                                }
                                map.put(str, Long.valueOf(jMax));
                                int i6 = c1318.f5497;
                                if (i6 != Integer.MIN_VALUE) {
                                    Integer numValueOf = Integer.valueOf(i6);
                                    HashMap map2 = (HashMap) r4.ᵔᵖᵹᵫ;
                                    if (map2.containsKey(numValueOf)) {
                                        Long l2 = (Long) map2.get(numValueOf);
                                        String str3 = AbstractC0956.f4222;
                                        jElapsedRealtime2 = Math.max(jElapsedRealtime2, l2.longValue());
                                    }
                                    map2.put(numValueOf, Long.valueOf(jElapsedRealtime2));
                                }
                            }
                        }
                    }
                }
            }
            return true;
        }
        return false;
    }

    /* JADX WARN: Multi-variable type inference failed */
    @Override // defpackage.InterfaceC0968
    /* JADX INFO: renamed from: ᵷᵺʾᵖ */
    public final void mo3287(C2348 c2348, long j, List list, C5559 c5559) {
        long j2;
        long j3;
        List list2;
        AbstractC4352 abstractC4352;
        C2693[] c2693Arr;
        long j4;
        long j5;
        long jMax;
        long j6;
        int i;
        long j7;
        long jM3267;
        int i2;
        Object c0957;
        long jM3214;
        long jM32672;
        boolean z;
        if (this.f15973 != null) {
            return;
        }
        long j8 = c2348.f9212;
        long j9 = j - j8;
        long jM32142 = AbstractC0956.m3214(this.f15979.m6970(this.f15975).f6964) + AbstractC0956.m3214(this.f15979.f11182) + j;
        int i3 = 0;
        C2676 c2676 = this.f15970;
        if (c2676 != null) {
            C4627 c4627 = c2676.f10339;
            C2906 c2906 = c4627.f17601;
            j3 = -9223372036854775807L;
            C5306 c5306 = c4627.f17598;
            if (!c2906.f11185) {
                j2 = j8;
                z = false;
            } else if (c4627.f17596) {
                j2 = j8;
                z = true;
            } else {
                j2 = j8;
                Map.Entry entryCeilingEntry = c4627.f17600.ceilingEntry(Long.valueOf(c2906.f11176));
                if (entryCeilingEntry == null || ((Long) entryCeilingEntry.getValue()).longValue() >= jM32142) {
                    z = false;
                } else {
                    long jLongValue = ((Long) entryCeilingEntry.getKey()).longValue();
                    C4002 c4002 = c5306.f20032;
                    long j10 = c4002.f15355;
                    if (j10 == -9223372036854775807L || j10 < jLongValue) {
                        c4002.f15355 = jLongValue;
                    }
                    z = true;
                }
                if (z && c4627.f17594) {
                    c4627.f17596 = true;
                    c4627.f17594 = false;
                    C4002 c40022 = c5306.f20032;
                    c40022.f15336.removeCallbacks(c40022.f15363);
                    c40022.m8791();
                }
            }
            if (z) {
                return;
            }
        } else {
            j2 = j8;
            j3 = -9223372036854775807L;
        }
        long jM32143 = AbstractC0956.m3214(AbstractC0956.m3240(this.f15982));
        C2906 c29062 = this.f15979;
        long j11 = c29062.f11182;
        long jM32144 = j11 == j3 ? j3 : jM32143 - AbstractC0956.m3214(j11 + c29062.m6970(this.f15975).f6964);
        if (list.isEmpty()) {
            list2 = list;
            abstractC4352 = null;
        } else {
            list2 = list;
            abstractC4352 = (AbstractC4352) list2.get(list.size() - 1);
        }
        int length = this.f15976.length();
        InterfaceC2178[] interfaceC2178Arr = new InterfaceC2178[length];
        int i4 = 0;
        while (true) {
            c2693Arr = this.f15981;
            if (i4 >= length) {
                break;
            }
            C2693 c2693 = c2693Arr[i4];
            int i5 = i3;
            InterfaceC1674 interfaceC1674 = c2693.f10370;
            long j12 = jM32144;
            long j13 = c2693.f10371;
            long j14 = c2693.f10368;
            ᵖˊʨ r27 = InterfaceC2178.f8675;
            if (interfaceC1674 == null) {
                interfaceC2178Arr[i4] = r27;
            } else {
                interfaceC1674.getClass();
                long jMo3010 = interfaceC1674.mo3010(j14, jM32143) + j13;
                long jM6499 = c2693.m6499(jM32143);
                if (abstractC4352 != null) {
                    jM32672 = abstractC4352.mo3274();
                } else {
                    InterfaceC1674 interfaceC16742 = c2693.f10370;
                    interfaceC16742.getClass();
                    jM32672 = AbstractC0956.m3267(interfaceC16742.mo3001(j, j14) + j13, jMo3010, jM6499);
                }
                long j15 = jM32672;
                if (j15 < jMo3010) {
                    interfaceC2178Arr[i4] = r27;
                } else {
                    interfaceC2178Arr[i4] = new C4904(m9118(i4), j15, jM6499);
                }
            }
            i4++;
            i3 = i5;
            jM32144 = j12;
        }
        long j16 = jM32144;
        int i6 = i3;
        if (!this.f15979.f11185 || c2693Arr[i6].m6500() == 0) {
            j4 = j9;
            j5 = 0;
            jMax = j3;
        } else {
            long jM6503 = c2693Arr[i6].m6503(c2693Arr[i6].m6499(jM32143));
            C2906 c29063 = this.f15979;
            long j17 = c29063.f11182;
            if (j17 == j3) {
                j4 = j9;
                jM3214 = j3;
            } else {
                j4 = j9;
                jM3214 = jM32143 - AbstractC0956.m3214(j17 + c29063.m6970(this.f15975).f6964);
            }
            long jMin = Math.min(jM3214, jM6503) - j2;
            j5 = 0;
            jMax = Math.max(0L, jMin);
        }
        long j18 = j5;
        this.f15976.mo3510(j2, j4, jMax, list2, interfaceC2178Arr);
        int iMo3508 = this.f15976.mo3508();
        SystemClock.elapsedRealtime();
        C2693 c2693M9118 = m9118(iMo3508);
        long j19 = c2693M9118.f10368;
        long j20 = c2693M9118.f10371;
        InterfaceC1674 interfaceC16743 = c2693M9118.f10370;
        C1318 c1318 = c2693M9118.f10367;
        C3511 c3511 = c2693M9118.f10369;
        AbstractC0841 abstractC0841 = c2693M9118.f10366;
        if (c3511 != null) {
            i = 1;
            C4281 c4281 = c3511.f13486 == null ? abstractC0841.f3744 : null;
            j6 = j20;
            C4281 c4281Mo2986 = interfaceC16743 == null ? abstractC0841.mo2986() : null;
            if (c4281 != null || c4281Mo2986 != null) {
                C5286 c5286Mo3738 = this.f15976.mo3738();
                int iMo3509 = this.f15976.mo3509();
                Object objMo3507 = this.f15976.mo3507();
                if (c4281 != null) {
                    C4281 c4281M9260 = c4281.m9260(c4281Mo2986, c1318.f5498);
                    if (c4281M9260 != null) {
                        c4281 = c4281M9260;
                    }
                } else {
                    c4281Mo2986.getClass();
                    c4281 = c4281Mo2986;
                }
                c5559.f20984 = new C3907(this.f15974, ᵱˉˈ.ᵻʽᵯ(abstractC0841, c1318.f5498, c4281, i6), c5286Mo3738, iMo3509, objMo3507, c2693M9118.f10369);
                return;
            }
        } else {
            j6 = j20;
            i = 1;
        }
        C2906 c29064 = this.f15979;
        int i7 = (c29064.f11185 && this.f15975 == c29064.f11178.size() + (-1)) ? i : i6;
        boolean z2 = (i7 == 0 || j19 != j3) ? i : i6;
        if (c2693M9118.m6500() == j18) {
            c5559.f20983 = z2;
            return;
        }
        interfaceC16743.getClass();
        long jMo30102 = interfaceC16743.mo3010(j19, jM32143) + j6;
        long jM64992 = c2693M9118.m6499(jM32143);
        boolean z3 = z2;
        if (i7 != 0) {
            long jM65032 = c2693M9118.m6503(jM64992);
            z3 = (z2 ? 1 : 0) & ((jM65032 - c2693M9118.m6501(jM64992)) + jM65032 >= j19 ? i : i6);
        }
        if (abstractC4352 != null) {
            jM3267 = abstractC4352.mo3274();
            j7 = jM64992;
        } else {
            interfaceC16743.getClass();
            j7 = jM64992;
            jM3267 = AbstractC0956.m3267(interfaceC16743.mo3001(j, j19) + j6, jMo30102, j7);
        }
        long j21 = jM3267;
        if (j21 < jMo30102) {
            this.f15973 = new BehindLiveWindowException();
            return;
        }
        if (j21 > j7 || (this.f15971 && j21 >= j7)) {
            c5559.f20983 = z3;
            return;
        }
        if (z3 != 0 && c2693M9118.m6501(j21) >= j19) {
            c5559.f20983 = i;
            return;
        }
        int iMin = (int) Math.min(this.f15978, (j7 - j21) + 1);
        int i8 = (j19 > j3 ? 1 : (j19 == j3 ? 0 : -1));
        int i9 = 1;
        if (i8 != 0) {
            while (iMin > 1 && c2693M9118.m6501((((long) iMin) + j21) - 1) >= j19) {
                iMin--;
            }
        }
        long j22 = list.isEmpty() ? j : j3;
        C5286 c5286Mo37382 = this.f15976.mo3738();
        int iMo35092 = this.f15976.mo3509();
        Object objMo35072 = this.f15976.mo3507();
        long jM6501 = c2693M9118.m6501(j21);
        interfaceC16743.getClass();
        C4281 c4281Mo3005 = interfaceC16743.mo3005(j21 - j6);
        InterfaceC1070 interfaceC1070 = this.f15974;
        if (c3511 == null) {
            c0957 = new C2535(interfaceC1070, ᵱˉˈ.ᵻʽᵯ(abstractC0841, c1318.f5498, c4281Mo3005, c2693M9118.m6504(j21, j16) ? 0 : 8), c5286Mo37382, iMo35092, objMo35072, jM6501, c2693M9118.m6503(j21), j21, this.f15980, c5286Mo37382);
        } else {
            C4281 c42812 = c4281Mo3005;
            int i10 = 1;
            while (true) {
                if (i9 >= iMin) {
                    i2 = i8;
                    break;
                }
                int i11 = iMin;
                i2 = i8;
                interfaceC16743.getClass();
                C4281 c4281M92602 = c42812.m9260(interfaceC16743.mo3005((j21 + ((long) i9)) - j6), c1318.f5498);
                if (c4281M92602 == null) {
                    break;
                }
                i10++;
                i9++;
                i8 = i2;
                c42812 = c4281M92602;
                iMin = i11;
            }
            long j23 = (j21 + ((long) i10)) - 1;
            long jM65033 = c2693M9118.m6503(j23);
            long j24 = (i2 == 0 || j19 > jM65033) ? j3 : j19;
            C0084 c0084 = ᵱˉˈ.ᵻʽᵯ(abstractC0841, c1318.f5498, c42812, c2693M9118.m6504(j23, j16) ? 0 : 8);
            long j25 = -abstractC0841.f3741;
            if (AbstractC4208.m9131(c5286Mo37382.f19987)) {
                j25 += jM6501;
            }
            c0957 = new C0957(interfaceC1070, c0084, c5286Mo37382, iMo35092, objMo35072, jM6501, jM65033, j22, j24, j21, i10, j25, c2693M9118.f10369);
        }
        c5559.f20984 = c0957;
    }

    /* JADX INFO: renamed from: ᵻʽᵯ, reason: contains not printable characters */
    public final ArrayList m9119() {
        List list = this.f15979.m6970(this.f15975).f6965;
        ArrayList arrayList = new ArrayList();
        for (int i : this.f15972) {
            arrayList.addAll(((C2104) list.get(i)).f8364);
        }
        return arrayList;
    }

    @Override // defpackage.InterfaceC0968
    /* JADX INFO: renamed from: ᵻˈᵦʼ */
    public final boolean mo3288(long j, AbstractC1900 abstractC1900, List list) {
        if (this.f15973 != null) {
            return false;
        }
        return this.f15976.mo3746(j, abstractC1900, list);
    }
}
