Audio

class foxglove.layouts.AudioPanel

Play audio streams.

For more information, see the documentation.

Example
import foxglove.layouts as fl

layout = fl.Layout(
    content=fl.AudioPanel(
        config=fl.AudioConfig(
            topic="/audio",
            color="#ff0000",
        ),
    ),
)
config: AudioConfig
title: str | None = None

The title of the panel.

class foxglove.layouts.AudioConfig

Configuration for the Audio panel.

color: str | None = None

Color of the audio waveform visualization

muted: bool | None = None

Mute audio playback

sliding_view_width: float | None = None

Time range in seconds for the sliding window (live sources only)

time_stretching: Optional[Literal['wsola', 'resample']] = None

How audio is played at playback speeds other than 1x. “wsola” time-stretches audio with waveform similarity overlap-add (WSOLA), which keeps its original pitch. “resample” resamples audio, so its pitch changes with speed. If unset, audio keeps its original pitch using the default algorithm, currently “wsola”.

topic: str | None = None

Topic containing audio messages

volume: float | None = None

Audio playback volume