package j3; import android.content.Context; import android.graphics.Color; import m3.b; /* loaded from: classes2.dex */ public class a { /* renamed from: a, reason: collision with root package name */ private final boolean f11037a; /* renamed from: b, reason: collision with root package name */ private final int f11038b; /* renamed from: c, reason: collision with root package name */ private final int f11039c; /* renamed from: d, reason: collision with root package name */ private final float f11040d; public a(Context context) { this.f11037a = b.b(context, c3.a.f3457m, false); this.f11038b = g3.a.a(context, c3.a.f3456l, 0); this.f11039c = g3.a.a(context, c3.a.f3454j, 0); this.f11040d = context.getResources().getDisplayMetrics().density; } private boolean e(int i10) { return q.a.f(i10, 255) == this.f11039c; } public float a(float f10) { if (this.f11040d <= 0.0f || f10 <= 0.0f) { return 0.0f; } return Math.min(((((float) Math.log1p(f10 / r0)) * 4.5f) + 2.0f) / 100.0f, 1.0f); } public int b(int i10, float f10) { float a10 = a(f10); return q.a.f(g3.a.f(q.a.f(i10, 255), this.f11038b, a10), Color.alpha(i10)); } public int c(int i10, float f10) { return (this.f11037a && e(i10)) ? b(i10, f10) : i10; } public boolean d() { return this.f11037a; } }