Skip to main content
Version: 0.2.4

Module: ImageModule

Interfaces

Variables

ImageUtil

Const ImageUtil: Object

The ImageUtil object provides functions to load an Image either from a URL or load an image that is bundled with the React Native app bundle. The returned Image object can the then be used to run model inference or it can be drawn on a canvas.

Type declaration

NameType
fromBundle(imagePath: number) => Promise<Image>
fromFile(path: string) => Promise<Image>
fromImageData(imageData: ImageData) => Promise<Image>
fromJSRef(imageRef: NativeJSRef) => Image
fromURL(url: string) => Promise<Image>
release(image: Image) => Promise<void>
toFile(image: Image) => Promise<string>

Functions

wrapRef

Const wrapRef(ref): Image

Parameters

NameType
refNativeJSRef

Returns

Image