feat: implement TS3 protocol layer, session management, and ServerQuery client
CI/CD / Test (ubuntu-latest) (push) Successful in 2m3s
CI/CD / Build Frontend (push) Failing after 11s
CI/CD / Test (macos-latest) (push) Has been cancelled
CI/CD / Test (windows-latest) (push) Has been cancelled
CI/CD / Build Desktop (linux) (push) Has been cancelled
CI/CD / Build Desktop (macos) (push) Has been cancelled
CI/CD / Build Desktop (windows) (push) Has been cancelled
CI/CD / Release (push) Has been cancelled
CI/CD / Test (ubuntu-latest) (push) Successful in 2m3s
CI/CD / Build Frontend (push) Failing after 11s
CI/CD / Test (macos-latest) (push) Has been cancelled
CI/CD / Test (windows-latest) (push) Has been cancelled
CI/CD / Build Desktop (linux) (push) Has been cancelled
CI/CD / Build Desktop (macos) (push) Has been cancelled
CI/CD / Build Desktop (windows) (push) Has been cancelled
CI/CD / Release (push) Has been cancelled
- Add real X25519 ECDH key exchange for initivexpand2 bootstrap - Add P-256 identity key generation with TeamSpeak tomcrypt format - Add session event loop with tokio::select! for packet/command handling - Add ServerQuery TCP client with typed parsing (channels, clients, permissions) - Add Tauri commands: connect (session-based), join_channel, send_message, disconnect - Add frontend ServerQuery snapshot panel - Fix CI: Node 22, rustup setup, npm install, workspace checks - Add mock UDP handshake tests through initserver - 54 tests passing across shared, tscore, tsaudio, tsdb
This commit is contained in:
@@ -1,6 +1,6 @@
|
||||
//! 抖动缓冲
|
||||
|
||||
use super::{AudioFrame, AudioResult, AudioError};
|
||||
use super::{AudioError, AudioFrame, AudioResult};
|
||||
|
||||
/// 抖动缓冲
|
||||
pub struct JitterBuffer {
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
//! 音频采集
|
||||
|
||||
use super::{AudioConfig, AudioFrame, AudioResult, AudioError};
|
||||
use super::{AudioConfig, AudioError, AudioFrame, AudioResult};
|
||||
|
||||
pub struct AudioCapture {
|
||||
config: AudioConfig,
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
//! Opus 编解码器
|
||||
|
||||
use super::{AudioResult, AudioError};
|
||||
use super::{AudioError, AudioResult};
|
||||
|
||||
pub struct OpusEncoder {
|
||||
sample_rate: u32,
|
||||
@@ -9,7 +9,10 @@ pub struct OpusEncoder {
|
||||
|
||||
impl OpusEncoder {
|
||||
pub fn new(sample_rate: u32, channels: u16) -> AudioResult<Self> {
|
||||
Ok(Self { sample_rate, channels })
|
||||
Ok(Self {
|
||||
sample_rate,
|
||||
channels,
|
||||
})
|
||||
}
|
||||
|
||||
pub fn encode(&mut self, _samples: &[f32]) -> AudioResult<Vec<u8>> {
|
||||
@@ -28,7 +31,10 @@ pub struct OpusDecoder {
|
||||
|
||||
impl OpusDecoder {
|
||||
pub fn new(sample_rate: u32, channels: u16) -> AudioResult<Self> {
|
||||
Ok(Self { sample_rate, channels })
|
||||
Ok(Self {
|
||||
sample_rate,
|
||||
channels,
|
||||
})
|
||||
}
|
||||
|
||||
pub fn decode(&mut self, _data: &[u8], _fec: bool) -> AudioResult<Vec<f32>> {
|
||||
|
||||
+13
-9
@@ -1,16 +1,16 @@
|
||||
//! TeamSpeak 音频引擎
|
||||
|
||||
pub mod capture;
|
||||
pub mod playback;
|
||||
pub mod codec;
|
||||
pub mod vad;
|
||||
pub mod buffer;
|
||||
pub mod capture;
|
||||
pub mod codec;
|
||||
pub mod playback;
|
||||
pub mod vad;
|
||||
|
||||
pub use capture::*;
|
||||
pub use playback::*;
|
||||
pub use codec::*;
|
||||
pub use vad::*;
|
||||
pub use buffer::*;
|
||||
pub use capture::*;
|
||||
pub use codec::*;
|
||||
pub use playback::*;
|
||||
pub use vad::*;
|
||||
|
||||
use thiserror::Error;
|
||||
|
||||
@@ -58,7 +58,11 @@ pub struct AudioFrame {
|
||||
|
||||
impl AudioFrame {
|
||||
pub fn new(sample_rate: u32, channels: u16, samples: Vec<f32>) -> Self {
|
||||
Self { sample_rate, channels, samples }
|
||||
Self {
|
||||
sample_rate,
|
||||
channels,
|
||||
samples,
|
||||
}
|
||||
}
|
||||
|
||||
pub fn frame_size(&self) -> usize {
|
||||
|
||||
Reference in New Issue
Block a user