No description
Find a file
Breadway 7fb1934d52 cast: don't drop the io loop on a single bad message, and don't let a scopeless link-local IPv6 clobber a working host
The receiver-status io loop treated any read error as a dead connection,
so one malformed/unexpected message (e.g. a MEDIA_STATUS missing a field
the struct requires) tore down the whole control channel for the rest of
the session even though the RTP stream was fine. Only end the loop on
Io/Tls/Dns errors now; log and keep going on Serialization/Parsing/etc.

mDNS resolves a single physical Cast device once per local address it
has, so the same device id can show up with a private IPv4 host and
again with a link-local IPv6 host. A bare fe80:: address has no zone id
attached, so connecting to it fails outright -- don't let it replace an
already-usable host in the device map just because it resolved more
recently.
2026-08-15 22:34:21 +08:00
.forgejo/workflows ci: build on bread-ecosystem's shared Arch container 2026-08-05 19:16:28 +08:00
breadcast Implement Cast Streaming mirroring, DLNA casting, daemon+GUI, and breadd integration 2026-08-03 09:07:21 +08:00
breadcast-caststream-sys Fix Cast Streaming teardown crash, bitrate collapse, and HLS latency 2026-08-15 22:34:21 +08:00
breadcast-core cast: don't drop the io loop on a single bad message, and don't let a scopeless link-local IPv6 clobber a working host 2026-08-15 22:34:21 +08:00
breadcastd cast: don't drop the io loop on a single bad message, and don't let a scopeless link-local IPv6 clobber a working host 2026-08-15 22:34:21 +08:00
ci ci: build on bread-ecosystem's shared Arch container 2026-08-05 19:16:28 +08:00
contrib Implement Cast Streaming mirroring, DLNA casting, daemon+GUI, and breadd integration 2026-08-03 09:07:21 +08:00
graphify-out docs: describe the shipped bakery product and single-trunk releases 2026-08-15 21:38:38 +08:00
vendor/rust_cast-0.21.0 Implement Cast Streaming mirroring, DLNA casting, daemon+GUI, and breadd integration 2026-08-03 09:07:21 +08:00
.gitignore gitignore: ignore graphify-out/ knowledge-graph cache 2026-08-15 22:34:21 +08:00
AGENTS.md Track AGENTS.md 2026-08-15 22:03:30 +08:00
bakery.toml docs: describe the shipped bakery product and single-trunk releases 2026-08-15 21:38:38 +08:00
Cargo.lock Implement Cast Streaming mirroring, DLNA casting, daemon+GUI, and breadd integration 2026-08-03 09:07:21 +08:00
Cargo.toml Implement Cast Streaming mirroring, DLNA casting, daemon+GUI, and breadd integration 2026-08-03 09:07:21 +08:00
CONTRIBUTING.md docs: describe the shipped bakery product and single-trunk releases 2026-08-15 21:38:38 +08:00
EVENTS.md Implement Cast Streaming mirroring, DLNA casting, daemon+GUI, and breadd integration 2026-08-03 09:07:21 +08:00
LICENSE Implement Cast Streaming mirroring, DLNA casting, daemon+GUI, and breadd integration 2026-08-03 09:07:21 +08:00
README.md docs: describe the shipped bakery product and single-trunk releases 2026-08-15 21:38:38 +08:00

breadcast

Cast your screen to a Chromecast, Google TV, or DLNA renderer on the LAN. Two binaries:

  • breadcastd — background daemon. Discovers Cast (mDNS) and DLNA/UPnP (SSDP) devices, owns the portal screen-capture / encode pipeline, and runs the live session: Cast Streaming (vendored openscreen) or DLNA/AVTransport. One active session at a time.
  • breadcast — GTK4 Layer Shell popup. Thin IPC client of breadcastd: pick a device, start or stop a cast. Closing the popup does not interrupt an active session.

This is a bakery product. It is not shipped on the BOS ISO and is not part of the default desktop — install it yourself if you want it.

Install

bakery install breadcast

That puts breadcast and breadcastd on $PATH (usually ~/.local/bin), installs contrib/breadcastd.service as a systemd user unit, enables it, and starts the daemon. bakery doctor breadcast checks the system packages listed in bakery.toml first.

Requirements

  • A Wayland compositor with Layer Shell and xdg-desktop-portal ScreenCast (Hyprland is the primary target)
  • GTK 4.12+ and gtk4-layer-shell
  • GStreamer plus gst-plugin-pipewire, gst-plugins-bad, gst-plugin-va (vah264enc), and gst-plugin-hlssink3
  • jsoncpp and openssl (runtime deps of the vendored Cast Streaming code)

From source you also need a Rust toolchain (edition 2021).

Build from source

git clone https://git.breadway.dev/Breadway/breadcast
cd breadcast
cargo build --release

Binaries land at target/release/breadcast and target/release/breadcastd.

cp target/release/breadcast target/release/breadcastd ~/.local/bin/
cp contrib/breadcastd.service ~/.config/systemd/user/
systemctl --user daemon-reload
systemctl --user enable --now breadcastd

Usage

Start the daemon (or let the systemd unit handle it):

breadcastd

Open the device picker:

breadcast

Running breadcast again while it is open closes it (toggle). Click a device to start mirroring — the portal picker asks which screen to share. Stop mirroring ends the session. Status is Idle or Casting.

Discovery examples (optional, for debugging the LAN):

cargo run -p breadcast-core --example discover
cargo run -p breadcast-core --example dlna_discover

Hyprland keybind

On stock Hyprland, add the contents of contrib/hyprland.conf to your hyprland.conf if you want Super+C and the frosted-glass blur:

layerrule = blur, breadcast
layerrule = ignorezero, breadcast

bind = $mainMod, C, exec, breadcast

BOS does not ship this app or a default keybind for it. Add one yourself if you install breadcast on a BOS machine.

bread event integration

breadcastd works the same with or without breadd. When breadd is running, it publishes bread.cast.* and honors bread.command.cast.*. See EVENTS.md for the bus contract. bread is not a bakery dependency.

Theming

breadcast inherits its colour palette from bread-theme.