Service: Chromecast Receiver - EyevinnOSC/community GitHub Wiki
Chromecast Receiver
Chromecast Receiver (serviceId eyevinn-cast-receiver) hosts a custom Cast receiver application that you configure with your own branding (logo, title, player styling) through options, with no code. It is a long-running service instance under the MIT license, built on the Google Cast Application Framework (CAF) SDK. Source: Eyevinn/cast-receiver.
What it can do
- Give your Chromecast integration a branded receiver without writing or deploying a custom receiver.
- Set the receiver title, splash logo and playback logo.
- Restyle the
cast-media-playerelement and pass advanced options to the Cast Receiver SDK.
Creating an instance
You need a registered Cast Application ID from the Google Cast SDK Developer Console, where you point your receiver URL to the OSC instance URL.
Call create-service-instance with serviceId: "eyevinn-cast-receiver":
{
"name": "myreceiver",
"title": "My Video App",
"logoUrl": "https://cdn.example.com/logo.png"
}
Wait for the instance to be running (wait-for-service-ready) and use describe-service-instance to get its URL.
CLI equivalent:
osc create eyevinn-cast-receiver myreceiver \
-o title="My Video App" \
-o logoUrl="https://cdn.example.com/logo.png"
Options
| Option | Required | Type | Meaning |
|---|---|---|---|
| name | Yes | string | Name of the instance. Alphanumeric, at most 20 characters. |
| title | Yes | string | Title of the application, shown on the receiver screen (TITLE). |
| castReceiverOptions | No | string | JSON string of options for the Cast receiver (CAST_RECEIVER_OPTIONS). Can override the recommended defaults; see the CastReceiverOptions reference. Advanced. |
| playbackLogoUrl | No | string | URL to the playback logo image (PLAYBACK_LOGO_IMAGE), shown during media playback. |
| logoUrl | No | string | URL to your logo image (LOGO), shown on the idle/splash screen. |
| castMediaPlayerStyle | No | string | Style for the cast-media-player element (CAST_MEDIA_PLAYER_STYLE), in the upstream format [style, value](/EyevinnOSC/community/wiki/style,-value), for example ["--splash-image", "url(https://example.com/logo.png)"], ["--splash-size", "contain"](/EyevinnOSC/community/wiki/"--splash-image",-"url(https://example.com/logo.png)"],-["--splash-size",-"contain"). May override other options that set style, such as logoUrl. |
Using the instance
- In the Google Cast SDK Developer Console, select your Cast application (or create one of type Custom Receiver).
- Set the Receiver Application URL to the OSC instance URL, then save and publish. It can take a few minutes for the Cast infrastructure to pick up the new URL.
- Cast content from a Cast-enabled sender app or the Chrome extension to a device registered to your Application ID. The branded receiver screen should show your title and logo.