package v0;

import android.graphics.Path;
import java.util.List;
import p0.AbstractC2704j;
import p0.AbstractC2711q;
import p0.C2702h;
import p0.C2703i;
import r0.InterfaceC2866e;

/* JADX INFO: renamed from: v0.h, reason: case insensitive filesystem */
/* JADX INFO: loaded from: classes.dex */
public final class C3070h extends AbstractC3061C {

    /* JADX INFO: renamed from: b, reason: collision with root package name */
    public AbstractC2711q f25163b;

    /* JADX INFO: renamed from: c, reason: collision with root package name */
    public float f25164c = 1.0f;

    /* JADX INFO: renamed from: d, reason: collision with root package name */
    public List f25165d;

    /* JADX INFO: renamed from: e, reason: collision with root package name */
    public float f25166e;

    /* JADX INFO: renamed from: f, reason: collision with root package name */
    public float f25167f;

    /* JADX INFO: renamed from: g, reason: collision with root package name */
    public AbstractC2711q f25168g;

    /* JADX INFO: renamed from: h, reason: collision with root package name */
    public int f25169h;

    /* JADX INFO: renamed from: i, reason: collision with root package name */
    public int f25170i;

    /* JADX INFO: renamed from: j, reason: collision with root package name */
    public float f25171j;

    /* JADX INFO: renamed from: k, reason: collision with root package name */
    public float f25172k;
    public float l;

    /* JADX INFO: renamed from: m, reason: collision with root package name */
    public float f25173m;

    /* JADX INFO: renamed from: n, reason: collision with root package name */
    public boolean f25174n;

    /* JADX INFO: renamed from: o, reason: collision with root package name */
    public boolean f25175o;

    /* JADX INFO: renamed from: p, reason: collision with root package name */
    public boolean f25176p;

    /* JADX INFO: renamed from: q, reason: collision with root package name */
    public r0.i f25177q;

    /* JADX INFO: renamed from: r, reason: collision with root package name */
    public final C2702h f25178r;

    /* JADX INFO: renamed from: s, reason: collision with root package name */
    public C2702h f25179s;

    /* JADX INFO: renamed from: t, reason: collision with root package name */
    public C2702h f25180t;

    /* JADX INFO: renamed from: u, reason: collision with root package name */
    public final Object f25181u;

    public C3070h() {
        int i6 = M.f25065a;
        this.f25165d = x4.y.f26065a;
        this.f25166e = 1.0f;
        this.f25169h = 0;
        this.f25170i = 0;
        this.f25171j = 4.0f;
        this.l = 1.0f;
        this.f25174n = true;
        this.f25175o = true;
        C2702h c2702hA = AbstractC2704j.a();
        this.f25178r = c2702hA;
        this.f25179s = c2702hA;
        this.f25181u = m1.g.j(w4.i.f25467c, C3069g.f25157b);
    }

    @Override // v0.AbstractC3061C
    public final void a(InterfaceC2866e interfaceC2866e) {
        InterfaceC2866e interfaceC2866e2;
        r0.i iVar;
        if (this.f25174n) {
            AbstractC3064b.j(this.f25165d, this.f25178r);
            e();
        } else if (this.f25176p) {
            e();
        }
        this.f25174n = false;
        this.f25176p = false;
        AbstractC2711q abstractC2711q = this.f25163b;
        if (abstractC2711q != null) {
            interfaceC2866e2 = interfaceC2866e;
            InterfaceC2866e.y(interfaceC2866e2, this.f25179s, abstractC2711q, this.f25164c, null, 56);
        } else {
            interfaceC2866e2 = interfaceC2866e;
        }
        AbstractC2711q abstractC2711q2 = this.f25168g;
        if (abstractC2711q2 != null) {
            r0.i iVar2 = this.f25177q;
            if (this.f25175o || iVar2 == null) {
                r0.i iVar3 = new r0.i(this.f25169h, this.f25170i, this.f25167f, this.f25171j, 16);
                this.f25177q = iVar3;
                this.f25175o = false;
                iVar = iVar3;
            } else {
                iVar = iVar2;
            }
            InterfaceC2866e.y(interfaceC2866e2, this.f25179s, abstractC2711q2, this.f25166e, iVar, 48);
        }
    }

    /* JADX WARN: Type inference failed for: r0v11, types: [java.lang.Object, w4.h] */
    public final void e() {
        Path path;
        float f6 = this.f25172k;
        C2702h c2702h = this.f25178r;
        if (f6 == 0.0f && this.l == 1.0f) {
            this.f25179s = c2702h;
            return;
        }
        if (kotlin.jvm.internal.o.c(this.f25179s, c2702h)) {
            this.f25179s = AbstractC2704j.a();
        } else {
            Path.FillType fillType = this.f25179s.f22920a.getFillType();
            Path.FillType fillType2 = Path.FillType.EVEN_ODD;
            boolean z6 = fillType == fillType2;
            this.f25179s.f22920a.rewind();
            C2702h c2702h2 = this.f25179s;
            c2702h2.getClass();
            if (!z6) {
                fillType2 = Path.FillType.WINDING;
            }
            c2702h2.f22920a.setFillType(fillType2);
        }
        ?? r02 = this.f25181u;
        C2703i c2703i = (C2703i) r02.getValue();
        if (c2702h != null) {
            c2703i.getClass();
            path = c2702h.f22920a;
        } else {
            path = null;
        }
        c2703i.f22924a.setPath(path, false);
        float length = ((C2703i) r02.getValue()).f22924a.getLength();
        float f7 = this.f25172k;
        float f8 = this.f25173m;
        float f9 = ((f7 + f8) % 1.0f) * length;
        float f10 = ((this.l + f8) % 1.0f) * length;
        if (f9 <= f10) {
            ((C2703i) r02.getValue()).a(f9, f10, this.f25179s);
            return;
        }
        C2702h c2702hA = this.f25180t;
        if (c2702hA == null) {
            c2702hA = AbstractC2704j.a();
            this.f25180t = c2702hA;
        }
        c2702hA.h();
        ((C2703i) r02.getValue()).a(f9, length, c2702hA);
        this.f25179s.d(c2702hA, 0L);
        c2702hA.h();
        ((C2703i) r02.getValue()).a(0.0f, f10, c2702hA);
        this.f25179s.d(c2702hA, 0L);
    }

    public final String toString() {
        return this.f25178r.toString();
    }
}
