102 lines
3.1 KiB
Java
102 lines
3.1 KiB
Java
package c.f.j.h;
|
|
|
|
import android.graphics.Bitmap;
|
|
import c.f.j.d.b;
|
|
import c.f.j.j.c;
|
|
import c.f.j.j.e;
|
|
import c.f.j.j.h;
|
|
import c.f.j.j.i;
|
|
import c.f.j.n.d;
|
|
import com.facebook.common.references.CloseableReference;
|
|
import com.facebook.imagepipeline.decoder.DecodeException;
|
|
import java.util.Objects;
|
|
/* compiled from: DefaultImageDecoder */
|
|
public class a implements b {
|
|
public final b a;
|
|
public final b b;
|
|
|
|
/* renamed from: c reason: collision with root package name */
|
|
public final d f460c;
|
|
public final b d = new C0065a();
|
|
|
|
/* compiled from: DefaultImageDecoder */
|
|
/* renamed from: c.f.j.h.a$a reason: collision with other inner class name */
|
|
public class C0065a implements b {
|
|
public C0065a() {
|
|
}
|
|
|
|
@Override // c.f.j.h.b
|
|
public c a(e eVar, int i, i iVar, b bVar) {
|
|
eVar.w();
|
|
c.f.i.c cVar = eVar.k;
|
|
if (cVar == c.f.i.b.a) {
|
|
a aVar = a.this;
|
|
CloseableReference<Bitmap> b = aVar.f460c.b(eVar, bVar.d, null, i, null);
|
|
try {
|
|
aVar.c(null, b);
|
|
eVar.w();
|
|
int i2 = eVar.l;
|
|
eVar.w();
|
|
return new c.f.j.j.d(b, iVar, i2, eVar.m);
|
|
} finally {
|
|
b.close();
|
|
}
|
|
} else if (cVar == c.f.i.b.f424c) {
|
|
a aVar2 = a.this;
|
|
Objects.requireNonNull(aVar2);
|
|
eVar.w();
|
|
if (eVar.n != -1) {
|
|
eVar.w();
|
|
if (eVar.o != -1) {
|
|
Objects.requireNonNull(bVar);
|
|
b bVar2 = aVar2.a;
|
|
return bVar2 != null ? bVar2.a(eVar, i, iVar, bVar) : aVar2.b(eVar, bVar);
|
|
}
|
|
}
|
|
throw new DecodeException("image width or height is incorrect", eVar);
|
|
} else if (cVar == c.f.i.b.j) {
|
|
return a.this.b.a(eVar, i, iVar, bVar);
|
|
} else {
|
|
if (cVar != c.f.i.c.a) {
|
|
return a.this.b(eVar, bVar);
|
|
}
|
|
throw new DecodeException("unknown image format", eVar);
|
|
}
|
|
}
|
|
}
|
|
|
|
public a(b bVar, b bVar2, d dVar) {
|
|
this.a = bVar;
|
|
this.b = bVar2;
|
|
this.f460c = dVar;
|
|
}
|
|
|
|
@Override // c.f.j.h.b
|
|
public c a(e eVar, int i, i iVar, b bVar) {
|
|
Objects.requireNonNull(bVar);
|
|
eVar.w();
|
|
c.f.i.c cVar = eVar.k;
|
|
if (cVar == null || cVar == c.f.i.c.a) {
|
|
eVar.k = c.f.i.d.b(eVar.e());
|
|
}
|
|
return this.d.a(eVar, i, iVar, bVar);
|
|
}
|
|
|
|
public c.f.j.j.d b(e eVar, b bVar) {
|
|
CloseableReference<Bitmap> a = this.f460c.a(eVar, bVar.d, null, null);
|
|
try {
|
|
c(null, a);
|
|
i iVar = h.a;
|
|
eVar.w();
|
|
int i = eVar.l;
|
|
eVar.w();
|
|
return new c.f.j.j.d(a, iVar, i, eVar.m);
|
|
} finally {
|
|
a.close();
|
|
}
|
|
}
|
|
|
|
public final void c(c.f.j.t.a aVar, CloseableReference<Bitmap> closeableReference) {
|
|
}
|
|
}
|