The engine's voice source is now a voelin_proto::link::Session obtained from a registry of connectors (docs/session-seam.md, slice 1): - link::Backends keeps the plain connectors of voelin_proto::link::Connectors and the in-process ones that also hand the engine a port for TeamSpeak 6 streams; the scheme of the address picks the connector, an address without one is a TeamSpeak bookmark. - link::SessionLink is the engine's ServerLink. session.rs is unchanged and still speaks LinkCmd and LinkEvent; SessionLink runs the connect sequence (List the server, subscribe HOME, SERVER and LIVE, take the seat), keeps a voelin_model::replica::Replica, projects it into the client's older model (link/project.rs, the fix-ups F1 to F10), frames voice as RTP and derives who talks from the media (link/media.rs), and turns every command into the Session call of its row. Transfers copy through read_file and write_file. - ts_session makes a TeamSpeak connection a Session: LinkSession over any ServerLink translates the link's commands, events and presence snapshots to v1 entities, pushes, answers and RTP; TsConnector makes them for ts3server:// and teamspeak:// addresses with TsLink inside, and LinkConnector for the link of Engine::start_with_link. - voice.rs opens the transfer connection itself for the new OpenRead and OpenWrite commands; files::download and upload are generic over the stream. - Engine::start_with_backends is new; start_with and start_with_link go through the registry. tests/link_fake.rs runs through both adapters; its fixtures are normalised as the design says (an order chain, database ids, talking from media, the server named, channel chat for the channel we are in), and the request id the link sees is the session's own. New unit tests cover every row of the mapping with a recording link, the TeamSpeak session on its own, media framing both ways, the talk tracker, the close table, the error texts, the backend and capability tables, the connect parameters, and the presence round trip on book fixtures and generated presences. Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
85 lines
3.6 KiB
TOML
85 lines
3.6 KiB
TOML
[package]
|
|
name = "voelin-core"
|
|
version = "0.1.0"
|
|
description = "Client engine: server sessions merging voice, gateway and query sources; the API the UI drives."
|
|
edition.workspace = true
|
|
rust-version.workspace = true
|
|
license.workspace = true
|
|
repository.workspace = true
|
|
publish.workspace = true
|
|
|
|
[features]
|
|
default = ["audio-device"]
|
|
# Capture and play audio through the system's devices.
|
|
audio-device = ["voelin-audio/device"]
|
|
# The `media` module: capture and video codecs for streams, with whatever
|
|
# voelin-media backends are enabled (e.g. MediaCodec and a registered capture
|
|
# source on Android), and the studio's WHIP output. The crate itself is always
|
|
# there: the stream types in the API (`EncodedFrame`, `LayerSpec`) are its.
|
|
media = ["voelin-media/whip"]
|
|
# `media` with voelin-media's desktop backends: libvpx, dav1d, OpenH264 and
|
|
# FFmpeg loaded at runtime, X11 and PipeWire on Linux. Not for Android
|
|
# (libvpx does not cross-compile there).
|
|
media-desktop = ["media", "voelin-media/default"]
|
|
|
|
[dependencies]
|
|
anyhow = "1"
|
|
base64 = "0.22"
|
|
# The RTP packets of the session seam (`voelin_proto::link::MediaPacket`).
|
|
bytes = "1"
|
|
dirs = "6"
|
|
futures = "0.3"
|
|
# Finding a server's gateway in DNS (the voice resolver's version).
|
|
hickory-resolver = "0.26"
|
|
md5 = "0.8"
|
|
# A stalled HTTP/2 connection's error, told apart (the version reqwest's hyper
|
|
# uses).
|
|
h2 = "0.4"
|
|
# Retry-After dates (already in the tree through hyper).
|
|
httpdate = "1"
|
|
# Banners on the web; the client the workspace has (voelin-query, voelin-media).
|
|
# `system-proxy`: the proxy settings of Windows and macOS; `socks`: SOCKS
|
|
# proxies (from the desktop's settings or ALL_PROXY).
|
|
reqwest = { version = "0.13.5", default-features = false, features = ["rustls", "socks", "system-proxy"] }
|
|
# Reading the official clients' settings.db when importing identities.
|
|
rusqlite = { version = "0.40.2", features = ["bundled"] }
|
|
serde = { version = "1", features = ["derive"] }
|
|
serde_json = "1"
|
|
thiserror = "2"
|
|
tokio = { version = "1", features = ["fs", "io-util", "macros", "net", "rt-multi-thread", "sync", "time"] }
|
|
tokio-tungstenite = "0.30"
|
|
toml = "1.1.6"
|
|
tracing = "0.1"
|
|
voelin-audio = { path = "../voelin-audio", default-features = false }
|
|
voelin-gateway-proto = { path = "../voelin-gateway-proto", features = ["client"] }
|
|
voelin-media = { path = "../voelin-media", default-features = false }
|
|
voelin-model = { workspace = true }
|
|
voelin-observer = { path = "../voelin-observer" }
|
|
# Paths only (the cache directory).
|
|
voelin-platform = { path = "../voelin-platform", default-features = false }
|
|
# The backend-neutral session seam the engine consumes (`voelin_proto::link`)
|
|
# and the v1 messages it speaks.
|
|
voelin-proto = { workspace = true }
|
|
voelin-query = { path = "../voelin-query" }
|
|
voelin-store = { path = "../voelin-store" }
|
|
voelin-stream = { path = "../voelin-stream" }
|
|
tsclientlib = { path = "../proto/tsclientlib" }
|
|
# The hash cash level, for raising an identity's security level.
|
|
tsproto = { path = "../proto/tsproto" }
|
|
tsproto-packets = { path = "../proto/tsproto-packets" }
|
|
tsproto-types = { path = "../proto/tsproto-types" }
|
|
|
|
[dev-dependencies]
|
|
# An HTTP/2 connection in a test (already in the tree through h2).
|
|
http = "1"
|
|
# Already in the app's graph (reqwest); for one_rustls_crypto_provider.
|
|
rustls = { version = "0.23", default-features = false }
|
|
# `process`: the browser interop test drives Chromium through Node.js.
|
|
tokio = { version = "1", features = ["macros", "net", "process", "rt-multi-thread", "test-util"] }
|
|
# The fakes of the session seam (`FakeHost`, `FakeSession`, the conformance
|
|
# suite).
|
|
voelin-proto = { workspace = true, features = ["test-util"] }
|
|
|
|
[lints]
|
|
workspace = true
|