Skip to content

audioLevel / mic monitoring not available during previewOnly (lobby) mode #225

Description

@czoli1976

Context

The previewOnly prop on OTPublisher (feature request #222) renders the local camera before publishing, enabling a waiting-room / lobby experience. A common lobby need is a mic level indicator — showing the user their microphone works before they join.

Limitation

The native Android and iOS Vonage Video SDKs only begin audio capture when the publisher is published. In previewOnly mode the publisher is intentionally not published, so audioLevel events are never emitted — the React Native wrapper has no audio level to forward during preview.

Repro: mount <OTPublisher previewOnly /> with an audioLevel handler → no audioLevel events fire until previewOnly is set to false (the publisher publishes).

Why this isn't solved in the wrapper

Working around it at the RN layer would mean opening an independent microphone capture (an AVAudioEngine tap on iOS / AudioRecord on Android) alongside the SDK. That double-opens the mic, fights the SDK's own capture lifecycle, and risks audio-route/echo issues — so it shouldn't be done in the wrapper.

Suggested direction

  • Short term (done): documented in the previewOnly README — audioLevel is unavailable during preview.
  • Proper fix: the native Video SDKs need to expose a preview-time audio level (or a standalone mic-level API) that the RN wrapper can forward while previewOnly is active. This should be raised with the native Android/iOS SDK team.

Tracking this alongside the previewOnly feature (#222).

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions