Google Cast is a technology that enables multi-screen experiences, which allows users to send content from mobile devices and personal computers to their TVs. You can use the Google Cast Android API to add casting functionality to your Android app so users can view your app content on their big screens.
Questions tagged [android-cast-api]
40 questions
1
vote
0 answers
App crashing on MiniControllerFragment inflate
I have added MiniControllerFrament in XML of mainActivity, whenever the app launch it crashes with the below log (Testing this on Google Pixel 4a device)
2022-01-27 20:06:08.063 21050-21050/? E/AndroidRuntime:
at…

shrikant
- 11
- 2
1
vote
1 answer
How to load media from local storage to cast video to Android TV?
As from sample google casting-app we can cast video to Android TV via URL. I want to cast video from local storage. I have not found any solution yet.
Let me know if anyone have implemented…

AhmadHassan
- 13
- 4
1
vote
1 answer
How to fully disconnect from Cast device when using RemoteDisplayLocalService?
I am using Cast SDK v2 and RemoteDisplayLocalService to cast local content. In the onRouteUnselected function in MediaRouter.Callback, I stop the service with CastRemoteDisplayLocalService.stopService(). The receiver app stops; however, the system…

plátano plomo
- 1,672
- 1
- 18
- 26
1
vote
1 answer
How to cast a GLSurfaceView in Google Cast SDK v3?
I would like my sender app to cast a GLSurfaceView to the receiver app in real time. This is possible in SDK v2 using the Remote Display API. Does SDK v3 have a similar feature, or must I render the contents of the GLSurfaceView to a MediaCodec…

plátano plomo
- 1,672
- 1
- 18
- 26
1
vote
1 answer
Connect to Chromecast using Remote Display API with WiFi Direct
In the official android documentation it says - "With the remote display APIs, your sender app can now render directly to any Cast receiver, like a Chromecast". What does directly mean here? Does it mean no wifi media channel is required/i.e. the…
user3052023
1
vote
1 answer
Cast api cast button not visible
I am new to Android development and I am trying to use the Android's Cast API. To start I have cloned and used the CastHelloText demo app. But there should be a cast button in the ActionBar/ToolBar which is for some reason not visible. I haven't…
user3052023
1
vote
0 answers
Does the API provide controls for remote video playback?
I'm aware of MediaController, but as I understand, it is only good if you have the video playing in a VideoView.
I'm using the LG Connect SDK to play a video on a remote device and I'm able to implement the MediaController.MediaPlayerControl…

Zackline
- 804
- 1
- 9
- 28
1
vote
2 answers
Adding Dynamic Cast Button to Android Application
From the Google documentation about adding a Cast button, https://developers.google.com/cast/docs/android_sender#adding-the-cast-button , it seems like the option they provide is for us to add a static button to the Action Bar. That said, what would…

jensiepoo
- 571
- 3
- 9
- 26
1
vote
1 answer
Cast Youtube videos inside my Android app directly to Youtube (in chromecast or roku or tv)
I am building an Android app with my youtube videos. I want to add casting support to these videos within my app. I don't want to build separate receiver app in chromecast but want to just use the existing youtube receiver app in…

user2818257
- 121
- 1
- 8
1
vote
1 answer
Can a custom Android Media Route Provider appear in the Cast dropdown list?
Media Route Providers declare entities that can receive media, but it seems that they don't appear in the same list as Chromecast in applications like Netflix.
Is there a way for me to make a Media Route Provider that I can stream to from common…

user3761898
- 1,143
- 1
- 8
- 7
1
vote
1 answer
Googlecast Custom Layout
I'm planning to develop a googlecast application using android. But i'm wondering if we can use custom receiver that has a video and a layout that displays text from the android application, i have looked everywhere but i couldn't find anything…

Kosh
- 6,140
- 3
- 36
- 67
0
votes
0 answers
Unable to programmatically tint chromecast media router button drawable
I have a Toolbar on the Activity which includes cast icon.
class MyActivity : AppCompatActivity() {
override fun onCreate(savedInstanceState: Bundle?) {
super.onCreate(savedInstanceState)
CastManager.getInstance(this)
}
…

Renjith
- 3,457
- 5
- 46
- 67
0
votes
1 answer
Android Chrome Browser casting to Chromecast - if I unplug chromecast (or unplug network), then the Chrome Browser page crashes
I have replicated the issue on Chrome and Edge (on Android). Although don't appear to have the issue on Chrome and Edge (Windows). I have tried Chrome v83 and latest v98.0.4758.101 - same issue. I can successfully cast and disconnect.
However, if…
0
votes
1 answer
How to change color in the subtitle dialog of Chromecast android sender SDK?
I would like to change the color of options provided in subtitle selection dialog of cast sender SDK.
I have tried bunch of different things like,
- @color/white100
-

Nishant
- 101
- 10
0
votes
1 answer
Google Cast crash on stop casting
My custom sender application is crashing whenever I'm clicking 'STOP CASTING' on the cast-options menu in the app. The error I'm getting is:
java.lang.NullPointerException: Attempt to write to field 'java.lang.ref.WeakReference…

Kasper Rynning-Tønnesen
- 782
- 2
- 7
- 22