Google Cast Receiver Application Id property

Official Content
This documentation is valid for:
Enables media casting by using Google services.

Scope

Objects: Menu, Panel, Work With (Only Main Objects)
Generators: Android

Description

This property allows you to enable Google Cast support for media playback (audio in background, images, or videos), whose value must be the application identifier that runs on the Google Cast receiver device when casting from the application that has the property set.

How does it work?

When you set this property, the app is considered as a sender, showing the cast icon in the top right corner when a cast device is detected, and the end user can share media content with a receiver (e.g. Chromecast device connected to a TV).

GoogleCast - Cast icon

GoogleCast - Result

What is the Receiver Application Identifier?

The cast architecture has two main components:

  • Sender application - The application that shares its content with the cast device.
  • Receiver application - The application hosted on the cast device that receives content from the sender application.

GoogleCast - Application receiver and sender

The receiver is a particular web application executed in the cast device. Unlike a typical web application, the receiver is not identified by a URL. It uses a unique identifier provided by Android through its developer console when the application is registered.

There are three kinds of receivers:

  • Default Media Receiver - Provided by Google. It does not allow customizing its aspect and is used for testing purposes. Its identifier is CC1AD845.
  • Styled Media Receiver - It is a flexible version of the previous one, but only allows customizing the UI through CSS.
  • Custom Receiver - It allows customizing every aspect of the receiver using HTML, JavaScript, and CSS, and even allows you to create your protocol to communicate with the cast device.

For the last two receivers, you must get the identifier once you have registered it in the developer console.
Then you can enter this AppID in the GeneXus property, and your application is available to communicate with it.

Notes

  • For testing purposes, you can use the default media receiver application ID: 'CC1AD845'.
  • Styled Media and Custom receivers must be developed using the tools mentioned above. See examples and How to register it.
  • It can be helpful to follow this diagram to choose which receiver is more convenient for your application.
  • At the moment, it is only available for Android platform and Audio external object (including the Audio Player). It is highly recommended to set the ContentType and StreamType fields of the MediaItem SDT for the adequate management of resources by the receiver app and the cast device.

Run-time/Design-time

This property applies only at design-time.

How to apply changes

To apply the corresponding changes when the property value is configured, Build the Main Object.

Availability

This property is available since GeneXus 15.

See Also