Repository navigation
Live: a member's page watches this Mac now, over WebRTC - #2
Merged
Merged
Conversation
The Mac app is a WebRTC peer. When a member's page asks (`device/live-signal { want }` on
/devices/<name>), the Mac offers each display it may show, one camera and the microphone, send
only, H.264 in hardware. The mind carries only the signalling; pictures and sound go peer to
peer. Measured with the app's own libraries: a picture is shown about 10 ms after it was drawn.
- `Sources/Live` holds everything that touches WebRTC (LiveKit's build, a binary target from
this repository's release, carried in Contents/Frameworks).
- `Record` hands each frame and sound buffer to sinks (`CaptureSink`): the record's tracks are
one, live is a second. A watched screen captures 30 frames a second; the record keeps 10.
- The owner's switches decide through the same gate as every use; a watch shows in Activity and
in the panel, and `live.state()` / `live.end()` are on the endpoint.
Session: claude b0eec5e0-9c0a-43e6-bf1b-01b7e83c523c on jonas-macbook-pro
Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What. The Mac app is now a WebRTC peer. When a member's page on
record.<domain>asks(
device/live-signal { want }on/devices/<name>), the Mac offers each display it may show,one camera (1280×720 at most) and the microphone. The tracks are send only, H.264 in hardware,
and the picture is shown at once with the sound in its own stream. The mind carries only the
signalling. The pictures and the sound go peer to peer.
Sources/Liveholds everything that touches WebRTC (LiveKit's build, a binary target fetchedfrom this repository's release, carried in
Contents/Frameworks).Recordgets one seam: the sources hand each frame and sound buffer to sinks (CaptureSink).The record's own tracks are one sink, and live is a second. The capture runs for the union of
what the record and live want. A watched screen captures 30 frames a second, and the record
keeps its 10 by time.
LiveWatchers, VoiceMeetCore).bridge/device-live.mjscarries the signals, asks the facetrecordfor ICE servers (STUNwhen it has none), and appends
device/live-watch-started/-ended.Ask asks once per watch, and Shared is sent. Turning a switch Off ends a watch. Activity shows
"Watched live by " while it runs. The panel lists the watchers with End.
live.state()andlive.end()are on the endpoint.Info.plistgetsNSLocalNetworkUsageDescription.Why. The record's files are 30 to 60 seconds behind; a live view needs to be a few milliseconds behind, and it must not change the record. The same capture now feeds both.
Proof (one Mac, a headless watcher, signalling through the mind on
/devices/record-test-rtc-app, with the app's own libraries and bridge vialive-run):buffer.
and identical audio levels, the same as two runs of the old code. With a watcher at 30, the
record kept the same 220/230 frames per slot.
tracks arrived (numbers only).
swift test: 86 tests, 16 of them new.Risk map.
tests pass.
--build-onlyplus render isproven; the first install is the real test.
events), and Off ends a watch. Unproven in the installed app: see the report's checklist.
Session: claude b0eec5e0-9c0a-43e6-bf1b-01b7e83c523c on jonas-macbook-pro
🤖 Generated with Claude Code