Skip to main content
Version: 0.11.x

Function: scaleBox()

scaleBox<F>(box, options): BoundingBox<F>

Defined in: extensions/cv/ops/box.ts:82

Scales bounding box coordinates based on scaling options and resize modes.

Type Parameters​

F​

F extends "xyxy" | "xywh" | "cxcywh"

Bounding box coordinate format.

Parameters​

box​

BoundingBox<F>

The original BoundingBox.

options​

ScaleBoxOptions

Options defining dimensions and resize modes. See ScaleBoxOptions.

Returns​

BoundingBox<F>

The scaled BoundingBox object.