Skip to main content

Crate sew_call_client

Crate sew_call_client 

Source
Expand description

sew-call-client: Sew’s native voice engine. Everything below the UI for one call:

  • LiveKit-protocol signalling against Sew’s media server (the /rtc/v1 single-PC session from sew-lk-compat) with resume, full reconnect inside a 20 s window and re-join through the host’s JoinProvider;
  • str0m transport with TURN over UDP, TCP and TLS, relay-only when the join answer or the engine asks (media.relay_only / force_relay), production TLS trust (the platform’s);
  • the frame path: kessel-audio’s encoded Opus frames are encrypted through the call’s keys (e2ee::KeySession) and sent; remote frames are decrypted and verified before kessel-audio ever sees them (no plaintext mode exists);
  • mute and deafen, participants, speaking levels, and the call credential’s renewal;
  • the call-stats beacon (Sew’s POST /api/v1/me/voice/stats, when the join answer carries its terms) and the same per-window numbers for the host (stats, Call::stats);
  • recording consent (Sew 0.7.3): a join into a recorded room is held at CallState::ConsentRequired until the host answers the notice (Call::consent); the call’s recording (Call::recording, CallEvent::Recording) feeds the keys, which release this device’s key to the recorder only once Sew says granted; Call::withdraw_consent is “Stop recording me”. Consent travels through the host’s JoinProvider with the person’s own session.

Sew is a self-hosted chat and calls server from Alakazam Labs; this crate is its native call client. It needs a Sew server to join calls on.

let client = CallClient::with_mls(ClientConfig::new("com.example.app", data_dir));
let call = client.join(provider, JoinRequest::new(target, room)).await?;
let audio = AudioBridge::start(&call, kessel_audio::EngineConfig::default())?; // feature `audio`
let mut events = call.events();

The host implements JoinProvider (its documentation says which crates that needs and has a complete example). The engine runs on Tokio: call CallClient::join from inside a Tokio runtime.

The E2EE layer plugs in through e2ee::E2eeProvider; CallClient cannot be built without one. The real one, and the default (CallClient::with_mls), is e2ee::MlsKeys: MLS through sew-e2ee, the call socket (gateway), the device store (device), the mandatory checks and sew-lk-compat’s LkGcm. The only other provider is the test-only StaticKeys (feature testing). CallClient says when to use with_mls and when CallClient::new.

Two labels in these docs: K2 is Alakazam Labs’ platform, which can host Sew (kessel-audio and kessel-video, the audio and video pipelines used here, are K2’s crates; nothing here needs K2). A Sew version (“Sew 0.7.3”) is a version of the Sew server: next to a feature, the first server version that has it; in the CHANGELOG’s headings, the server version that release of this crate is tested against.

The README has the cargo features and the platforms each one builds on.

Re-exports§

pub use stats::BeaconOutcome;
pub use stats::BeforeFirstWindow;
pub use stats::CallStatsReport;
pub use stats::PlayoutSource;
pub use stats::PlayoutStats;
pub use stats::PlayoutTotals;
pub use stats::StatsWindow;
pub use kessel_audio;
pub use kessel_video;
pub use rustls;

Modules§

device
The device store: the native equivalent of the browser’s IndexedDB sew-e2ee store.
e2ee
The E2EE interface: what the engine asks of the call’s keys, and what the keys tell the engine. This module fills it in (MLS through sew-e2ee, the call socket, key transport over the call credential, the device store, the mandatory defences). The engine itself never holds a key.
gateway
The call socket: one gateway connection opened with the call credential.
noise_probe
The probe of the noise removal stage (feature noise-probe; measurement builds only). The noise removal stage’s probe (feature noise-probe; for measurement builds only, never a release): a call whose stage records what each 10 ms block cost on the audio pipeline’s processing thread, which core the thread was on and what DeepFilterNet3 ran, beside two fixed loops on the same thread (sew_noise::probe). It answers how fast the OS runs that thread, apart from how much work the model is.
stats
The call-stats beacon: one aggregate, anonymous CallStatsSample per window to Sew’s POST /api/v1/me/voice/stats with the call credential, and the same per-window numbers for the host (crate::Call::stats, crate::CallEvent::Stats).

Structs§

AnswerError
Why a join answer could not be read.
AudioBridge
A running bridge between one call and a kessel-audio engine.
AudioSession
The phone’s audio session state, shared between the app’s reports and the call’s audio (one per app; clones share it). It keeps what the app said before a call’s audio started (CallKit may activate the session before the join has a call) and hands it to the next AudioBridge::start_with_session:
BackupSpec
Video publishing: the engine’s frame API (Call::publish_video) and its types. Video publishing: the engine’s frame API (Call::publish_video) and its types. Video publishing: the engine’s frame API (Call::publish_video) and its types. A publication’s backup codec (VideoPublish::with_backup): VP8 beside an H.264 primary, negotiated at publish and run only while some subscriber needs it.
BridgeLevels
kessel-audio’s latest levels (about every 50 ms) by engine identity (AudioBridge::levels).
Call
One live call.
CallClient
The engine of one app: at most one live call.
CallCounters
Counters of one call.
CallCredential
The call-scoped credential minted with the join answer (VoiceJoinResponse.call_credential, flag call_credential, Sew 0.7.1).
CallErrorEvent
An error for the host (errors event): {code, detail}.
CallLeaver
Leaves a call without its Call handle (Call::leaver). Cloneable; a leave of a call that is already over answers CallError::Ended.
CallMoved
Where a moderator move took the call (Sew’s voice_server_updated).
CallRecording
The call’s recording as Sew says it (recording event, Call::recording).
CallSecurity
The call’s end-to-end key state and its security code, as the keys report them (CallEvent::Security, CallSnapshot::security). Ids, an epoch and a code only: no key material.
CallSnapshot
A point-in-time view of a call (state command).
CameraFrame
Raw camera frames for a native self-view (video-core): VideoCapture::camera_tap. Raw camera frames for a native self-view (video-core): VideoCapture::camera_tap. Raw camera frames for a native self-view (video-core): VideoCapture::camera_tap. One raw camera frame for a native self-view.
CameraRequest
The video bridge: a kessel-video backend’s cameras, screens and encoders into a call, with the in-call self-view. The video bridge: a kessel-video backend’s cameras, screens and encoders into a call, with the in-call self-view. The video bridge: a kessel-video backend’s cameras, screens and encoders into a call, with the in-call self-view. What to do with the camera (VideoBridge::set_camera).
CameraSource
Video capture (video-core): cameras, screens, the OS picker, screen thumbnails and the pre-join preview over a kessel-video backend, as the sources the publish side takes. Video capture (video-core): cameras, screens, the OS picker, screen thumbnails and the pre-join preview over a kessel-video backend, as the sources the publish side takes. Video capture (video-core): cameras, screens, the OS picker, screen thumbnails and the pre-join preview over a kessel-video backend, as the sources the publish side takes. A running camera (VideoCapture::open_camera). Everything of Capture through Deref.
CameraTap
Raw camera frames for a native self-view (video-core): VideoCapture::camera_tap. Raw camera frames for a native self-view (video-core): VideoCapture::camera_tap. Raw camera frames for a native self-view (video-core): VideoCapture::camera_tap. The reading end of a camera tap (VideoCapture::camera_tap or CameraTap::channel): the feed, then the newest frame each time one is taken. Dropping it (or CameraTap::close) closes it; the camera side then forgets it.
CameraTapSender
Raw camera frames for a native self-view (video-core): VideoCapture::camera_tap. Raw camera frames for a native self-view (video-core): VideoCapture::camera_tap. Raw camera frames for a native self-view (video-core): VideoCapture::camera_tap. The feeding end of a CameraTap. Never blocks: a frame replaces one not yet taken.
Capture
Video capture (video-core): cameras, screens, the OS picker, screen thumbnails and the pre-join preview over a kessel-video backend, as the sources the publish side takes. Video capture (video-core): cameras, screens, the OS picker, screen thumbnails and the pre-join preview over a kessel-video backend, as the sources the publish side takes. Video capture (video-core): cameras, screens, the OS picker, screen thumbnails and the pre-join preview over a kessel-video backend, as the sources the publish side takes. A running camera or screen source. Dropping it stops the device.
CaptureDspSched
What the audio pipeline’s processing thread asks the OS for in the calls that start after it is set (NoiseRemovalControl::set_dsp_sched): the mode, the time-constraint policy’s figures and, for CaptureDspSchedMode::OwnWorkgroup, each block’s deadline. The pipeline reads it once, as a call’s audio starts; a change reaches the next call.
ClientConfig
The engine’s configuration (one per app).
CodecPlan
The video bridge: a kessel-video backend’s cameras, screens and encoders into a call, with the in-call self-view. The video bridge: a kessel-video backend’s cameras, screens and encoders into a call, with the in-call self-view. The video bridge: a kessel-video backend’s cameras, screens and encoders into a call, with the in-call self-view. What a native sender publishes in (choose_codecs).
ConsentAnswer
The person’s answer to a live recording’s notice, for the host to send with the person’s own Sew session: POST {path} with {body} (Sew’s POST /api/v1/recordings/{id}/consent), whose 200 is the recording as the person sees it (ConsentAnswer::recording_from_json). consent: false while granted is a withdrawal (“Stop recording me”); before that, a decline.
ConsentPrompt
Sew’s recording types the engine’s recording API carries (from sew-proto). The consent modal’s data. Every slot is data; templates supply the sentences. notice_version is a stable hash of every other slot; the answer must echo it.
ConsentRequired
Sew’s 409 recording_consent_required on a join (Sew 0.7.3): the room is recorded (or the channel records itself on its first join) and the join carried no answer to the current notice. Its error.details, unchanged.
Dfn3LoadInfo
What loading DeepFilterNet3’s weights cost, and how long the model stays after the last call by default (feature dfn3). What loading DeepFilterNet3’s weights cost, and how long the model stays after the last call by default (feature dfn3). What loading DeepFilterNet3’s weights cost, and how long the model stays after the last call by default (feature dfn3). What loading the DeepFilterNet3 weights cost (feature dfn3): resident memory before and after (KiB; None where this build can’t read it) and the time taken.
DmCall
The DM call of a DM call join’s answer (CallJoinResponse.call and created), kept by JoinAnswer::from_json.
EncodedVideo
Video publishing: the engine’s frame API (Call::publish_video) and its types. Video publishing: the engine’s frame API (Call::publish_video) and its types. Video publishing: the engine’s frame API (Call::publish_video) and its types. One encoded plaintext frame of one layer (the engine encrypts it).
FrameSender
The send queue of a call, cloneable (Call::frame_sender).
FrameStream
The receive side’s queue (one consumer).
JoinAnswer
Sew’s join answer as the host got it, and the door to Sew’s client API.
JoinRequest
What the host joins. Its JSON ({target, room, muted, deafened, rejoin}, plus recording_notice when there is one) is what a host’s provider may forward to its own server (tauri-plugin-sew-voice’s App server route).
LayerRate
Video publishing: the engine’s frame API (Call::publish_video) and its types. Video publishing: the engine’s frame API (Call::publish_video) and its types. Video publishing: the engine’s frame API (Call::publish_video) and its types. One layer’s run state (VideoControl::Rates).
LayerSpec
Video publishing: the engine’s frame API (Call::publish_video) and its types. Video publishing: the engine’s frame API (Call::publish_video) and its types. Video publishing: the engine’s frame API (Call::publish_video) and its types. One simulcast layer of a publication.
LocalFrame
Video capture (video-core): cameras, screens, the OS picker, screen thumbnails and the pre-join preview over a kessel-video backend, as the sources the publish side takes. Video capture (video-core): cameras, screens, the OS picker, screen thumbnails and the pre-join preview over a kessel-video backend, as the sources the publish side takes. Video capture (video-core): cameras, screens, the OS picker, screen thumbnails and the pre-join preview over a kessel-video backend, as the sources the publish side takes. One encoded plaintext frame of this device’s own camera or screen (self-view).
LocalVideo
Video publishing: the engine’s frame API (Call::publish_video) and its types. Video publishing: the engine’s frame API (Call::publish_video) and its types. Video publishing: the engine’s frame API (Call::publish_video) and its types. The local video’s state (CallEvent::LocalVideo).
NoiseRemovalControl
The noise removal setting of the capture path and what runs; with audio-core, the control that builds the capture stage (AudioBridge::start_with_noise). The noise removal setting of an app, and the handle on the stage of its live call’s audio. Clones share it; keep one per app (the setting outlives calls).
NoiseRemovalState
The noise removal setting and what runs: {mode, active, reason?, model?, model_reason?, step_downs?, phone_mode?, phone_mode_reason?, phone_mode_switches?, phone_mode_gap_ms?, step_down_reason?, last_step_down_ms_ago?, slowest_block_us?, blocks_over_budget?, in_grace?, dfn3_state?, retry_in_ms?, grace_step_downs?, slowest_block_cpu_us?, p99_block_us?, p99_block_cpu_us?, capture_stage_strikes?, capture_stage_bypassed?, capture_stage_p99_us?, capture_stage_grace?, capture_stage_grace_blocks?, capture_stage_grace_over_budget?, capture_stage_last_transient?, capture_stage_clock?, capture_stage_max_wall_us?, capture_stage_preempted_over_budget?, capture_stage_starved?, capture_stage_dsp_scheduling?}.
OpusFrame
One encoded 20 ms Opus frame to send (kessel-audio’s EncodedFrame).
Participant
One participant (participants event). Names are the host’s.
PlannedCodec
The video bridge: a kessel-video backend’s cameras, screens and encoders into a call, with the in-call self-view. The video bridge: a kessel-video backend’s cameras, screens and encoders into a call, with the in-call self-view. The video bridge: a kessel-video backend’s cameras, screens and encoders into a call, with the in-call self-view. One codec of a CodecPlan: the codec and the backend’s encoder entry for it.
Preview
Video capture (video-core): cameras, screens, the OS picker, screen thumbnails and the pre-join preview over a kessel-video backend, as the sources the publish side takes. Video capture (video-core): cameras, screens, the OS picker, screen thumbnails and the pre-join preview over a kessel-video backend, as the sources the publish side takes. Video capture (video-core): cameras, screens, the OS picker, screen thumbnails and the pre-join preview over a kessel-video backend, as the sources the publish side takes. A running preview. Dropping it (or Preview::stop) closes the camera at once.
Recording
Sew’s recording types the engine’s recording API carries (from sew-proto). A recording.
RecordingMember
One participant of the recording, as everyone in the call sees it.
RecordingNotice
Sew’s recording types the engine’s recording API carries (from sew-proto). The answer to the consent modal, sent with a voice join or call join/accept. Joining never implies consent: consent is required and notice_version must echo the current ConsentPrompt.
RecordingRequest
The person’s Record or Stop, for the host to send with the person’s own Sew session, as ConsentAnswer is: POST {path} with {body}, whose 200 is the recording as the person sees it (RecordingRequest::recording_from_json). Never the call credential: starting and stopping are the person’s acts, with Sew’s permission checks and audit.
RecvOpus
One decrypted, verified remote frame (kessel-audio’s RecvFrame).
ScreenChoice
Video capture (video-core): cameras, screens, the OS picker, screen thumbnails and the pre-join preview over a kessel-video backend, as the sources the publish side takes. Video capture (video-core): cameras, screens, the OS picker, screen thumbnails and the pre-join preview over a kessel-video backend, as the sources the publish side takes. Video capture (video-core): cameras, screens, the OS picker, screen thumbnails and the pre-join preview over a kessel-video backend, as the sources the publish side takes. One display or window to share, with its thumbnail as a PNG.
ScreenSource
Video capture (video-core): cameras, screens, the OS picker, screen thumbnails and the pre-join preview over a kessel-video backend, as the sources the publish side takes. Video capture (video-core): cameras, screens, the OS picker, screen thumbnails and the pre-join preview over a kessel-video backend, as the sources the publish side takes. Video capture (video-core): cameras, screens, the OS picker, screen thumbnails and the pre-join preview over a kessel-video backend, as the sources the publish side takes. A running screen or window capture (VideoCapture::open_screen), with ContentHint::Screen. Everything of Capture through Deref.
ServerControls
A person’s Record and Stop in the call’s room, as Sew computes them (Call::recording_controls, CallEvent::RecordingControls, CallRecording::my_controls). Of two values, the larger rev is the newer. Sew still decides each Record and Stop; show its refusal if one comes.
SourceFeed
The video bridge: a kessel-video backend’s cameras, screens and encoders into a call, with the in-call self-view. The video bridge: a kessel-video backend’s cameras, screens and encoders into a call, with the in-call self-view. The video bridge: a kessel-video backend’s cameras, screens and encoders into a call, with the in-call self-view. A frame source a host opened itself (a screen or window from its picker, a camera with its own preview), handed to VideoBridge::publish_source: any kessel-video FrameSource and the size it delivers.
SourceNote
The video bridge: a kessel-video backend’s cameras, screens and encoders into a call, with the in-call self-view. The video bridge: a kessel-video backend’s cameras, screens and encoders into a call, with the in-call self-view. The video bridge: a kessel-video backend’s cameras, screens and encoders into a call, with the in-call self-view. A published source’s event (VideoBridge::events), in capture’s vocabulary.
Speaking
A speaking level (speaking event).
VideoBridge
The video bridge: a kessel-video backend’s cameras, screens and encoders into a call, with the in-call self-view. The video bridge: a kessel-video backend’s cameras, screens and encoders into a call, with the in-call self-view. The video bridge: a kessel-video backend’s cameras, screens and encoders into a call, with the in-call self-view. The video bridge of one app: a kessel-video backend into the current call.
VideoCaps
Video publishing: the engine’s frame API (Call::publish_video) and its types. Video publishing: the engine’s frame API (Call::publish_video) and its types. Video publishing: the engine’s frame API (Call::publish_video) and its types. Send caps on top of the policy (thermal pressure, low power): applied before the split.
VideoCapture
Video capture (video-core): cameras, screens, the OS picker, screen thumbnails and the pre-join preview over a kessel-video backend, as the sources the publish side takes. Video capture (video-core): cameras, screens, the OS picker, screen thumbnails and the pre-join preview over a kessel-video backend, as the sources the publish side takes. Video capture (video-core): cameras, screens, the OS picker, screen thumbnails and the pre-join preview over a kessel-video backend, as the sources the publish side takes. The app’s video capture over one kessel-video backend. Cheap to clone; clones share the camera: one opener holds it at a time (a new preview, or a camera opened for the publish, stops the running preview first).
VideoFrame
One decrypted, verified encoded frame of a remote video track.
VideoFrameStream
The receive side’s queue (one consumer), crate::Call::video_frames.
VideoLayerInfo
One simulcast layer a publisher sends, as its TrackInfo lists it.
VideoPublication
Video publishing: the engine’s frame API (Call::publish_video) and its types. Video publishing: the engine’s frame API (Call::publish_video) and its types. Video publishing: the engine’s frame API (Call::publish_video) and its types. A live publication’s handle (crate::Call::publish_video): push frames, follow controls.
VideoPublish
Video publishing: the engine’s frame API (Call::publish_video) and its types. Video publishing: the engine’s frame API (Call::publish_video) and its types. Video publishing: the engine’s frame API (Call::publish_video) and its types. What to publish (crate::Call::publish_video).
VideoSendStats
Video publishing: the engine’s frame API (Call::publish_video) and its types. Video publishing: the engine’s frame API (Call::publish_video) and its types. Video publishing: the engine’s frame API (Call::publish_video) and its types. The send-side video counters (crate::Call::video_stats).
VideoSender
Video publishing: the engine’s frame API (Call::publish_video) and its types. Video publishing: the engine’s frame API (Call::publish_video) and its types. Video publishing: the engine’s frame API (Call::publish_video) and its types. The frame half of a VideoPublication, cloneable.
VideoSink
One open sink of a remote video track (crate::Call::video_sink): while it is open (and visible) the track’s frames flow; dropping it closes it.
VideoSinkSpec
What a sink shows of a track; the engine asks the server for the union of a track’s sinks.
VideoTrack
A remote video track (camera or screen) of a participant.
VideoTrackView
One participant’s camera or screen in the snapshot (crate::Participant::camera, crate::Participant::screen).

Enums§

AudioBridgeError
Why the bridge could not start.
CallError
Why a call could not start or a command failed.
CallEvent
Something that happened in the call.
CallState
The call’s state (state event).
CameraFeed
Raw camera frames for a native self-view (video-core): VideoCapture::camera_tap. Raw camera frames for a native self-view (video-core): VideoCapture::camera_tap. Raw camera frames for a native self-view (video-core): VideoCapture::camera_tap. Whether a tap’s camera gives frames (CameraTap).
CameraState
The video bridge: a kessel-video backend’s cameras, screens and encoders into a call, with the in-call self-view. The video bridge: a kessel-video backend’s cameras, screens and encoders into a call, with the in-call self-view. The video bridge: a kessel-video backend’s cameras, screens and encoders into a call, with the in-call self-view. The camera’s state after VideoBridge::set_camera.
CameraTapItem
Raw camera frames for a native self-view (video-core): VideoCapture::camera_tap. Raw camera frames for a native self-view (video-core): VideoCapture::camera_tap. Raw camera frames for a native self-view (video-core): VideoCapture::camera_tap. What a CameraTap gives.
CaptureDspSchedError
Why CaptureDspSched::validate (and NoiseRemovalControl::set_dsp_sched) refused.
CaptureDspSchedFallback
Why the processing thread runs in CaptureDspSchedMode::Workgroup and not in the mode asked for (NoiseRemovalState::capture_stage_dsp_sched_fallback).
CaptureDspSchedMode
Which scheduling the audio pipeline’s processing thread asks the OS for (CaptureDspSched::mode, NoiseRemovalControl::set_dsp_sched). Only macOS and iOS act on it.
CaptureDspScheduling
How the OS schedules the audio pipeline’s processing thread, the thread the noise removal stage runs on (NoiseRemovalState::capture_stage_dsp_scheduling): the best of the requests the pipeline made that the OS granted. On macOS and iOS the thread asks for real-time scheduling; elsewhere it keeps the OS’s default.
CaptureEnd
Video capture (video-core): cameras, screens, the OS picker, screen thumbnails and the pre-join preview over a kessel-video backend, as the sources the publish side takes. Video capture (video-core): cameras, screens, the OS picker, screen thumbnails and the pre-join preview over a kessel-video backend, as the sources the publish side takes. Video capture (video-core): cameras, screens, the OS picker, screen thumbnails and the pre-join preview over a kessel-video backend, as the sources the publish side takes. Why a source ended (terminal: drop it, unpublish, release the lease).
CaptureError
Video capture (video-core): cameras, screens, the OS picker, screen thumbnails and the pre-join preview over a kessel-video backend, as the sources the publish side takes. Video capture (video-core): cameras, screens, the OS picker, screen thumbnails and the pre-join preview over a kessel-video backend, as the sources the publish side takes. Video capture (video-core): cameras, screens, the OS picker, screen thumbnails and the pre-join preview over a kessel-video backend, as the sources the publish side takes. Why a camera or screen could not be opened. CaptureError::code is the plugin’s code.
CaptureEvent
Video capture (video-core): cameras, screens, the OS picker, screen thumbnails and the pre-join preview over a kessel-video backend, as the sources the publish side takes. Video capture (video-core): cameras, screens, the OS picker, screen thumbnails and the pre-join preview over a kessel-video backend, as the sources the publish side takes. Video capture (video-core): cameras, screens, the OS picker, screen thumbnails and the pre-join preview over a kessel-video backend, as the sources the publish side takes. A source’s events, in order, in Sew’s vocabulary.
CaptureKind
Video capture (video-core): cameras, screens, the OS picker, screen thumbnails and the pre-join preview over a kessel-video backend, as the sources the publish side takes. Video capture (video-core): cameras, screens, the OS picker, screen thumbnails and the pre-join preview over a kessel-video backend, as the sources the publish side takes. Video capture (video-core): cameras, screens, the OS picker, screen thumbnails and the pre-join preview over a kessel-video backend, as the sources the publish side takes. A camera or a screen.
CapturePause
Video capture (video-core): cameras, screens, the OS picker, screen thumbnails and the pre-join preview over a kessel-video backend, as the sources the publish side takes. Video capture (video-core): cameras, screens, the OS picker, screen thumbnails and the pre-join preview over a kessel-video backend, as the sources the publish side takes. Video capture (video-core): cameras, screens, the OS picker, screen thumbnails and the pre-join preview over a kessel-video backend, as the sources the publish side takes. Why a source paused without ending (frames stop; the publication stays).
CaptureStageClock
The clock the audio pipeline times the noise removal stage by (NoiseRemovalState::capture_stage_clock).
CaptureTransient
A busy moment of the device reported to the audio pipeline, which opens its grace window for the stage (NoiseRemovalState::capture_stage_last_transient).
CodecPreferenceReason
Why “Prefer H.264” could not apply, so the device publishes VP8.
Dfn3LoadError
Why DeepFilterNet3’s weights were refused (feature dfn3). Why Dfn3Model::load refused. Nothing is loaded when one is returned.
EndReason
Why a call ended (ended.reason).
H264Detection
What the run-time check of this device’s OS H.264 encoder found.
NoiseDfn3State
Where the call’s stage is with DeepFilterNet3 (NoiseRemovalState::dfn3_state).
NoiseModel
The model that removes the noise when NoiseRemoval::Standard runs.
NoiseRemoval
How much noise this device’s microphone has removed. The default is NoiseRemoval::Standard.
NoiseRemovalReason
Why the noise removal that runs (NoiseRemovalState::active) is less than what was asked (NoiseRemovalState::mode).
NoiseStepDownReason
Why the call’s stage last stepped down from DeepFilterNet3 to RNNoise (NoiseRemovalState::step_down_reason): the stage’s own rule names.
PhoneAudioMode
How a phone’s microphone is captured (iOS and Android with feature mobile): through the OS’s voice processing, or raw, with the OS’s processing off (NoiseRemoval::Off).
PreviewItem
Video capture (video-core): cameras, screens, the OS picker, screen thumbnails and the pre-join preview over a kessel-video backend, as the sources the publish side takes. Video capture (video-core): cameras, screens, the OS picker, screen thumbnails and the pre-join preview over a kessel-video backend, as the sources the publish side takes. Video capture (video-core): cameras, screens, the OS picker, screen thumbnails and the pre-join preview over a kessel-video backend, as the sources the publish side takes. What the preview’s channel carries.
ProviderError
Why the host could not join.
RecordUnavailable
Sew’s recording types the engine’s recording API carries (from sew-proto). Why Record would be refused for now although the person may record: a hint a client may show on a greyed Record. It never changes can_record.
RecordingConsent
A person’s answer to a recording’s notice, as Sew stores it.
RecordingControl
What the person asks of the call’s recording: press Record, or Stop.
RecordingRef
Sew’s recording types the engine’s recording API carries (from sew-proto). What a recording_notice refers to: a live recording, or "auto" for an auto-record channel with no recording yet.
RecordingTrigger
Sew’s recording types the engine’s recording API carries (from sew-proto). What started a recording. Stored in recordings.trigger.
RecvItem
What the receive side hands the audio pipeline, in order.
RejoinReason
Why the engine asks for a join again.
ScreenPick
Video capture (video-core): cameras, screens, the OS picker, screen thumbnails and the pre-join preview over a kessel-video backend, as the sources the publish side takes. Video capture (video-core): cameras, screens, the OS picker, screen thumbnails and the pre-join preview over a kessel-video backend, as the sources the publish side takes. Video capture (video-core): cameras, screens, the OS picker, screen thumbnails and the pre-join preview over a kessel-video backend, as the sources the publish side takes. What to share (VideoCapture::open_screen).
SelfViewItem
The video bridge: a kessel-video backend’s cameras, screens and encoders into a call, with the in-call self-view. The video bridge: a kessel-video backend’s cameras, screens and encoders into a call, with the in-call self-view. The video bridge: a kessel-video backend’s cameras, screens and encoders into a call, with the in-call self-view. What the self-view channel carries (VideoBridge::self_view).
SessionEvent
The phone’s audio session, as the app reports it (CallKit on iOS, Telecom or the app’s own audio focus on Android), for AudioSession::event.
VideoCodec
A video codec a remote track can carry.
VideoCodecPreference
Which codec this device’s camera and screen publish in. A per-device user setting; the default is VideoCodecPreference::Automatic.
VideoControl
Video publishing: the engine’s frame API (Call::publish_video) and its types. Video publishing: the engine’s frame API (Call::publish_video) and its types. Video publishing: the engine’s frame API (Call::publish_video) and its types. What the engine tells the producer of a publication.
VideoError
Video publishing: the engine’s frame API (Call::publish_video) and its types. Video publishing: the engine’s frame API (Call::publish_video) and its types. Video publishing: the engine’s frame API (Call::publish_video) and its types. Why a lease or a publication failed: VideoError::code is the plugin’s error code.
VideoPause
Why the media server paused a track’s video for this member.
VideoRecvItem
What the receive side hands a video host, in order (crate::Call::video_frames).
VideoSource
What a remote video track shows.

Constants§

AUDIO_BACKEND
The audio backend platform_audio_config picks in this build: "os-voice" (iOS and Android with feature mobile: the OS’s own voice processing) or "system" (cpal).
CONSENT_UNSUPPORTED
The Refused code of JoinProvider::consent’s default: the host sends no consent.
CRYPTO_BACKEND
The call peer connection’s DTLS/SRTP provider in this build: "rust-crypto" (features rust-crypto, mobile: dimpl’s RustCrypto backend and RustCrypto SRTP) or "aws-lc-rs".
DFN3_IDLE_UNLOAD
What loading DeepFilterNet3’s weights cost, and how long the model stays after the last call by default (feature dfn3). What loading DeepFilterNet3’s weights cost, and how long the model stays after the last call by default (feature dfn3). What loading DeepFilterNet3’s weights cost, and how long the model stays after the last call by default (feature dfn3). How long the model stays in memory after the last call’s audio ends, by default (NoiseRemovalControl::set_dfn3_idle_unload). Five minutes: calls come in clusters (a call back, a rejoin after a drop, the next meeting), and a reload costs a file read and tens of milliseconds of one core, so the model stays for those, and the memory is back soon after a session of calls ends.
DFN3_WEIGHTS_FILE
The DeepFilterNet3 weights file’s name, as an app ships it (feature dfn3). The weights archive’s file name, as apps ship it.
ENGINE_VERSION
The engine’s name and version as Sew sees it (ClientInfo, the caps’ sdk_version).
PREVIEW_BITRATE_BPS
Video capture (video-core): cameras, screens, the OS picker, screen thumbnails and the pre-join preview over a kessel-video backend, as the sources the publish side takes. Video capture (video-core): cameras, screens, the OS picker, screen thumbnails and the pre-join preview over a kessel-video backend, as the sources the publish side takes. Video capture (video-core): cameras, screens, the OS picker, screen thumbnails and the pre-join preview over a kessel-video backend, as the sources the publish side takes. The preview encoder’s bitrate (it is never sent; enough for a clean self-view).
PREVIEW_FPS
Video capture (video-core): cameras, screens, the OS picker, screen thumbnails and the pre-join preview over a kessel-video backend, as the sources the publish side takes. Video capture (video-core): cameras, screens, the OS picker, screen thumbnails and the pre-join preview over a kessel-video backend, as the sources the publish side takes. Video capture (video-core): cameras, screens, the OS picker, screen thumbnails and the pre-join preview over a kessel-video backend, as the sources the publish side takes. The preview’s frame rate.
PREVIEW_HEIGHT
Video capture (video-core): cameras, screens, the OS picker, screen thumbnails and the pre-join preview over a kessel-video backend, as the sources the publish side takes. Video capture (video-core): cameras, screens, the OS picker, screen thumbnails and the pre-join preview over a kessel-video backend, as the sources the publish side takes. Video capture (video-core): cameras, screens, the OS picker, screen thumbnails and the pre-join preview over a kessel-video backend, as the sources the publish side takes. The preview’s largest coded height.
PREVIEW_QUEUE
Video capture (video-core): cameras, screens, the OS picker, screen thumbnails and the pre-join preview over a kessel-video backend, as the sources the publish side takes. Video capture (video-core): cameras, screens, the OS picker, screen thumbnails and the pre-join preview over a kessel-video backend, as the sources the publish side takes. Video capture (video-core): cameras, screens, the OS picker, screen thumbnails and the pre-join preview over a kessel-video backend, as the sources the publish side takes. Items the preview’s channel holds; when the reader falls behind, the camera’s own 2-deep queue drops raw frames (never an encoded one, so the stream stays decodable).
PREVIEW_WIDTH
Video capture (video-core): cameras, screens, the OS picker, screen thumbnails and the pre-join preview over a kessel-video backend, as the sources the publish side takes. Video capture (video-core): cameras, screens, the OS picker, screen thumbnails and the pre-join preview over a kessel-video backend, as the sources the publish side takes. Video capture (video-core): cameras, screens, the OS picker, screen thumbnails and the pre-join preview over a kessel-video backend, as the sources the publish side takes. The preview’s largest coded size (the camera’s aspect ratio is kept inside it).
RECORDING_UNSUPPORTED
The Refused code of JoinProvider::recording’s default: the host sends no Record or Stop.
THUMBNAIL_MAX_WIDTH
Video capture (video-core): cameras, screens, the OS picker, screen thumbnails and the pre-join preview over a kessel-video backend, as the sources the publish side takes. Video capture (video-core): cameras, screens, the OS picker, screen thumbnails and the pre-join preview over a kessel-video backend, as the sources the publish side takes. Video capture (video-core): cameras, screens, the OS picker, screen thumbnails and the pre-join preview over a kessel-video backend, as the sources the publish side takes. The widest screen-source thumbnail (screen_sources), in pixels.
USER_AGENT
The user agent of the key routes and the call socket (no personal data).

Traits§

JoinProvider
The host’s join callback: call Sew’s voice or DM call join with call_credential: true (and no e2ee) and return the answer unchanged.

Functions§

choose_codecDeprecated
The video bridge: a kessel-video backend’s cameras, screens and encoders into a call, with the in-call self-view. The video bridge: a kessel-video backend’s cameras, screens and encoders into a call, with the in-call self-view. The video bridge: a kessel-video backend’s cameras, screens and encoders into a call, with the in-call self-view. The codec a native sender publishes in: VP8 when the policy lists it and the backend has a VP8 encoder (kessel-video’s pure-Rust one, or the OS’s), else H.264 when the policy lists it and an H.264 encoder exists; None: codec_unavailable.
choose_codecs
The video bridge: a kessel-video backend’s cameras, screens and encoders into a call, with the in-call self-view. The video bridge: a kessel-video backend’s cameras, screens and encoders into a call, with the in-call self-view. The video bridge: a kessel-video backend’s cameras, screens and encoders into a call, with the in-call self-view. What a native sender publishes in, on caps, under the call’s policy, with the automatic codec preference, on a device that decodes H.264 where its platform does (crate::default_video_h264):
default_video_h264
Whether this platform negotiates H.264 by default (ClientConfig::video_h264): false on Linux (no H.264 decoder there), true elsewhere.
effective_publish_codec
The codec a camera or screen of this device publishes in under pref, given what the H.264 detection found, and why “Prefer H.264” didn’t apply when it didn’t.
effective_publish_codec_under_policy
effective_publish_codec in a call whose media policy allows H.264 (h264_allowed) or not: without it, an H264 turns into VP8, with CodecPreferenceReason::Policy under “Prefer H.264”. The device’s own reasons come first (a device that can’t publish H.264 says so whatever the policy).
h264_encode_detection
The per-device video codec preference and the run-time H.264 check it rests on. The first of the three checks, from a kessel-video backend’s capabilities: an H.264 encode entry run by hardware. A software entry never counts. Linux, Android and Windows backends are always H264Detection::NoPlatformCheck. An iOS before 17.4 lists none, since it can’t confirm hardware: H264Detection::Unconfirmed.
plan_layers
Video publishing: the engine’s frame API (Call::publish_video) and its types. Video publishing: the engine’s frame API (Call::publish_video) and its types. Video publishing: the engine’s frame API (Call::publish_video) and its types. The layers of hint for a capture of capture_width × capture_height, lowest first. A hint layer’s height is its short side (180p, 360p, 720p): each layer whose short side is at most the capture’s, the long side scaled to the capture’s aspect (even), in the capture’s orientation (a portrait phone camera gets portrait layers, 180 × 320 rather than 100 × 180), at the hint’s frame rate. A capture smaller than every layer gets the lowest one at the capture’s size.
plan_screen_layers
Video publishing: the engine’s frame API (Call::publish_video) and its types. Video publishing: the engine’s frame API (Call::publish_video) and its types. Video publishing: the engine’s frame API (Call::publish_video) and its types. The layers of a screen share for a capture of capture_width × capture_height, lowest first: plan_layers, and on top the capture’s own size when the hint has a layer above the top one that fits (a 1366×768 or 1440×900 display under a 1080p hint), so that a viewer who zooms in gets the screen’s real pixels rather than a downscaled copy. That layer takes the larger hint layer’s rid and frame rate, and its cap scaled to the capture’s pixels (never below the layer under it). A capture within a quarter of the top fitting layer’s short side keeps plan_layers’ layers (a near copy would spend the uplink for nothing); so does a capture smaller than every layer (its one layer is already the capture’s size). The capture is within the hint’s max_width × max_height already (the capture constraints).
platform_audio_config
The kessel-audio config for a call on this platform’s audio.
preview_codec
Video capture (video-core): cameras, screens, the OS picker, screen thumbnails and the pre-join preview over a kessel-video backend, as the sources the publish side takes. Video capture (video-core): cameras, screens, the OS picker, screen thumbnails and the pre-join preview over a kessel-video backend, as the sources the publish side takes. Video capture (video-core): cameras, screens, the OS picker, screen thumbnails and the pre-join preview over a kessel-video backend, as the sources the publish side takes. The codec the preview encodes with on these capabilities: VP8 when the backend has a VP8 encoder (every backend with kessel-video’s vp8), else H.264, else none.
screen_constraints
Video capture (video-core): cameras, screens, the OS picker, screen thumbnails and the pre-join preview over a kessel-video backend, as the sources the publish side takes. Video capture (video-core): cameras, screens, the OS picker, screen thumbnails and the pre-join preview over a kessel-video backend, as the sources the publish side takes. Video capture (video-core): cameras, screens, the OS picker, screen thumbnails and the pre-join preview over a kessel-video backend, as the sources the publish side takes. Screen constraints: at most max_width x max_height at fps, the cursor drawn, and this app’s own windows left out of display capture where the OS allows it (VideoCapture::open_screen clears that where it doesn’t).
system_clock
The system clock.
thumbnail_png
Video capture (video-core): cameras, screens, the OS picker, screen thumbnails and the pre-join preview over a kessel-video backend, as the sources the publish side takes. Video capture (video-core): cameras, screens, the OS picker, screen thumbnails and the pre-join preview over a kessel-video backend, as the sources the publish side takes. Video capture (video-core): cameras, screens, the OS picker, screen thumbnails and the pre-join preview over a kessel-video backend, as the sources the publish side takes. A source’s thumbnail as an 8-bit RGBA PNG at most THUMBNAIL_MAX_WIDTH wide (scaled down keeping the aspect ratio, each pixel the average of its box). None without a thumbnail, without its size, or with one that isn’t RGBA or BGRA.

Type Aliases§

BoxFuture
A boxed future, as the trait methods return.
Clock
Wall-clock unix milliseconds, or a test clock.
PreviewFrames
Video capture (video-core): cameras, screens, the OS picker, screen thumbnails and the pre-join preview over a kessel-video backend, as the sources the publish side takes. Video capture (video-core): cameras, screens, the OS picker, screen thumbnails and the pre-join preview over a kessel-video backend, as the sources the publish side takes. Video capture (video-core): cameras, screens, the OS picker, screen thumbnails and the pre-join preview over a kessel-video backend, as the sources the publish side takes. The preview’s frames.
SelfViewFrames
The video bridge: a kessel-video backend’s cameras, screens and encoders into a call, with the in-call self-view. The video bridge: a kessel-video backend’s cameras, screens and encoders into a call, with the in-call self-view. The video bridge: a kessel-video backend’s cameras, screens and encoders into a call, with the in-call self-view. This device’s own camera and screen frames while they are published.