interface RemoveOptions {
    session?: BaseSession;
    onlyMask?: boolean;
    postProcessMask?: boolean;
    bgcolor?: [number, number, number, number];
    onProgress?: ((info) => void);
}

Properties

session?: BaseSession

Custom session to use (if not provided, will create a new u2net session)

onlyMask?: boolean

Return only the mask (black/white) instead of the cutout

postProcessMask?: boolean

Apply post-processing to smooth the mask

bgcolor?: [number, number, number, number]

Background color to apply (RGBA values 0-255)

onProgress?: ((info) => void)

Progress callback function

Type declaration