Youtube API - background play? cache? - caching

On a desktop browser (Chrome, Safari, Firefox, etc.) you can have several tabs open and have a Youtube video cached on every tab. You can playback those videos even if you dont have internet anymore (because they are cached) and also you can minimize the browser to work on other stuff (so you can listen to the audio but dont have the video open at the same time).
So my question is: can I develop an app for mobile devices, which can have Youtube videos playing in the background (multitask) and also be able to cache them, and play them offline afterwards?
I just want to do the same that a browser can do on a computer, but on an iPhone. *The Youtube API Terms os Service are not clear in this aspect.

The terms of service are here: https://developers.google.com/youtube/terms
"For the avoidance of doubt, Your API Client shall not be designed to cache YouTube audiovisual content."

Related

is there any way to play the video in safari browser

below are 2 video files uploaded in aws. it will play in chrome or firefox etc, but wont play in safari
https://s3.ap-south-1.amazonaws.com/apppreprod/Vid_637768063547139404.webm
https://s3.ap-south-1.amazonaws.com/apppreprod/Vid_637745132425435217.mp4
The issue is that safari wont play videos uploaded into blob storage like aws.
recomended solution is to save the video in other server and it will play in safari.
The two links you provide can be opened in other browsers. I tested it with an iPhone, and found that it could not be opened in the safari browser, but the other three-party iPhone browsers can. After checking the Apple official website, it is certain that the safari browser of the iPhone supports the MOV video format.
suggestion:
When uploading a video, the video can be converted and stored as needed

Can I Use Google Home To Automatically Chromecast My Own Content

I have a working "Action On Google" that we programmed.
I separately created a website that Chromecasts video (based on Google's sample code).
However, what I would REALLY like to have is speak to my Google Home, then automatically have content (ideally an image + audio, then a video right after) cast to the Chromecast.
Is this technically possible exclusively through the Google Home interaction?
Alternately, is there a way to cast image + audio at the same time through a website (and what code do I need to do so)?
Right there is no API for third-party developers to programmatically send content to a Chromecast.

Why does youtube video work fast on Chrome than firefox?

As a java UI & Backend developer for past 10 years, What surprises me is the following browser behavior :
Firefox : I click on a related video (youtube website) and it takes some time to figure out the video and then buffering starts for the video.
Chrome : I click on a related video (youtube website) and it starts as if it was already buffering or buffer ready. This is surprising as there is no delay.
(note: If you have a very fast connection, you may not notice it. Slow it down by some parallel network related activity and then experiment)
My Concern is : Is Chrome browser programmed to preload some data related to youtube related videos to give a faster experience?
Google owns youtube and it makes sense for doing so.
But doing so,seems weird. Its like unusual customization for a particular website from a sea of websites.
Anyone knows a thing or two about it?
I noticed that when you install firefox you have to install flash manually, while chrome does not require that, i think it comes with it, or does not use flash at all. It might have something to do with that..

How to detect if Safari power saver mode is enabled?

I'm experiencing issues with the YouTube player failing to load when the power save mode is enabled in Safari 6.1 and 7 on OSX. The issue doesn't happen if the youtube user is using the experimental HTML5 player, but it's still in beta and most people are still using the Flash player. The "disable plugins to save power" option is on by default in most new versions of Safari and this causes the YouTube iFrame API to enter an endless loop as it tries to initialize the player.
Is there any attribute on the window or navigator objects that would possibly indicate that the power save mode is enabled so that I can warn users?
This issue is semi-intentional. The Power Saver mode in Safari deliberately stops flash content. You can read more about it in this article.
If the flash content is 'front and centre' (within a 3000 x 3000 pixel boundary starting at the top left corner of the document) it should still play. So it may help, if the youtube video is off to the side of the page, to try and centre it. Apple says content will not play if it is in the margins (see this page under the Safari Power Saver heading).
Well i do not think there is any readable JS property to know that,
if so Apple would have a flawed design, and the Safari Users would get nagged to disable that mode, in order to have the web site working "properly" ...
What you could do of course is to try to make a server call on your web site via flash, and then try to read the changed session variable via JavaScript, then you would know ...

Remote Screen Sharing in realtime like SharedView, TeamViewer

What technologies would I need to know to write an app like the now defunct Microsoft SharedView or something like TeamViewer? Any way to do it with a browser and not need a client app?
I'm a .NET developer, but figure I'd need to know C++ or driver stuff?
How would you stream the users desktop to another user? How do you even capture it in realtime?
I can imagine how you could take screenshots of the desktop and transfer them, but how do you capture live video of the screen of application and stream it to another user.
There are many apps that do this: Skype, GotoMeeting, TeamViewer, SharedView, Citrix, logmein, etc. but I'd like to write my own.
How would I get this to work on Windows, tablets, droids, etc...?
The browser seems to be a good platform for this, but there are some limitations
1 - flash doesn't work at all on IOS, and is not widely available on android.
2- Webrtc works with chrome, firefox and opera on mac/pc/linux, and with firefox/chrome on android. There's librairies to use webrtc from an IOS native app(in objective C). Screen Sharing on the other hand only works with chrome (pc/mac/linux). There's a work in progress in firefox.
3- Installation of browser plugins will be hard if not impossible on various platforms, but it can open some possibility : on chrome and firefox you can make them with javascript. For example a javascript extention can share a tab in chrome.
Using javascript you can stream from a desktop to any other desktop / android.

Resources