Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

UIActivityViewController - Upload Youtube Video

I have a UIActivityViewController I'm using to share a video, I'm passing an NSString of text and a NSUrl that points to a local mp4 video file.

Sharing already works for email, message, photo album, etc. How can I upload my video to Youtube as well?

Apple does this in the default Photos and Camera app if you try it there. Can I do it in my app as well?

like image 914
jonathanpeppers Avatar asked Feb 16 '13 22:02

jonathanpeppers


2 Answers

Apple only share some of the UIActivity that it uses in it's applications. That's likely because some are part of iOS while other are parts of the applications (different teams).

OTOH it's quite easy to add your own UIActivity to your application, e.g. see my AirPlay UIActivity that comes with a sample.

So if you can find a .NET YouTube client library then you should only need a bit of glue to connect them.

like image 99
poupou Avatar answered Nov 11 '22 01:11

poupou


Unfortunately, as per UIActivity class reference it is not included in iOS 6 (well, at least not in the public API).

You'll probably have to create your own UIActivity (just like here) and implement the youtube upload yourself.

Or hopefully there is a ready-made library that does so.

like image 41
Tomek Kopczuk Avatar answered Nov 11 '22 00:11

Tomek Kopczuk