/** * @rajeev02/camera — Capture Module * Full camera abstraction: photo, video, HDR, panorama, timer, burst, night mode */ export type CameraFacing = "front" | "back"; export type FlashMode = "off" | "on" | "auto" | "torch"; export type CaptureMode = "photo" | "video" | "portrait" | "panorama" | "night" | "burst" | "timelapse" | "slow_motion" | "document"; export type AspectRatio = "1:1" | "4:3" | "16:9" | "3:2" | "full"; export type GridType = "none" | "rule_of_thirds" | "golden_ratio" | "square" | "crosshair"; export interface CameraConfig { facing: CameraFacing; flash: FlashMode; mode: CaptureMode; aspectRatio: AspectRatio; grid: GridType; /** Enable HDR (High Dynamic Range) */ hdr: boolean; /** Enable image stabilization */ stabilization: boolean; /** Timer delay in seconds (0 = no timer) */ timerSeconds: number; /** Zoom level (1.0 = no zoom) */ zoom: number; /** Max zoom level */ maxZoom: number; /** Photo quality (0-100) */ photoQuality: number; /** Video resolution */ videoResolution: VideoResolution; /** Video frame rate */ videoFps: number; /** Enable location tagging */ geoTag: boolean; /** Enable sound on capture */ shutterSound: boolean; /** Enable beauty/face enhancement mode */ beautyMode: boolean; /** Beauty mode intensity (0-100) */ beautyIntensity: number; /** Watermark text (e.g., timestamp, custom text) */ watermark?: string; /** Mirror front camera preview */ mirrorFrontCamera: boolean; } export type VideoResolution = "480p" | "720p" | "1080p" | "2K" | "4K"; export interface CapturedMedia { id: string; uri: string; type: "photo" | "video"; width: number; height: number; /** File size in bytes */ sizeBytes: number; /** MIME type */ mimeType: string; /** Duration in ms (video only) */ durationMs?: number; /** Thumbnail URI (video) */ thumbnailUri?: string; /** EXIF metadata */ exif?: ExifData; /** Timestamp */ capturedAt: number; } export interface ExifData { make?: string; model?: string; dateTime?: string; gpsLatitude?: number; gpsLongitude?: number; focalLength?: number; exposureTime?: string; iso?: number; aperture?: number; flash?: boolean; orientation?: number; } export interface FocusPoint { x: number; y: number; autoExposure: boolean; } export interface CameraCapabilities { hasFlash: boolean; hasFrontCamera: boolean; hasBackCamera: boolean; maxZoom: number; supportedModes: CaptureMode[]; supportedResolutions: VideoResolution[]; supportedFps: number[]; supportsHdr: boolean; supportsNightMode: boolean; supportsPortrait: boolean; supportsPanorama: boolean; supportsSlowMotion: boolean; supportsTimelapse: boolean; supportsBeautyMode: boolean; supportsOpticalZoom: boolean; supportedAspectRatios: AspectRatio[]; } /** * Camera Controller — manages camera state, capture, and settings */ export declare class CameraController { private config; private isRecording; private recordingStartTime; private capturedMedia; private listeners; constructor(config?: Partial); /** Switch between front and back camera */ flipCamera(): void; /** Set capture mode */ setMode(mode: CaptureMode): void; /** Set flash mode */ setFlash(mode: FlashMode): void; /** Cycle flash mode: off → on → auto */ cycleFlash(): FlashMode; /** Set zoom level */ setZoom(zoom: number): void; /** Set focus point (tap to focus) */ setFocusPoint(point: FocusPoint): void; /** Set aspect ratio */ setAspectRatio(ratio: AspectRatio): void; /** Set grid overlay */ setGrid(grid: GridType): void; /** Toggle HDR */ toggleHdr(): boolean; /** Toggle beauty mode */ toggleBeautyMode(): boolean; /** Set beauty intensity */ setBeautyIntensity(intensity: number): void; /** Set timer delay */ setTimer(seconds: number): void; /** Cycle timer: 0 → 3 → 5 → 10 → 0 */ cycleTimer(): number; /** Capture a photo (returns mock; native layer does actual capture) */ capturePhoto(): string; /** Start video recording */ startRecording(): void; /** Stop video recording */ stopRecording(): void; /** Called by native layer when media is captured */ onMediaCaptured(media: CapturedMedia): void; /** Get recording state */ getIsRecording(): boolean; /** Get recording duration */ getRecordingDurationMs(): number; /** Get current config */ getConfig(): CameraConfig; /** Get captured media gallery */ getCapturedMedia(): CapturedMedia[]; /** Subscribe to camera events */ on(listener: (event: CameraEvent) => void): () => void; /** Get default capabilities (native layer overrides) */ static getDefaultCapabilities(): CameraCapabilities; private emit; } export type CameraEvent = { type: "camera_flipped"; facing: CameraFacing; } | { type: "mode_changed"; mode: CaptureMode; } | { type: "focus_set"; point: FocusPoint; } | { type: "capture_started"; mediaType: "photo" | "video"; } | { type: "recording_started"; } | { type: "recording_stopped"; durationMs: number; } | { type: "media_captured"; media: CapturedMedia; }; //# sourceMappingURL=index.d.ts.map