import { GpuShaderDefinition } from '../../gpu/porters'; import { transformColor } from '../../utilities/transformations'; /** * ObjectTracker — a computer-vision "object detection" overlay. Each pixel walks a spatial * partition of the canvas to the leaf cell it belongs to, scans that leaf for content (coverage * + a content-tight bounding box), and — if the leaf holds an object — composites a bounding box * + an optional label over the source. The whole fragment is the std detectionOverlay recipe: * analysis core (partition walk + content bbox) → detection box → glyph-pill label, over the * kit's detection parts and the shared overlay vocabulary. */ export interface ComponentProps { /** * What counts as a detectable object. * * Accepts one of: `"alpha"`, `"bright"`, `"dark"`, `"red"`, `"green"`, `"blue"`. * @default "bright" */ detectionMode: string; /** * Detection cut-off. * * Accepts a number between 0 and 1. * @default 0.25 */ threshold: number; /** * How the canvas is partitioned into detection cells. * * Accepts one of: `"grid"`, `"quadtree"`, `"mosaic"`. * @default "mosaic" */ layout: string; /** * Base cell size in pixels * * Accepts a number between 24 and 800. * @default 400 */ cellSize: number; /** * Maximum subdivision levels for Quadtree/Mosaic layouts (each level can quarter a cell). * * Accepts a number between 1 and 5. * @default 2 */ maxDepth: number; /** * Bounding box outline style * * Accepts one of: `"full"`, `"corners"`. * @default "corners" */ boxStyle: string; /** * Thickness of the box outline in pixels. * * Accepts a number between 0.5 and 12. * @default 1.5 */ lineWidth: number; /** * Corner radius of the box outline in pixels * * Accepts a number between 0 and 40. * @default 0 */ cornerRadius: number; /** * Bounding box outline colour. * * Accepts hex strings (`#ff0000`), RGB objects (`{ r, g, b }`), or CSS color names (`limegreen`). * @default "#ffffff" */ strokeColor: Parameters[0]; /** * Bounding box fill color. * * Accepts hex strings (`#ff0000`), RGB objects (`{ r, g, b }`), or CSS color names (`limegreen`). * @default "#5a79911a" */ fillColor: Parameters[0]; /** * Label text color. * * Accepts hex strings (`#ff0000`), RGB objects (`{ r, g, b }`), or CSS color names (`limegreen`). * @default "#000000" */ labelColor: Parameters[0]; /** * Label pill background color. * * Accepts hex strings (`#ff0000`), RGB objects (`{ r, g, b }`), or CSS color names (`limegreen`). * @default "#ffffff" */ labelBackgroundColor: Parameters[0]; /** * What each label shows. * * Accepts one of: `"none"`, `"dimensions"`, `"percentage"`. * @default "none" */ labelMode: string; /** * Which corner of the box the label anchors to. * * Accepts one of: `"bottom-left"`, `"bottom-right"`, `"top-left"`, `"top-right"`. * @default "bottom-right" */ labelPosition: string; /** * Place the label inside or outside the box. * * Accepts a boolean value (`true` or `false`). * @default true */ labelInset: boolean; /** * Corner radius of the label pill in pixels. * * Accepts a number between 0 and 30. * @default 0 */ labelRadius: number; /** * Google Fonts family used for label text. * * @default "Inter" */ fontFamily: string; /** * Font weight for label text. * * @default 500 */ fontWeight: number; /** * Label text size as a fraction of canvas height. * * Accepts a number between 0.01 and 0.5. * @default 0.015 */ fontSize: number; /** * Letter spacing for label text, in em units. * * Accepts a number between -0.1 and 0.5. * @default 0 */ letterSpacing: number; } export declare const componentDefinition: GpuShaderDefinition; export default componentDefinition; //# sourceMappingURL=index.d.ts.map