YouTubeAPI [Released]

YouTubeAPI

Get it: Unity Asset Store - The Best Assets for Game Making

YouTubeAPI is a lightweight plugin for using YouTube’s functionality inside Unity.

Features:

  • -Search for videos
  • -Set Max Results
  • -change relevance language
  • -Order videos by different filters
  • -Get Thumbnails
  • -Get video Duration
  • -Get video Description
  • -Get the video MP4 video link! (you can play it by Handheld.PlayFullScreenMovie or any other video playback, also 3rd party plugins like Easy Movie texture are supported)
  • -Uses Youtube Data API v3
  • -Two example scenes included!
  • -Get all available subtitle languages!
  • -Save subtitles as SRT as an file!
  • -Get subtitle SRT as an string!

Supported Platforms:
Windows, Mac, Linux, Android, IOS, WinPhone, BlackBerry

It is all written in C#, so it’s perfectly compatible with other native plugins!

API:
API

//Search for videos
YouTube.Search (YourSearchTerm,MaximalResults,YourApiKey,OrderBy)

OrderBy supports ordering results by:

relevance

viewCount

rating

date

title

videoCount

//Arrays which containing different data after search:
//Returns Titles Array from search
YouTube.Titles;

//Return YouTube IDs Array from search
YouTube.IDs;

//Return Thumb Links Array from search
YouTube.THLinks;

//Returns Description Array from search
YouTube.Description;

//Download Thumbs from THLinks and returns the array
YouTube.GetAllThumbs();

//returns an single thumbnail when passing in an valid video id
YouTube.GetSingleThumb (ThumbnailLink);

//returns the duration when passing in an valid video id
YouTube.GetDuration (YTVideoID, YourApiKey);

//Returns High Quality MP4 Link
YouTube.GetHighestQuality (YTVideoID);

//Returns Medium Quality MP4 Link
YouTube.GetMediumQuality (YTVideoID);

Example API Script:
API
Example APP(included):
Screen
[spoiler]



[/spoiler]

Faq:
Q: There other app alreay out, whats different in YouTubeAPI?
A: Lets Compare:
IYoutube offers you to get the mp4 link after passing an youtube link. But its missing many features like searching, description and so on. It does also only work on android/ios and uses native code that could cause issues with other plugins.

YouTube API V3 + YouTube Video Player: Almost same featureset, but this one requires an server site php script, which higher the risk of instability since it always have to comunicate with the php server. Also mine automatically filter protected videos. YouTube Video Player doesnt, it just throws an error.

Price: 15$
Get it: Unity Asset Store - The Best Assets for Game Making

Ive just cutted the price by 50%. It does only cost 15$ from now on! :slight_smile:

Can your plugin get youtube video caption srt?

Hi, currently not. But i can add it if youre interested!

Edit: Since it sounds like an realy usefull feature, im going to add it. Going to submit an update to the asset store in the next 2 days. If you buy it, just send me your invoice number and you get the updated one. So you dont have to wait for unity to aproove it the update!

Update v1.1.0 is now live!:

  • Added Subtitle API!
  • Get all available Subtitle languages
  • Save Subtitles as file!
  • Get Subtitle as string!

Get it: Unity Asset Store - The Best Assets for Game Making

2 Likes

Hi,

Does Youtube Data API v3 include insert function ?

Hi, what do you mean with insert? To upload an video? No currently not.

Does it need server site scripting (like php/MySQL) ? or does it work without any additional setups. I am not a technical person but an artist so I am just asking if it’s easy to use. I don’t see any documentation/user manual on your site.

Hi,
it does not need any server side script. The plugin is completetly written in c#, no php/sql or other server side things involved. Everything is running inside Unity3D.

Have a look at the example api on the asset store page. Il think its very easy to use. Anyway, if you encountering problems, since youre not an programmer, il gonna help you.

PS: New website is incoming, may take around 1-2 weeks.

I just purchased your product. I am trying to figure out something simple like how to display youtube search result thumbnails on a Game Object (cube). Your example is on a 2D canvas. But I would like to display it on a cube. Secondly I am using Easy Movie Texture but I don’t know how to use it with your product. An example or prefabs for both cases would be great. My ultimate goal is in fact to display thumbnails of a search results (5 videos) on a game object (cube). Once the displayed, the thumbnails can be clicked and selected video is played using the Easy Movie Texture.
Thanks in advance for your support.

Do you want the thumbnails to be on a cube? 5 thumbnails on 1 cube or for each video one cube? Thumbnail api returns an texture, you could just apply it to an cube, or any other gameobject.

For using Easy movie texture, just pass the mp4, returned by my plugin, link into easy movie textures Load function.

Il gonna prepare an example scene tommorow, so youre able to see how to use my plugin for your purpose!

Yes I want the thumbnails to be displayed on a surface gameObject (example cube) let’s say 5 in a row. So that the player can click on one of them and it will play a movie on another surface (big screen … also a cube or any game bject used as a display). This can be done via Easy movie texture but I need some examples of a prefab would be great.
I will be waiting for your example scene tomorrow. Thanks again for your support !!

PM!

I need a way for people in a game world to paste youtube url’s onto a game object and have the youtube video play on that object or another object in the 3d game world for them and their visitors to view. People will be logged in on pc’s and mac computers. Will this product do this?

My plugin does not provide an playback video texture engine. Its the youtube api only. If you have an playback solution for mp4 files, it will work. If not, then not.

I would like to use your plugin for my project but at first I want to take a look at the readme file. Could you send it to me?

Send the readme to your mail :slight_smile:

1 Like

Got it! Thanks a lot

Can you show me how to use with easy movie texture plis and how to get the .mp4 url i have a code for download but i can find that line

Hi,
i beliebe youre the one who send me the mail?
Thanks for buying, as said via mail, going to send ya an example tomorrow morning for how to use it with easy movie texture! :slight_smile: