Skip to content

@burnmark-io/designer-core


@burnmark-io/designer-core / toBitmap

Function: toBitmap()

toBitmap(rgba, options?): LabelBitmap

Defined in: packages/core/src/render/pipeline.ts:50

Convert RawImageData (RGBA) to a 1bpp LabelBitmap via @mbtech-nl/bitmap. Uses Floyd–Steinberg dithering by default; threshold defaults to 128.

Parameters

rgba

RawImageData

options?

dither?

boolean

invert?

boolean

threshold?

number

Returns

LabelBitmap

Not affiliated with Dymo, Brother, Avery, or any hardware vendor.