Skip to content
This repository has been archived by the owner on May 28, 2022. It is now read-only.

experimental: Youtube Live Events Streaming #206

Closed
jonathanasdf opened this issue Sep 30, 2012 · 3 comments
Closed

experimental: Youtube Live Events Streaming #206

jonathanasdf opened this issue Sep 30, 2012 · 3 comments

Comments

@jonathanasdf
Copy link
Contributor

Add ability to stream to a Youtube Live Event.

@mcchong and I will try to tackle this during this UCOSP term. We haven't come up with the details of the design yet.

For reference:

@ghost ghost assigned jonathanasdf and mcchong Sep 30, 2012
@mcchong
Copy link
Contributor

mcchong commented Dec 1, 2012

'Step one' has been completed - an RTMP streaming plugin is implemented and appears to be working. The next steps will quite possibly be something like the following:

Acquire a Live Events enabled Youtube account, as well as a Developer key.

For the Youtube authentication, I am under the understanding that Mitchell was working on a youtube-uploader (however, since not much was done on the youtube-interface yet on our end, we haven’t looked into how the work could overlap, and from what I know now, I understand it’s part of the cli functionality). What we might want to include is a Youtube authentication UI, which takes the user’s username and pass, and retrieves an authentication token, which our app can use to perform api calls on the user’s behalf.

The user can then manage (create, update, start, end, delete) a live event. My initial thoughts were that, since a ‘live event’ is somewhat similar to a ‘presentation’, include live-event specific functionality into the talk editor. However, if that is not the case, perhaps a separate interface, which could provide a title, summary, and start time, could be built, and manage the live event separately.

The work that has been done was for the backend Youtube API interface. It has not been tested, but has been designed to build API requests, and send them (populating them with data from a ‘Presentation’ object, but this can be changed to be something more generic). Parsing API requests also still needs to be implemented, as well as some research and design into ‘CDN’ configuration, and whether it is necessary to have those settings accurate. More information can be found here [https://developers.google.com/youtube/2.0/developers_guide_protocol_managing_live_events].

The complete project proposal and documentation can be found here:
https://docs.google.com/document/d/1SYkEACGE8FDGqpRrI8cYmaJKgXNB2CZ_to745yvJB1Q/edit#

@mcchong
Copy link
Contributor

mcchong commented Dec 1, 2012

I had also considered opening up another issue for the following, but was unsure how to describe it, other than "rtmp streaming is a little messy" Here's the case (it's also documented in the doc above):

Currently, RTMP Streaming works only if you correctly set the video preview queue to leaky (and it's the only other output), or if you set tune=zerolatency for x264enc.

The options are configurable, but I don't know if there's a 'nicer' way to generalize this issue, maybe in core or something, or if we should just leave it as is.

zxiiro pushed a commit that referenced this issue Dec 2, 2012
NOT YET TESTED.  (this line will be removed from commit message when testing is complete)

Implemented get_output_bin function in RTMP Streaming plugin. Returns
a bin with video and audio sink pads, as necessary.  Uses flvmux to mux the audio/video streams, and add
metadata tags.  Uses x264enc to encode the video to x-h264 for flv.  Streams flv content to rtmp server at url provided by user.

Testing notes: TODO

Notes for review:
- I add the metadata tags to the flv stream using the flvmux element.
Currently, I'm not sure if that's the right way how to do it, and
need to look into how to verify it.
- I set the bitrate for the h264 encoder based on the value found
in the ogg-output plugin.
zxiiro pushed a commit that referenced this issue Dec 2, 2012
- This is necessary to get around an issue where the if 2 output
plugins are loaded at the same time, rtmp will freeze and not stream
anything.
zxiiro pushed a commit that referenced this issue Dec 2, 2012
Audio encoding is done with faac (bad plugin), to follow youtube's
encoding setting suggestions.  As well, video bitrate and audio
quality can be set by the user.
zxiiro pushed a commit that referenced this issue Dec 2, 2012
Added configureable setting to make the queue for the video preview
plugin leaky.  It is necessary to enable this when using rtmp streaming.
zxiiro pushed a commit that referenced this issue Dec 2, 2012
'tune' property is now configureable, used to set the property in
x264enc (see http://mewiki.project357.com/wiki/X264_Settings).
Also added a note about setting other outputs to be leaky when
using rtmp.  As well, added connecting signal to video quality
spinbox that was missing
zxiiro pushed a commit that referenced this issue Dec 2, 2012
Corrected changes to rtmp streaming, so that changes made using
the config widget take effect.  Also, commented out audio encoding
lines, until faac becomes available, or we decideo to use another
encoder or element to adjust audio quality.

(most of these need for fixes and the weird commit patterns were a result
of me doing development on my local machine, and testing on my vm,
and using git to transfer between the two.  I have since decided that
was a not-the-most-intelligent way of going about things.)
zxiiro added a commit that referenced this issue Dec 2, 2012
- Merges in Jonathan Shen & Mike Chong's work on rtmp-streaming
- There is still work that needs to be done per GH-206 before youtube
streamin functionality is complete.

#206
zxiiro pushed a commit that referenced this issue Feb 24, 2013
NOT YET TESTED.  (this line will be removed from commit message when testing is complete)

Implemented get_output_bin function in RTMP Streaming plugin. Returns
a bin with video and audio sink pads, as necessary.  Uses flvmux to mux the audio/video streams, and add
metadata tags.  Uses x264enc to encode the video to x-h264 for flv.  Streams flv content to rtmp server at url provided by user.

Testing notes: TODO

Notes for review:
- I add the metadata tags to the flv stream using the flvmux element.
Currently, I'm not sure if that's the right way how to do it, and
need to look into how to verify it.
- I set the bitrate for the h264 encoder based on the value found
in the ogg-output plugin.
zxiiro pushed a commit that referenced this issue Feb 24, 2013
- This is necessary to get around an issue where the if 2 output
plugins are loaded at the same time, rtmp will freeze and not stream
anything.
zxiiro pushed a commit that referenced this issue Feb 24, 2013
Audio encoding is done with faac (bad plugin), to follow youtube's
encoding setting suggestions.  As well, video bitrate and audio
quality can be set by the user.
zxiiro pushed a commit that referenced this issue Feb 24, 2013
Added configureable setting to make the queue for the video preview
plugin leaky.  It is necessary to enable this when using rtmp streaming.
zxiiro pushed a commit that referenced this issue Feb 24, 2013
'tune' property is now configureable, used to set the property in
x264enc (see http://mewiki.project357.com/wiki/X264_Settings).
Also added a note about setting other outputs to be leaky when
using rtmp.  As well, added connecting signal to video quality
spinbox that was missing
zxiiro pushed a commit that referenced this issue Feb 24, 2013
Corrected changes to rtmp streaming, so that changes made using
the config widget take effect.  Also, commented out audio encoding
lines, until faac becomes available, or we decideo to use another
encoder or element to adjust audio quality.

(most of these need for fixes and the weird commit patterns were a result
of me doing development on my local machine, and testing on my vm,
and using git to transfer between the two.  I have since decided that
was a not-the-most-intelligent way of going about things.)
@dideler
Copy link
Member

dideler commented Feb 12, 2014

Closing as duplicate. Continue any discussion in #439.

@dideler dideler closed this as completed Feb 12, 2014
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants