I am getting started with the youtube api but was wondering is a few things:
do i need to upload the video the youtube or can i just use it's
player?
if it does require me to upload to youtube, performance wise it
it better?
if i do upload to youtube can i make the videos private so they can
be viewed from my site only without being accessible through youtube
it self?
do i have limits on the number of videos i can upload, or the number
of playlists i can create?
can i get the video thumbnail using the api?
sorry if it appears random, thanks.
You have to upload it.
Assuming the clients are scattered around the world: yes, youtube will perform better than your own solution. If the clients are all within your building, on your network, then .. maybe. Depends on what you have hosting it, how many simultaneous and far more questions than is feasible to type out here.
More to the point on this one, if YouTube is serving the videos then you don't have to worry about that bandwidth coming from your server which may be important in terms of cost and bandwidth you need.
Yes. See https://developers.google.com/youtube/2.0/reference for some details about "authorized" requests.
The only limitations have to do with the length and size of the video. If you need videos longer than 15 minutes or 2GB then you need to request authorization. http://support.google.com/youtube/bin/answer.py?hl=en&answer=71673
See How do I get a YouTube video thumbnail from the YouTube API?
Related
I have recently purchased a Nest Camera (Wired, Indoor) today and I am wanting to stream it to Youtube so I can embed a live-feed into my website and so I can share the stream with my friends so I do not have to add them to the Google Home application and give them access to all devices.
I've seen the api documents for it, but I do not understand them. I found the API Documents on google's developer site (https://developers.google.com/nest/device-access/api/camera-wired#extend_a_live_stream), however I do not understand how this works, or how to complete it.
In my personal opinion, there should be a feature to stream it to a platform such as Youtube, such a feature would make things a lot easier for many people.
I have so far found no documents explaining how to do this except from the api documents.
There is no simple "out of the box" way to do this. You would need to setup some kind of device as an intermediary. One one side it would connect to the SDM API, open a stream, and start receiving the data. On the other side it would need to connect to the YouTube API (or equivalent) and pass the data through. Unfortunately you would need some degree of programming skill to engineer such as system.
Looking for some strategy here. We have a secure (subscription-based) website that points to another website for streaming video. Currently, a savvy user could potentially share the link to the streaming page thus bypassing the login. Looking for ideas on how to:
Prevent sharing the link
Cloak the link...or
Make the link from the origin page point to a dynamically-generated URL that can only be visited once.
Thanks in advance!
Unless there is a form of streaming the video from the third party to your application (by streaming I actually mean sending the video in chunks of data to your backend, assembling them back together, and serving the actual assembled video as if it was hosted directly on the same host as the web application, I have personally done this using Amazon S3 for my open-source subscription-based CMS called phpReel) I don't think you can securely do this.
If you do want to go down this route please note that it might get expensive if you have a lot of active subscriptions but if you are interested you could check out these files as they showcase how I have done it for phpReel. I am afraid though that you might need a developer for this job.
On a more optimistic note, may I ask what service do you actually use to stream your videos? For example, Vimeo with the cheapest paid plan offers an option that restricts access to your video outside a specific domain name. Meaning you can set that your videos must be streamed only on domain.com, and thus they will be accessible there and only there.
I want to:
play videos in my Xamarin Forms app (iOS + Android + UWP)
follow best practices and use maintained code
be able to secure my content (subscription based access)
if possible, style the transport controls to have a the same look and feel as my app
I found multiple ways that are possible, but not sure what is to be advised given my scenario:
Azure Media player
I found this talk that implied that it is best to use Azure Media Services to transcode your video to different qualities / formats so you can do Adaptive Bitrate Streaming, which means that depending on the quality of the connection and the device type, you will always have the "best possible" video on every type of device with the lowest bandwith usage. According to this talk this requires a "smart player" with the logic to do the switching between quality levels. In the talk the azure media player is mentioned as the go-to video player because it has support for Adaptive Bitrate Streaming (ABS) from azure media services.
It does not mention other players with ABS compatibility.
The transcoded video in the sample is played with Azure Media Player, which is hosted in a WebView. And since this talk was from 2018 and in a very recent release of Xamarin Forms (5.0) they have removed support for UIWebView and replaced it with WKWebView and I'm not sure if the WebView (and thus the video player) used in the sample is still supported / advised.
Custom Renderer
The Xamarin Forms documentation has a section "implementing a video player" where they give you a sample video player in the form of a custom renderer. I like that they allow you to style the transport controls yourself.
It is not mentioned if this video player has the same "smart switching" like the azure media player.
Use vimeo
With a paid subscription you can apperently secure the access your content. The styling of the player is limited, but maybe enough for my purposes. They do the content encoding / smart switching in the player for you. You pay a monthly fee, and have a limit on how many video minutes you can add each month, but no other bandwith / storage costs (as far as I can see).
Quick and dirty (naive?)
I can upload an mp4 to azure blob storage and use the customer renderer sample to playback the video directly from the blob.
This however would mean that there is no dynamic switching of video quality on the client and they would always consume "full bandwidth".
I am new to video transcoding / streaming.
Am I missing something in my analysis?
I would definitely go with option 2 because:
It's recommended by Xamarin and Microsoft.
It's free!
Taking adventage of the native implementation, you would be using the full potential of each platform and you can display videos from any source, local videos from the phone or the project or from YouTube, Vimeo, etc (as long as they are public videos).
Easy to use.
It's easy to customize because you handle the native code, that means you are in charge and not some WebView or someone else library.
I would discard the other options because:
Option 1 might be a good option, but you're consuming Azure and eventually it will cost you or your client money and use a WebView to display a video it's not very friendly from the UX point of view.
Options 3: I would definitely discard a paid solution if I have other options, specially if the other options are free.
Option 4 as same as before, you would be consuming Azure time and process, that lead you to lose money, if you want to upload a public video always upload to YouTube or some similar service, but as you said, consume the video from a native video player is the best option.
And by last, check this official sample, is more updated than the docs.
P.D: it's, custom renderer, not customer renderer ;-)
I have to implement a video collection website for users of a specific ISP. The site will be hosted on a public web-server but all the movies will be hosted on local ISP server. The user of that ISP + general visitors can see the available movies; but only ISP's users will be able to play them.
The player on site will point to URL of a local machine (http://192.x.x.x/movies/mymovie.mov) this private class (192.x.x.x) will only be accessible to ISP user.
Question: Is it possible with PHPMotion script? or I need to do custom work.
If possible, can someone please suggest available MODs?
PHPmotion would require some modifications to be able to handle something like this. Uploading, conversion, thumbnail generation, and playback are all pretty static in PHPmotion.
Really though, rather than modding the entire upload and conversion process, if you created a quick custom form to add entries to the PHPmotion database (maybe include thumbnail upload), then tweaked the playback paths, you should be good to go on the PHPmotion side of things. This would assume that you already had your videos in a format that the player could handle (such as flv or mp4).
I have an thing to create Internet shop to sell video views. And there are some rules, which I don't know how to do. The rules is:
Loggined client can only view one video 3 times per day.
I read somewhere that I need to generate virtual links to video and server must hold it, for example, 3 hours OR until client looked up to the end the video, and then delete this virtual link and refresh player state to "start video position and waiting for start". Like on youtube but client shouldn't have a way to rewind the video.
I need to hold situation that client who buy 'video01' give another client him page address or all attributes data from player tag. If second client don't buy 'video01' he shouldn't load it. (I think it's can be solved by cookies).
After 180 video views, client's subscription must be stopped.
And finally question from me is how to play video from my website? Can anyone explain me how to make asp.net site with rules that I wrote the above? What technology I need to use?
I will be grateful if someone advise me a literature that I need to read to know how to do this? Perhaps for a start I need to know how to play video on asp.net webpages.
What free flash player I should use for my solution, any examples please? Really need help.
P.S.: I need to use a free flash player to play videos, not silverlight.
The videos are on the remote servers, not on the local server where I hold the site.
To limit the video as per your requirement you need to use GenericHandlers in asp.net. It must be designed in such a way that the url must expire after reaching the above condition.
For Example, you can generate a random key that should append with the url (ie, QueryString) and store it in Database along with the time of generation. You can make the key expire after 3 hours then.
To play the video on your website you can add jQuery plugin videojs. The documentation will help you to add that simple HTML5+Flash video player.