Foliovision › Forums › FV Player › Troubleshooting › Change audiotrack in multilanguage video on Chromecast
-
Hello! I’m having issues playing hls streams on chromecast. After some testing seems that is a problem with the mime types. I’ll follow your document for fix it but, my question is: is possible to change audio track and subtitles on chromecast? This stream works fine with FV Player and Chromecast but I’m not been able to change tracks…
https://d2zihajmogu5jn.cloudfront.net/bipbop-advanced/bipbop_16x9_variant.m3u8
Thanks for your help!
-
-
Hi Gus,
Thank you for reporting the issue.
We tested the Chromecast with your stream in the latest version of Chrome – 87.0.4280.141 on Android 10, and we were able to reproduce the issue. The subtitles were synchronized with the video which played on the source device, but they didn’t show up on the screen to which the video was casted.
Could you please let us know on which device and browser you have experienced the issue? I’ll forward it to our development team to see what we can do about it.
Thanks,
ChiaraHi Chiara, thanks for answering me! I’ve tested in a Chromecast v1 reciever and in a Sony Bravia Smart TV with build in Chromecast. Is sent from a Chrome browser version 87.0.4280.141. I’m not able to change audio track. I’ve been researching on this topic for a while and seems that Flowplayer doesn’t support these features so FV Player neither…
If I’m in the right path is needed a Google Cast Sender App wich is the responsible of sending the active track into the reciever. I’m afraid that this issue wont be fixed by your team. Hope I’m wrong. Anyway I’m following Google Chromecast SDK examples trying to figure out if is possible some kind of easy fix.
Hello Gus,
I see the LoadRequest has a a way of obtianing the activeTrackIds: https://developers.google.com/cast/docs/reference/chrome/chrome.cast.media.LoadRequest#activeTrackIds So I would guess there is indeed a way of switching from one audio track to another.
I was able to find some code examples for subtitles, although these are 3-4 years old. But this bit of code looks good: https://gist.github.com/guerrerocarlos/3aca64069853d8d24a83b481246f23ca#file-chromecast_with_subtitles-html-L45-L57
Thanks,
MartinHello Gus,
I should be able to improve the FV Player Chromecast code next week.
What always puts me off when working with Chromecast is that there are some HLS streams which fail to cast with it for no apparent reason. For example https://playertest.longtailvideo.com/adaptive/bipbop/bipbop.m3u8 won’t work even when using JW Player: https://foliovision.com/support/fv-wordpress-flowplayer/bug-reports/detailederrorcode-315-on-casting-to-chromecast#post-126516
Thanks,
MartinHello Martin, I’ve just seen this answer. If you can fix it would be great.
For us having the option of changing the subtitles and language track is crucial. Almost all of our movies have 2 or 3 audio tracks and subtitles too.
I’ve been researching a little bit on how it can be done and seems that by adding an eventListener to the “fp-selected” class and sending the data-audio attribute through your Sender app is the way.
I’ve found a working example on the google CACToolv2 source code that may help you:
https://casttool.appspot.com/cactool/
If you look for this line in the source code you can find a working example:
document.getElementById(‘alternate-audio-button’).addEventListener(“click”, ()=>{…Would be great if this is fixed!! Thank you so much.
Hello,
I’ve created an hls stream that is able to cast on Chromecast but only works on one of my sites that has FV Player version 7.4.37.727. The same one is not working on other site with version 7.4.38.727.
This is the stream:
https://dusqglx8g3hsd.cloudfront.net/test_multia_audio_renditions_3/master.m3u8.
Both were using FV Player Pro 7.4.38.727.beta.
Now I’ve updated FV Player Pro into 7.4.39.727.beta in the site that was not working and I can’t see the Chromecast icon anymore…Hello Gus,
please post a link to your website where we can see that video playing.
Do you get the Chromecast icon on https://foliovision.com ?
Thanks,
MartinIs weird because the same stream on another cloudfront distribution does not work on Chromecast but if I try it on other test players is still working…
This is the other Cloudfront stream:
https://d1xudlldmrufp1.cloudfront.net/test_multia_audio_renditions_3/master.m3u8Hello Gus,
I see the issue with Chromecast not working in FV Player Pro 7.4.39.727. The issue is actually that FV Player 7.4.39.727 is not out yet as I dropped the ball there as I was waiting on some feedback. Sorry about that, will release that FV Player 7.4.39.727 next.
Thank you for the test video, it’s great for our work on audio channel switching!
Thanks,
MartinHello Gus,
FV Player 7.4.39.727 is out and it brings following improvements to Chromecast integration:
- Chromecast – retain playback position when enabling/disabling
- Chromecast – support replaying the video and playlists
- Chromecast – support switching of audio tracks in multiple audio track HLS streams
Thanks,
MartinHello Martin,
Thanks for this improvements!
I’m still having issues casting to Chromecast. Now I get the icon but the stream won’t play. FV Player and FV Player Pro have 7.4.39.727 version.
The same stream in FV Player 7.4.37.727 and FV Player Pro 7.4.38.727.beta is playable (the one I’ve shared with you)Hello Gus,
what Cloudfront settings did you change? Did you only disable the requirement of signed URLs and that was it? Could you please post the link to your test page?
Signed URLs should not stop Chromecast from working, but I see it could run into issues is the URL signature times out. I will test that out and feed the new URL with new singature into Chromecast when necessary. I hope it works, it’s getting quite complex that way.
We also need to handle subtitles.
Thanks,
MartinHello Martin,
What I did on Cloudfronts settings was enable/disable ipv6 but seems that has nothing to do.
This is my test page with the last version of FV Player and FV Player Pro:
https://play.adso.tv/movie/test-chromecast-fv-player/
It has Cloudfront signed url enabled. I’m not able to cast. The player gets hanged and sometimes crashes the browser.
Thanks,
GusHello Gus,
I’m running into the same issue on https://foliovision.com/player/demos/hls-stream – if the CDN hosting the HLS stream is set to require the URL tokens, then we serve the stream through our Stream Loader component of FV Player.
And unfortunately it seems like Chromecast doesn’t like it. It seems that it has a problem with the absolute paths in HLS m3u8 files. If that’s true then it’s a problem as we won’t be able to support playback of these HLS streams with URL token on Chromecast unless the CDN supports it natively (generate m3u8 files with URL tokens for video segment files).
I will test some other stream with the absolute URLs as I haven’t found any documentation regarding this.
Thanks,
MartinHello Gus,
making the video available for Chromecast does decrese its security. For the Signed URLs it requires these URLs to last for longer.
FV Player Pro encrypred videos currently do not play in Chromecast. We could add support, but it would open another channel for the decryption key.
I was trying to figure out why Stream Loader won’t work with Chromecast. I do not have the solution yet, but at least I was able to verify that the absolute segment URLs and query strings are not the issue.
Thanks,
MartinHello Gus,
to conclude this thread, the issue is with separate audio track HLS streams: https://foliovision.com/support/fv-wordpress-flowplayer/bug-reports/chromecast-2
Thanks,
Martin