what-the-bank/sources/o/C0789Opb.java

70 lines
2.0 KiB
Java
Raw Normal View History

2024-07-27 18:17:47 +07:00
package o;
import com.google.android.gms.maps.model.BitmapDescriptorFactory;
import com.google.zxing.NotFoundException;
/* renamed from: o.Opb, reason: case insensitive filesystem */
/* loaded from: classes2.dex */
public final class C0789Opb {
public final RHW c;
public final C8902dZc d;
public C0789Opb(C8902dZc c8902dZc) throws NotFoundException {
this.d = c8902dZc;
this.c = new RHW(c8902dZc);
}
public final boolean b(qCz qcz) {
return qcz.a >= BitmapDescriptorFactory.HUE_RED && qcz.a <= ((float) (this.d.e - 1)) && qcz.e > BitmapDescriptorFactory.HUE_RED && qcz.e <= ((float) (this.d.c - 1));
}
public static qCz d(qCz qcz, float f, float f2) {
float f3 = qcz.a;
float f4 = qcz.e;
return new qCz(f3 < f ? f3 - 1.0f : f3 + 1.0f, f4 < f2 ? f4 - 1.0f : f4 + 1.0f);
}
public static qCz e(qCz qcz, qCz qcz2, int i) {
float f = i + 1;
return new qCz(qcz.a + ((qcz2.a - qcz.a) / f), qcz.e + ((qcz2.e - qcz.e) / f));
}
public final int e(qCz qcz, qCz qcz2) {
int i = (int) qcz.a;
int i2 = (int) qcz.e;
int i3 = (int) qcz2.a;
int min = Math.min(this.d.c - 1, (int) qcz2.e);
int i4 = 0;
boolean z = Math.abs(min - i2) > Math.abs(i3 - i);
if (z) {
i = i2;
i2 = i;
i3 = min;
min = i3;
}
int abs = Math.abs(i3 - i);
int abs2 = Math.abs(min - i2);
int i5 = (-abs) / 2;
int i6 = i2 < min ? 1 : -1;
int i7 = i >= i3 ? -1 : 1;
boolean b = this.d.b(z ? i2 : i, z ? i : i2);
while (i != i3) {
boolean b2 = this.d.b(z ? i2 : i, z ? i : i2);
if (b2 != b) {
i4++;
b = b2;
}
i5 += abs2;
if (i5 > 0) {
if (i2 == min) {
break;
}
i2 += i6;
i5 -= abs;
}
i += i7;
}
return i4;
}
}