public class ImageBuilder
extends java.lang.Object
| Constructor and Description |
|---|
ImageBuilder() |
| Modifier and Type | Method and Description |
|---|---|
static Image |
buildImageFromCamera1NV21Frame(byte[] imageBuffer,
int imageWidth,
int imageHeight,
Orientation imageOrientation,
Rectangle scanningRegion) |
static Image |
buildImageFromCamera2Image(android.media.Image image,
Orientation imageOrientation,
Rectangle scanningRegion)
Builds image object from Camera2 frame in YUV_420_888 format.
|
static Image |
buildImageFromNativeContext(long nativeContext)
Builds image object from native context.
|
public static Image buildImageFromNativeContext(long nativeContext)
nativeContext - Native pointer containing native image object.Image object for usage via DirectAPI's Recognizer object.public static Image buildImageFromCamera2Image(@NonNull android.media.Image image, @NonNull Orientation imageOrientation, @Nullable Rectangle scanningRegion)
image - Image object that contains image from which MicroBlink Image will be built. You must ensure that this object is not closed
while returned Image is in use. Doing so will lead to undefined behaviour.imageOrientation - Orientation of the device at the time Image was created. Cannot be null nor Orientation.ORIENTATION_UNKNOWN.scanningRegion - Region of image that will be used for recognition. If null, entire image will be used.Image object for usage via DirectAPI's Recognizer object.public static Image buildImageFromCamera1NV21Frame(@NonNull byte[] imageBuffer, int imageWidth, int imageHeight, @NonNull Orientation imageOrientation, @Nullable Rectangle scanningRegion)