package defpackage;

/* renamed from: ˎᵫˋ, reason: contains not printable characters */
/* loaded from: classes3.dex */
public final class C1771 {

    /* renamed from: ˇʼʤˎ, reason: contains not printable characters */
    public int f7149;

    /* renamed from: ˎˏʜʾ, reason: contains not printable characters */
    public int f7150;

    /* renamed from: ˏˋٴ, reason: contains not printable characters */
    public int f7151;

    /* renamed from: ˏᵙ, reason: contains not printable characters */
    public int f7152;

    /* renamed from: ᵥᵯˎ, reason: contains not printable characters */
    public final byte[] f7153 = new byte[10];

    /* renamed from: ᵴᵳ, reason: contains not printable characters */
    public boolean f7154;

    /* renamed from: ᵻᵢﹳᵰ, reason: contains not printable characters */
    public long f7155;

    /* renamed from: ˏᵙ, reason: contains not printable characters */
    public final void m5047(InterfaceC1383 interfaceC1383) {
        if (this.f7154) {
            return;
        }
        byte[] bArr = this.f7153;
        interfaceC1383.mo4249(bArr, 0, 10);
        interfaceC1383.mo4245();
        if (bArr[4] == -8 && bArr[5] == 114 && bArr[6] == 111) {
            byte b = bArr[7];
            if ((b & 254) == 186) {
                i = 40 << ((bArr[((b & 255) == 187 ? 1 : 0) != 0 ? '\t' : '\b'] >> 4) & 7);
            }
        }
        if (i == 0) {
            return;
        }
        this.f7154 = true;
    }

    /* renamed from: ᵥᵯˎ, reason: contains not printable characters */
    public final void m5048(InterfaceC2154 interfaceC2154, C5346 c5346) {
        if (this.f7152 > 0) {
            interfaceC2154.mo4410(this.f7155, this.f7149, this.f7151, this.f7150, c5346);
            this.f7152 = 0;
        }
    }

    /* renamed from: ᵴᵳ, reason: contains not printable characters */
    public final void m5049(InterfaceC2154 interfaceC2154, long j, int i, int i2, int i3, C5346 c5346) {
        ᵛᵾˏ.ᵢˇᵭ("TrueHD chunk samples must be contiguous in the sample queue.", this.f7150 <= i2 + i3);
        if (this.f7154) {
            int i4 = this.f7152;
            int i5 = i4 + 1;
            this.f7152 = i5;
            if (i4 == 0) {
                this.f7155 = j;
                this.f7149 = i;
                this.f7151 = 0;
            }
            this.f7151 += i2;
            this.f7150 = i3;
            if (i5 >= 16) {
                m5048(interfaceC2154, c5346);
            }
        }
    }
}
