import type { Frame, Page } from 'playwright'; import type { CamSpec, OccupantMeasure, Vec3 } from './vehicleMath'; import { type Overlay } from './evidenceOverlay'; import { type GripWindow } from './vehicleGrip'; interface PanelLike { id: string; signal: string; role: string; nodes: string[]; } type Shot = (id: string, label: string, group: string, settleMs?: number) => Promise; type SetCam = (c: CamSpec) => Promise; export interface CaptureOccupantsArgs { page: Page; frame: Frame; itemId: string; panels: PanelLike[]; seatsDeclared: { driver: string | null; seats: string[]; }; seatEvidence: Array<{ id: string; role: string; }>; carBounds: { min: Vec3; max: Vec3; } | null; outDir: string; shot: Shot; setCam: SetCam; clearCam: () => Promise; /** Take an in-bundle evidence frame (id, caption, group); returns whatever the caller needs to keep or drop it. */ evidence?: (id: string, label: string, group: string, overlay?: Overlay) => Promise; /** Evidence frame id prefix: `evidence.` for the default rendition, `evidence..` for another. */ evidencePrefix?: string; } export interface CaptureOccupantsResult { measures: OccupantMeasure[]; failed: Array<{ seatKey: string; why: string; }>; facts: Record; /** Cutaway evidence frames taken (the caller keeps the worst few of the whole car). */ evidence: Array<{ id: string; score: number; shot: unknown; }>; /** Held windows of the hands and fingers (every occupant at rest; the driver also with the wheel at centre and each lock). */ grip: GripWindow[]; /** Seats an occupant was measured in (judgeGrip needs to know every seat that should have a window). */ seated: Array<{ seatKey: string; role: string; }>; /** `[vehicle-seat]` console lines the seat rig logged while each seat was occupied (its describe().warnings). */ rigWarnings: Array<{ seatKey: string; text: string; }>; } export declare function captureOccupants(a: CaptureOccupantsArgs): Promise; export {};