Skip to main content

modules

@auvious/media-tools / Exports

@auvious/media-tools

Table of contents

Classes

Interfaces

Variables

Functions

Variables

MediaDevices

Const MediaDevices: Devices

Functions

canvasToBlob

canvasToBlob(canvas): Promise<Blob>

Parameters

NameType
canvasHTMLCanvasElement

Returns

Promise<Blob>


canvasToUrl

canvasToUrl(canvas): string

Parameters

NameType
canvasHTMLCanvasElement

Returns

string


captureBlobImage

captureBlobImage(videoElement): Promise<Blob>

Parameters

NameType
videoElementHTMLVideoElement

Returns

Promise<Blob>


captureURLImage

captureURLImage(videoElement, options?): string

Parameters

NameType
videoElementHTMLVideoElement
optionsObject
options.mirrorboolean

Returns

string


merge

merge(a, b): HTMLCanvasElement

Parameters

NameType
aHTMLImageElement | HTMLVideoElement | HTMLCanvasElement | ImageBitmap
bHTMLImageElement | HTMLVideoElement | HTMLCanvasElement | ImageBitmap

Returns

HTMLCanvasElement


mirror

mirror(canvas): HTMLCanvasElement

reverse canvas on y axis, without clearing

Parameters

NameType
canvasHTMLCanvasElement

Returns

HTMLCanvasElement


useCanvas

useCanvas(source): HTMLCanvasElement

Parameters

NameType
sourceCanvasImageSource

Returns

HTMLCanvasElement