- Introduce `Streamtype` enum (Continuous vs Finite) to distinguish radio streams from finite tracks - Enrich `TrackBoundary` sync marker with stream type for proper pause behavior per mode (silence vs backpressure) - Update all sources and sinks to pass `StreamType` when creating track boundaries - Radio Paradise, HTTP source → Continuous (infinite) - Improve UPnP control architecture: pause sends silence for radio, blocks pipeline via backpressure for tracks - Prepare groundwork for multi-client DSP architecture with shared source and per-DSP pipelines
26 lines
451 B
Rust
Executable File
26 lines
451 B
Rust
Executable File
use std::sync::Arc;
|
|
use tokio::sync::RwLock;
|
|
|
|
use pmometadata::TrackMetadata;
|
|
|
|
#[derive(Debug, Clone, Copy, PartialEq, Eq)]
|
|
pub enum StreamType {
|
|
Continuous,
|
|
Finite,
|
|
}
|
|
|
|
pub enum SyncMarker {
|
|
TrackBoundary {
|
|
metadata: Arc<RwLock<dyn TrackMetadata>>,
|
|
stream_type: StreamType,
|
|
},
|
|
StreamMetadata {
|
|
key: String,
|
|
value: String,
|
|
},
|
|
TopZeroSync,
|
|
Heartbeat,
|
|
EndOfStream,
|
|
Error(String),
|
|
}
|