Bytes Per Pixel value for byte representation of image in Android
问题 I'm currently writing an Android application which needs to use OCR within it. To achieve this I am using Tesseract in conjunction with the tesseract-android-tools project. I have managed to get the Tesseract API to initialize and need to use the following setImage function: void com.googlecode.tesseract.android.TessBaseAPI.setImage(byte[] imagedata, int width, int height, int bpp, int bpl) What I am struggling with is how to get the correct values for bpp (bytes per pixel) and bpl (bytes per