public final class

ImageHelper

extends Object
java.lang.Object
   ↳ com.vidinoti.android.vdarsdk.arcore.helpers.ImageHelper

Class Overview

Helper class for converting images.

Summary

Public Methods
static byte[] imageYuv420888toJpeg(Image image, int rotation, double ratio)
Converts the given image to JPG format.
[Expand]
Inherited Methods
From class java.lang.Object

Public Methods

public static byte[] imageYuv420888toJpeg (Image image, int rotation, double ratio)

Converts the given image to JPG format.

Parameters
image the input image with format YUV_420_888
rotation the angle in degree if the image needs to be rotated
ratio the output ratio of the output image. The output image may be cropped to match the given ratio.
Returns
  • the bytes corresponding to the JPG image
Throws
UnsupportedImageFormatException if the input image is not in format YUV_420_888