fn writer_thread(
rx: Receiver<Tap>,
file: File,
path: String,
backend: &'static str,
mode_name: &'static str,
audio: Option<AudioTrackConfig>,
shared: Arc<RecShared>,
)Expand description
Writer-thread body: drain the queue, convert Annex-B to AVCC, and mux. Output starts at the first IDR with parameter sets; earlier frames are discarded and audio packets held. Runs until every sender is dropped (stop) or a write error occurs, then finalizes the file and publishes the final status.