18

The docs are a little hard to parse here. I was wondering if there was any way to

  1. Stream YouTube live into an iOS app, without significant/any YouTube branding.
  2. Stream from an iOS device as a broadcast stream for YouTube live.

My initial Googling turned up mixed responses. I was hoping to see an example of this if it's possible, or save myself some time if it's not.

Suppose I have a person on ATT next to a person on Verizon streaming content, and I want to make both appear as a single uninterrupted stream switching back and forth. Does YouTube or a library do to anything to facilitate this?

JAL
  • 41,701
  • 23
  • 172
  • 300
Stefan Kendall
  • 66,414
  • 68
  • 253
  • 406
  • 1
    Periscope does live streaming, albeit proprietary. Pretty sure live stream *to* YouTube would work – ScottMcGready Sep 05 '15 at 22:42
  • 1
    Apps like Periscope and Meerkat send video to cloud services to transcode to a downstream format. YouTube live streaming currently only allows RTMP ingestion. The encoding could be done client-side or with cloud services. The downstream is handled by YouTube's end, as playback is restricted to a UIWebView. – JAL Sep 06 '15 at 20:35
  • you have to follow developer site and you no other way to stream live there is other ways but with that you have to code manually and it will too complex. – JAY RAPARKA Sep 15 '15 at 07:07

1 Answers1

15

Streaming from an iOS device is no different than streaming from any other device. You would have to write an h264 encoder and RTMP packetizer, and send the video to your YouTube stream object's ingestionAddress. Outlining the details of the encoder beyond the above is too broad for Stack Overflow, but I highly recommend looking at the VideoCore iOS project.

As far as branding goes, the only way to play back YouTube content in an iOS app without breaking YouTube's terms of service is to play the video in a UIWebView or YouTube's iOS player helper library (which is just a web view with some playback interfaces).

There is no way to completely remove YouTube branding from the IFrame player. However, there are branding options you can toggle using the modestBranding flag on the player. See the IFrame docs here.

JAL
  • 41,701
  • 23
  • 172
  • 300
  • 1
    Modest would be fine. VideoCore looks pretty intense. – Stefan Kendall Sep 07 '15 at 00:15
  • 1
    @StefanKendall I worked on a project that used VideoCore in conjunction with YouTube. I've also added some features to YouTube's iOS Player Helper to support live events. – JAL Sep 07 '15 at 23:41
  • 1
    do you have any idea how complex it is or what effort is required to sync youtube broadcasts? Suppose I have a person on ATT next to a person on Verizon streaming content, and I want to make both appear as a single uninterrupted stream switching back and forth. Does YouTube or videocore to anything to facilitate this? – Stefan Kendall Sep 08 '15 at 13:42
  • 1
    YouTube does provide a multi-camera interface for live events, but I've never used it and am not sure if it is even exposed as part of the API. – JAL Sep 08 '15 at 14:13