Reputation: 271
To play 360 videos from YouTube in my app, I integrated YouTube API. It plays normal video properly in its builtin YouTube player, but it doesn't support 360 videos. After so much digging, I use YouTubeStandalonePlayer to play 360 videos, but only work when I open that 360 video in light-box. Otherwise, when I set the light-box as false, it opens a full screen YouTube player, but the 360 videos stuck in there. It's just play for a second and get paused, same thing happen when we seek the video just to play for one second and get paused. Other YouTube API player does not play 360 videos properly.
Any suggestion will be helpful
Upvotes: 0
Views: 2638
Reputation: 1078
I'm using the youtube api already to stream live VR :
https://developers.google.com/youtube/v3/live/docs/liveBroadcasts#contentDetails.projection
check the object Livebroadcast object : you can specify : "rectangular" or "360"
NodeJs Example :
var start_date = new Date(Date.now() + (1000 /*sec*/ * 1 /*min*/ * 1 /*hour*/ * 1 /*day*/ * 1))
var youtube_broadcasts_body = {
snippet: {
"scheduledStartTime": start_date,
"title": "Live from StackOverflow"
},
status: {
"privacyStatus": "unlisted"
},
contentDetails: {
"projection": "360", <-------- this is for VR default is "rectangular"
}
}
var youtube_livebroadcast_params = {
part: "id,snippet,status, contentDetails",
resource: youtube_broadcasts_body
}
youtube.liveBroadcasts.insert(youtube_livebroadcast_params, callback)
Upvotes: 1
Reputation: 13469
By searching from the Internet, I found that YouTube has already roll out the support for 360 degree live streams and spatial audio. You can check it here. But by checking the Youtube API document, I cannot see any topics that are related now on the 360 videos. Also by checking other SO question, I only found this one, try to check it if it can help you.
Upvotes: 1