[package] name = "chanora_audio" description = "Chanora audio subsystem — cpal-based capture/playback, audiopus encode, tsclientlib AudioHandler for decode + jitter buffer + mix. DEC-011, DEC-011.1." version.workspace = true edition.workspace = true rust-version.workspace = true authors.workspace = true license.workspace = true repository.workspace = true publish.workspace = true [dependencies] chanora_protocol = { path = "../chanora_protocol" } thiserror.workspace = true tracing.workspace = true # Cross-platform audio I/O (DEC-011.1). cpal = "0.16" # Opus encoder. tsclientlib already pulls this; we depend explicitly so # this crate can compile against it without going through tsclientlib. audiopus = "0.3.0-rc.0" # AudioHandler lives in the tsclientlib crate behind the `audio` # feature. We import the crate just for the AudioHandler type; the # Connection type stays inside chanora_protocol. tsclientlib = { git = "https://github.com/ReSpeak/tsclientlib.git", rev = "04aa2491", default-features = false, features = ["default-tls", "audio"] } tokio = { version = "1", features = ["sync", "rt", "macros", "time"] } [target.'cfg(target_os = "android")'.dependencies] # JNI bindings to flip Android's AudioManager into MODE_IN_COMMUNICATION # when the voice-comm preset is requested. ndk_context is initialised # by the bridge crate's android_init shim. jni = { version = "0.21", default-features = false } ndk-context = "0.1" [dev-dependencies] # `test-util` enables `start_paused` / virtual-clock tests used by # the missed-key-up watchdog unit tests. tokio = { version = "1", features = ["sync", "rt", "macros", "time", "test-util"] } [target.'cfg(target_os = "linux")'.dependencies] # GNOME-on-Wayland Global Push-to-Talk uses the freedesktop # `org.freedesktop.portal.GlobalShortcuts` interface over D-Bus. # `zbus` is the standard async D-Bus crate; we use the blocking # proxy for the probe path since portal version reads happen at # audio-engine start (off the hot path). The `tokio` runtime # selector is mandatory in zbus 5; we share the tokio runtime # the rest of the audio + core crates already depend on. zbus = { version = "5", default-features = false, features = ["tokio", "blocking-api"] }