chafa-wasm / ChafaModule
An object that contains the Chafa WebAssembly module API.
[x
: string
| number
| symbol
]: any
decodeImage: (
image
,callback
) =>void
Decodes a PNG, JPEG or WebP image into an ImageDataLike object. If an already decoded image is specified, it will be left as is.
ArrayBufferLike
| ImageDataLike
void
imageToAnsi: (
image
,config
,callback
) =>void
Converts an image into an ANSI string.
ArrayBufferLike
| ImageDataLike
Callback
<object
>
void
imageToCanvas: (
image
,config
,callback
) =>void
Converts an image into a Chafa canvas pointer.
ArrayBufferLike
| ImageDataLike
Callback
<object
>
void
imageToConsoleLogArgs: (
image
,config
,callback
) =>void
Converts an image into an array of console.log
arguments.
ArrayBufferLike
| ImageDataLike
Callback
<object
>
void
imageToHtml: (
image
,config
,callback
) =>void
Converts an image into an HTML string.
ArrayBufferLike
| ImageDataLike
Callback
<object
>
void
imageToMatrix: (
image
,config
,callback
) =>void
Converts an image into a matrix of characters.
ArrayBufferLike
| ImageDataLike
Callback
<object
>
void