Inglourious Coder

A Coder's work is never done.

GSoC 2014 Ultimate Glory - Flumotion ported

August 22, 2014 | permalink

These past few months have been one hell of a ride. The official GSoC period is over and I thought I should post about what I achieved in this time.

The Project

Flumotion is a streaming media server based on GStreamer and Twisted. It allows broadcasters and companies to stream content live and on demand in all the leading formats from a single server. This end-to-end yet modular solution includes signal acquisition, encoding, multi-format transcoding and streaming of contents.

GStreamer has now moved to version 1.2.4, and version 0.10 is no longer being maintained. Some core functionality has changed for newer Twisted as well. So, this was preventing Flumotion and consequently streaming system to run on anything newer than Ubuntu 12.04 Precise. The goal of my project was to port Flumotion to Gstreamer-1.x API and fix the Twisted functionality so that it would work on latest operating system. By the end of these amazing 3 months, I am able to run Flumotion on Ubuntu 14.04 Trusty and create test streams that work as they should. There need to be some improvements which I will be working on even after GSoC ends.

The Outcome

I was able to port the existing code to use the latest Gstreamer and hence run Flumotion successfully on Ubuntu 14.04 Trusty. Flumotion now uses Gstreamer 1.2.4 which, being the latest version, has brought significant improvements for:

  • Embedded processors support, lower power consumption, offloading work to specialized hardware units (such as DSPs)
  • Hardware accelerated video decoding/encoding using GPUs
  • Zero-copy memory management (avoiding unnecessary roundtrips between the CPU and GPU) for better performance and lower power consumption
  • Dynamic pipelines
  • API and code cleanups

Beyond the technical improvements, the 1.x series is also defined by a new release versioning scheme. As the GStreamer roadmap explains, all 1.x.y versions carry a -1.0 API version suffix and have a stable API/ABI. The API/ABI can only be broken by a new major release series (ie: 2.x); however, there are currently no plans for a 2.0 release series. Until then, the new version 1.2.3 will be a stable version.

This will help various users of Flumotion, providing them a more up-to-date, stable and feature-rich software.

The code could be found in my Github repo. There are still a few issues and a lot of improvements required. You are welcome to contribute :)

The Organization

My project was under the organization TimVideos.us, whose goal is to reduce the costs and expertise required to produce live streaming events to near zero so that everyone has the ability to record and host live conferences, meetings and presentations with remote participants across the globe. There exists a set of exciting projects which together create a system for accomplishing this task. Following is the overall structure of the system:

TimVideos.US overall Diagram

One of these projects is the streaming-system which comprises of a django website and Flumotion for collecting, encoding and streaming videos. Following is a diagram depicting the streaming system:

Streaming System overall Diagram

Previous