MediaHelpers
| Summary | A library used to retrieve video stream urls for use with the VideoPlayer class. |
|---|---|
| Description |
MediaHelpers A library used to retrieve video stream urls for use with the VideoPlayer class. How to use Add the following package to your game/addon: Make sure your class is and you're good to go! Here's some example code: public void PlayVideo(string url) { if(MediaHelper.IsYoutubeUrl(url)) { string streamUrl = MediaHelper.GetUrlFromYoutubeUrl(url); videoPlayer.Play(streamUrl); } else { videoPlayer.Play(url); } }MediaHelpers
A library used to retrieve video stream urls for use with the VideoPlayer class.
How to use
Add the following package to your game/addon:
Make sure your class is and you're good to go!
Here's some example code:
public void PlayVideo(string url)
{
if(MediaHelper.IsYoutubeUrl(url))
{
string streamUrl = MediaHelper.GetUrlFromYoutubeUrl(url);
videoPlayer.Play(streamUrl);
}
else
{
videoPlayer.Play(url);
}
}
|
| Votes | 10 0 15 |
| Error Rate | 0% |
| Usage |
8,943 players
16,770 sessions
4,159 hours playtime
15 minutes avg session
Totals captured
|
| Data | {} |