FrameFlutterBridge

Bridge interface implemented by the HOST APP, backed by its embedded Flutter module.

Why this exists:

  • This SDK wants to support Frame via Flutter without forcing a Flutter dependency on all consumers.

  • So this module defines the contract; the app wires it to MethodChannel/EventChannel.

Properties

Link copied to clipboard
abstract val events: Flow<GlassesEvent>

Bridge-side events from Flutter (logs/tap/etc.).

Link copied to clipboard
abstract val microphone: Flow<AudioChunk>

Raw microphone audio chunks pushed from the embedded Flutter module.

Link copied to clipboard
abstract val state: StateFlow<FrameFlutterState>

Bridge-side connection state (mirrors the Flutter module state).

Functions

Link copied to clipboard
abstract suspend fun capturePhoto(options: CaptureOptions): Result<CapturedImage>
Link copied to clipboard
abstract suspend fun connect(): Result<Unit>
Link copied to clipboard
abstract suspend fun disconnect()
Link copied to clipboard
abstract suspend fun displayText(text: String, options: DisplayOptions): Result<Unit>
Link copied to clipboard
abstract suspend fun startMicrophone(options: MicrophoneOptions): Result<AudioFormat>
Link copied to clipboard
abstract suspend fun stopMicrophone(): Result<Unit>