Repository navigation
Add audio-follow-video (AFV) signaling to the mixer orchestrator - #44
MateuszSalski wants to merge 5 commits into
Conversation
|
@MateuszSalski could you review the two commits I pushed to this branch (4652208, d30558b)? Problem: Change: the node is now clocked by the program's video ticks, not by its inputs.
Tests:
Still open for you:
🤖 Generated with Claude Code |
mixer.init's audio_router_node names an external IInputsObjects node; the orchestrator emits transition_ended on every cut/take completion and transition_progress per program frame during a fade, dip or wipe (at the take's TakeClock progress, the lever's included), so that node's own gain policy can follow program/preview changes. AUX preview followers emit transition_ended for their buses. Also: optional per-source audio decode (Source.has_audio -> MixerApplication.audio_edges), preserving each source's native channel layout, the open-source audio_mixer node, a Janus Opus audio output helper, a program-audio mute toggle on the operator page's viewers, and the demos/mixer_audio demo. Squashed from feature/audio-follow-video (56c670a..12de1ca) onto develop. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The node mixed only once every input held a full block, so one stalled or restarting source silenced every bus while the other inputs' queues grew without bound. Blocks of frame_samples now leave at the deadline of the program video tick holding their last sample (tick time + the compositor's latency_ms), with that tick's picture, whatever arrived by then. Each source's samples are placed by their realtime set_pts media time in a SampleQueue: a frame within 1 ms of the previous one's end continues it, a late or missing span is silence faded out and back in over 3 ms, and nothing is held more than 1 s ahead. Output blocks carry their media time instead of a counter from 0, and gain events are kept by sample index. A status object counts dropped, missing and discontinuous samples per source. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
develop's graph builds nodes (MixerDelivery and others) this test's own list did not name; take the list from test_graph.fake_api instead. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
d30558b to
735ac94
Compare
|
@MateuszSalski I rebased this branch onto latest develop ( What changed while resolving the conflicts:
Tests: module build, C++ core test, the native audio test and 925 mixer pytest pass on a build container. Not yet run: a GPU show, Janus/browser audio, lip sync. Items 2–7 of my previous comment are still open. The previous head was 🤖 Generated with Claude Code |
Program audio reached no browser through Setup: its Janus mountpoints were created video-only, and the setup's mixer never named an audio router, so a has_audio source's audio edge went unread and would fill and hold its demux, and the video with it. The show is now the one source of truth. With a has_audio source: - build_application defaults audio_router_node to the in-tree audio_mixer (MixerOptions.audio_router_node still names another router); - MixerConfig.audio_rendition picks the first dirty Janus program rendition for the program audio's one RTP port; - janus_mountpoints creates that mountpoint with the Opus stream build_janus_audio_output sends, and adds it to an existing video-only one on replace; - that output's settings.program_outputs entry carries "audio": true, and the viewers offer the mute toggle only there (it showed on every program viewer, audio or not). A show without has_audio sources is unchanged. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
|
@MateuszSalski one more commit,
Verified on an L4 with this branch's images, using a two-source show (flash + beep per second, 880 / 440 Hz):
Lip sync in the browser is still open: video has no RTCP SR. 🤖 Generated with Claude Code |
mixer.init's audio_router_node names an external IInputsObjects node; the orchestrator emits afv_program on every cut/take completion and afv_crossfade per frame during a crossfade, so that node's own gain policy can follow program/preview changes.
Also: optional per-source audio decode (Source.has_audio ->
MixerApplication.audio_edges), preserving each source's native channel layout (mono, stereo, 5.1, ...) rather than forcing stereo, and a Janus Opus audio output helper, for an application that wants to feed and ship that node's mix.