import type { Five } from '@realsee/five'; import type { CameraState } from '../typings'; /** * FiveModelCameraBridge —— CameraState ↔ five **Mapview**(地图态 / orbit)参数的唯一收敛点。 * * 统一运镜采用 Mapview orbit 位姿:相机绕 `target` 旋转, * 相机位置 = target − coordinatesToVector(longitude, latitude) × distance,视线恒指向 `target`。 * 因此「播放逐帧接管」与「暂停交还用户拖拽」处于同一参数系: * 暂停瞬间 five 已是合法 Mapview 状态(offset=target、distance>0),用户可直接左键 orbit / 右键平移, * 无需任何 look-from→orbit 转换、无跳变。 * * apply:target→offset、longitude/latitude/distance 直传、fov 钳制、mode='Mapview'。 * capture:从 five 当前 Mapview 位姿反读一个 CameraState。 * * 注:类名沿用历史 `FiveModelCameraBridge`(避免大范围改名);实际目标模态为 Mapview。 */ export declare class FiveModelCameraBridge { private five; constructor(five: Five); /** * 将 CameraState 应用到 five(mode:'Mapview')。对 `five.setState` 恰好一次。 * - fov 钳制到开区间 (0,180)(含 fov<=0 与 NaN),不拒绝、不抛错。 * @param immediately five.setState 第二参数。true(缺省)= 立即贴合目标(逐帧驱动/seek 用);false = 走 five 内插动画。 */ apply(state: CameraState, immediately?: boolean): void; /** * 加法式:以「走 five 内插动画」的方式应用 CameraState(`apply` 的 immediately=false 分支), * 返回一个在过渡完成后 resolve 的 Promise。 * - 映射规则与 `apply` 完全一致,对 `five.setState` 恰好一次,仅第二参数取 false(动画)。 * - 完成信号:`five.setState` 返回 void、无可等待对象,故以一次过渡时长(CAMERA_TRANSITION_MS)兜底后 resolve。 */ applyAnimated(state: CameraState): Promise; /** * 从 five 当前 Mapview 位姿反读一个 CameraState。 * five.getCurrentState() 返回 { offset, longitude, latitude, distance, fov }(来自相机 pose), * 其中 offset 即 orbit 目标点(target)。 */ capture(): CameraState; }