Methods

(async, inner) toContext(img)

Parameters:
NameTypeDescription
imgImage | Imageable

img: image, canvas, context2d, url, data url

Returns:

A Canvas.context object

(inner) toUint8Array(msg)

Parameters:
NameTypeDescription
msg*

A string, charCode (number), Uint8Array or Uint8ClampedArray

Returns:

A Uint8Array or Uint8ClampedArray

(inner) charToBits(char)

Parameters:
NameTypeDescription
char

An 8 bit char

Returns:

Array of 3 parts of char using the bits tempate (3, 2, 3 bits)