package com.unity3d.player;

import android.graphics.ImageFormat;
import android.hardware.Camera;

/* loaded from: /storage/emulated/0/Documents/jadec/sources/com.UBI.A90.WW/dex-files/2.dex */
public final class g {
    public static int a(int i) {
        return ImageFormat.getBitsPerPixel(17);
    }

    public static void a(Camera camera) {
        camera.setPreviewCallbackWithBuffer(null);
    }

    public static void a(Camera camera, Camera.Size size, int i, Camera.PreviewCallback previewCallback) {
        int i2 = (((size.width * size.height) * i) / 8) + 4096;
        camera.addCallbackBuffer(new byte[i2]);
        camera.addCallbackBuffer(new byte[i2]);
        camera.setPreviewCallbackWithBuffer(previewCallback);
    }

    public static void a(Camera camera, byte[] bArr) {
        camera.addCallbackBuffer(bArr);
    }
}
