Very WIP! Not ready for release. Expect many bugs. Please don't sign builds on AMO with current ID.
Credit:
- Linux
- macOS
- Windows (TODO)
Only tested on Linux and macOS. mDNS library issue to be fixed. mdns
only works on Windows, mdns-js
only works on Linux.
- NodeJS
node
binary in pathBonjour SDK (Windows)
git clone https://github.com/hensm/caster.git
npm install
npm run build
npm run install-manifest
Testing requires geckodriver (or chromedriver for Chrome parity testing). See selenium-webdriver installation instructions (ignore npm install
).
Chrome doesn't load the media router in a temporary selenium profile, so there's a bundled profile (test/ChromeProfile.zip
). Extract the folder within as test/ChromeProfile/
.
npm run build
npm test
SELENIUM_BROWSER=chrome npm test
Extension can be loaded from about:debugging
as a temporary extension.
Most sites won't load the cast API unless the browser presents itself as Chrome. The extension includes a method of spoofing the user agent string, sites can be whitelisted via the options page. Whitelist entries are specified as match patterns. To whitelist all sites, add <all_urls>
to the whitelist, though this could cause breakage on random sites.
HTML5 media elements have a "Cast..." context menu item that triggers a sender application. Only works on remote (non-local) media that isn't DRM-encumbered.
Cast-enabled websites will load the sender API shim and display a cast button as in Chrome, provided there are no bugs/incompatibilities with the shim.
Netflix / HTML5: