Skip to content
PepoBCNPublic

About

Free Mac app: YouTube as your wallpaper on every screen, with sound. Screensaver mode, hand-off back to Chrome.

Topics

Resources

Stars

0 stars

Watchers

0 watching

Forks

Latest commit

 

History

28 Commits

Folders and files

NameName
Last commit message
Last commit date
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

B-Side

A free Mac app that plays a YouTube video, playlist or mix as your desktop wallpaper, on every screen and every desktop, with sound. Switch it to screensaver mode to cover everything, or hand the video back to Chrome at the second it had reached.

Website · Download the latest release · macOS 13 or later · MIT licence

What it does

  1. Takes the YouTube video playing in Chrome (or a pasted link) and puts it behind every window on all your screens.
  2. Plays the sound from the main screen only. The other screens follow the main one: same video, same second.
  3. Screensaver mode covers every screen, menu bar and Dock included. A click, a key or a deliberate move of the mouse drops back to wallpaper. A small nudge does not.
  4. Back to Chrome reopens the video in a normal tab where it had got to, playlist included.
  5. Control panel: now playing with thumbnail, seek bar, previous, play and next, mute and volume, dim, fill or fit, all screens or main only, recents and settings.
  6. Pauses itself when the Mac locks or the displays sleep (and on battery, if you switch that on), then carries on.
  7. Skips still-picture tracks in playlists and mixes (audio uploads with one album cover or photo), and tells you when a whole mix is like that.
  8. Paste a video or playlist link at any time, including while something plays, to switch to it. ⌘V anywhere in the panel does the same.
  9. Keyboard shortcuts that work in any app. Watching something on YouTube in Chrome? Press ⌃⌥B and it moves to your desktop.
  10. Optional: screensaver after 2 to 15 minutes idle, resume the last video when the app opens, open at login.

Install

  1. Download B-Side.zip from Releases and unzip it.
  2. Drag B-Side into Applications and open it.
  3. macOS will say it can't check the app, because it isn't notarised by Apple. Go to System Settings > Privacy & Security, scroll down and click Open Anyway. You only do this once.
  4. The first time B-Side takes a video from Chrome, macOS asks whether it may control Google Chrome. Click Allow.
  5. For the keyboard shortcuts to work in other apps, macOS asks for Accessibility access. Click Open System Settings and switch on B-Side under Privacy & Security > Accessibility. The panel shows a reminder with a button until you do. B-Side picks it up straight away, no restart needed.

Optional: turn on Chrome's View > Developer > Allow JavaScript from Apple Events. B-Side can then pause YouTube in Chrome when it starts playing, and start from the exact second you were at. Going back to Chrome is always exact.

Using it

  1. Open B-Side. The control panel appears.
  2. With a YouTube video open in Chrome, press Play as wallpaper or Screensaver. Or paste a link.
  3. B-Side sits in the Dock while it runs. Click it, or open the app again, to bring the panel back. The ♫ menu bar icon does the same (if a menu bar manager such as Ice or Bartender hides it, drag it out of the hidden section).
  4. In the panel: Space play or pause, ← → change track, M mute, ↑ ↓ volume, ⌘W hide.
  5. Anywhere, in any app (switch off under Settings > Keyboard shortcuts):
Keys What it does
⌃⌥B If Chrome's front tab is a YouTube video or playlist, play it in B-Side (replacing whatever plays). Otherwise, if B-Side is playing, send it back to Chrome. Otherwise open the panel.
⌃⌥P Play or pause
⌃⌥→ ⌃⌥← Next or previous track
⌃⌥S Switch between wallpaper and screensaver
⌃⌥M Mute or unmute

Play and pause is ⌃⌥P because ⌃⌥Space already belongs to macOS (it switches keyboard input source). The keys go by position on the keyboard, so on a layout where B, P, S or M sit elsewhere, use the key where they are on a US keyboard. A window manager such as Rectangle uses ⌃⌥← and ⌃⌥→ by default; if it takes them first, change one of the two.

Mixes look best started from an official music video. A mix started from an audio upload is mostly still pictures, and B-Side only skips three in a row.

Terminal

bin/bside drives the app. Link it into your PATH, for example ln -s "$PWD/bin/bside" ~/.local/bin/bside.

bside                  open the control panel
bside on [screensaver] take the YouTube video open in Chrome
bside <youtube link>   play that link
bside off              back to Chrome at the same second
bside stop | quit      turn the wallpaper off | quit the app
bside pause|next|prev|mute|louder|quieter|wallpaper|screensaver|resume
bside status           what's playing, as JSON
bside vol 50 | dim 30 | screens all|main | fill on|off

Building from source

./build.sh              build and install to /Applications
./build.sh --no-install build into build/ only
./build.sh --release    build and zip into build/ with a SHA-256

Everything it needs ships with macOS: osacompile, PlistBuddy, qlmanage, sips, iconutil and codesign. No Xcode.

How it works

  1. src/engine.js is a JavaScript for Automation script compiled into a stay-open applet. It uses the Cocoa bridge to open one borderless window per screen at desktop level, each with a WKWebView running YouTube's own embed player.
  2. The main screen's player owns the playlist and the sound and reports its state (video, second, play state) once a second. The app tells the other screens' muted players to match. YouTube mixes reshuffle on every load, so this keeps every screen on the same track.
  3. Screensaver mode raises the same windows to screensaver level and puts a view on top that ends it on any input.
  4. src/panel.html is the control panel, a web page in a floating window with macOS vibrancy. Buttons post messages to the app through WKScriptMessageHandler, and the app pushes state back every second.
  5. The terminal tool sends the same commands over a distributed notification (bside.cmd).
  6. Keyboard shortcuts use NSEvent key monitors: a global one for keys pressed in other apps (that's what needs Accessibility access) and a local one for when B-Side is in front. Both send the same commands as the panel.
  7. The app is signed ad hoc with an identifier-only requirement, so macOS keeps the Chrome and Accessibility permissions across rebuilds.

Settings and recents live in ~/Library/Application Support/B-Side/state.json. Errors go to ~/Library/Logs/B-Side.log. Nothing is sent anywhere: no account, no analytics.

Limits

  1. Taking a video from the browser works with Chrome only for now.
  2. Some videos block playing outside YouTube. The panel says so and playlists skip on to the next track.
  3. The shortcuts can't be changed yet, and the app in front still sees the key press as well.

Licence

MIT. B-Side is not affiliated with, endorsed by or connected to YouTube or Google. Videos play through YouTube's own embed player and remain subject to YouTube's terms.

About

Free Mac app: YouTube as your wallpaper on every screen, with sound. Screensaver mode, hand-off back to Chrome.

Topics

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages