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

19 lines
600 B
Java
Raw Permalink Normal View History

2024-07-27 18:17:47 +07:00
package o;
import android.graphics.Bitmap;
import java.io.ByteArrayOutputStream;
import java.io.IOException;
/* loaded from: classes5.dex */
public final class fQO {
public static byte[] a(Bitmap bitmap, Bitmap.CompressFormat compressFormat, Integer num) throws IOException {
ByteArrayOutputStream byteArrayOutputStream = new ByteArrayOutputStream();
try {
bitmap.compress(compressFormat, num.intValue(), byteArrayOutputStream);
return byteArrayOutputStream.toByteArray();
} finally {
byteArrayOutputStream.close();
}
}
}