I am looking for a way to find all of the 360° videos from Youtube using Youtube APIs for my research. Currently I haven't been able to find this feature from the Youtube APIs, or hack a work-around using available API functions.
Search results on Yuotube webpage can be filtered by featureto just show the 360° videos among the search results. Even replicating this functionality using available API methods would be a good starting point to my needs. Maybe this could be accomplished by using snippet's tags, but I haven't been able to make it work.
(This question is quite similar ;-) to : Searching 360 degree videos using YouTube Data API? . But that question remains unanswered after 8 moths, even though Google Youtube Data API support page states: "We support the YouTube Data API on Stack Overflow. Google engineers monitor and answer questions with the youtube-api, youtube-data-api, and youtube-v3-api tags." As I just came across this problem, I hope the question gets some attention.)
I have been struggling with this problem as well and have used a combination of approaches with limited results:
First, we use this method and add a publishedBefore
filter for subsequent fresh searches (no pageToken
) of the oldest result we have found. This enables us to get more than the 1000 results youtube apparently limits you to.
Second we found good lots of good results for the query #360Video
, and we perform 2 sets of searches for that string: videoDimension: '2d'
and videoDimension: '3d'
. For all results, we query their contentDetails
and make filter out those who's contentDetails.projection
does not equal '360'. For good measure, we also do a '3d' dimension search without the query string.
Finally we combine all of the sets of results we retrieved. Unfortunately we do still seem to miss quite a few videos we spot test by hand. So far we have only been to query ~1000 videos. It seems like finding all 360 videos could require lots of manual work.
update: We have employed a manual step where we regularly scrape a list of user accounts, channels, and playlists with many 360 videos. This has yielded several hundred more videos at the least with, arguably, better quality. There might be a further step where we check all of the "recommended" videos for each of those videos and so on.
Well, I found in this thread that YouTube rolls out support for 360-degree live streams and spatial audio. And if you check the YouTube API documentation, there is no guide there that shows you how to use the 360 videos in YouTube.
So, YouTube 360 videos are not fully supported in YouTube API as of the moment. It is currently filed as a feature request that you can find here.
Hope it helps you.
来源:https://stackoverflow.com/questions/41888792/how-to-find-360-videos-using-youtube-data-api