SlideShare a Scribd company logo
HIGH QUALITY LIVE BROADCASTING WITH
PHP
by Martin de Keijzer
PHP Limburg BE - July 27, 2016
A presentation by Martin de Keijzer
ABOUT ME
Martin de Keijzer
Dutch web developer
Working @ Spinnin' Records
PHPBenelux Board Member
@Martin1982
http://www.martindekeijzer.nl
High quality live broadcasting with PHP 27 07-2016
A presentation by Martin de Keijzer
We digital
A presentation by Martin de Keijzer
TODAY
LIVE STREAMING
Why and when?
A presentation by Martin de Keijzer
LIVING ONTHE EDGE
Live streaming is all about bringing the latest and greatest
A presentation by Martin de Keijzer
VIRTUAL PRESENCE
A presentation by Martin de Keijzer
DIRECT FEEDBACK
Every modern live streaming service has a chat for direct feedback
A presentation by Martin de Keijzer
LIKE INTHE OLD DAYS
A presentation by Martin de Keijzer
BENEFITS AND USAGES
• More followers
• Create hype
• Product presentations
• Screencasts
THE SPINNIN' HISTORY
Why the tech dept. stepped in
A presentation by Martin de Keijzer
SPINNIN' SESSIONS
Weekly premiere onTwitch
A presentation by Martin de Keijzer
THETECHNOLOGY
A presentation by Martin de Keijzer
THETECHNOLOGY
Ingredient 1;An MP4 file
A presentation by Martin de Keijzer
THETECHNOLOGY
Ingredient 2:An old Windows desktop
A presentation by Martin de Keijzer
THETECHNOLOGY
Ingredient 3: Open Broadcaster Software
A presentation by Martin de Keijzer
THETECHNOLOGY
Ingredient 4:A human being at the controls
A presentation by Martin de Keijzer
THETECHNOLOGY
What could possibly go wrong?
A presentation by Martin de Keijzer
THE RESULT
A presentation by Martin de Keijzer
THE RESULT
The good: People were eager to hear the radio show early
A presentation by Martin de Keijzer
THE RESULT
The bad: We were struggling with technology to deliver on time
A presentation by Martin de Keijzer
THE RESULT
The ugly: Jenny got frustrated by technology issues and viewers
start complaining in chat
A presentation by Martin de Keijzer
OTHER COMPLICATIONS
Bandwidth when sending a stream to multiple social networks
A presentation by Martin de Keijzer
OTHER COMPLICATIONS
Power outages
A presentation by Martin de Keijzer
OTHER COMPLICATIONS
Technical knowledge about accepted stream settings
A presentation by Martin de Keijzer
OTHER COMPLICATIONS
Manually starting streams for timezone targeting
LIVE BROADCAST BUNDLE
The path to salvation
A presentation by Martin de Keijzer
GET ITTODAY
Demo project:
git clone git@github.com:Martin1982/live-broadcast-demo.git
Runs with SQLite / Local php server
A presentation by Martin de Keijzer
SUPPORT
A presentation by Martin de Keijzer
GET ITTODAY
composer require martin1982/live-broadcast-bundle
Just the bundle:
Still in alpha; we release early & often
A presentation by Martin de Keijzer
HIGH LEVEL OVERVIEW
Input



File
Url
RTMP
Processing


Database
FFMPEG
OS PID's
Twitch
Facebook
Youtube
Twitch
Outputs
INSIDETHE BUNDLE
Created for extensibility
A presentation by Martin de Keijzer
SCHEDULER
• Retrieves the LiveBroadcast entities
• Checks running broadcasts
• Decides to start/stop or leave a broadcast
alone
A presentation by Martin de Keijzer
I/O STREAM SERVICES
Converts the Input and Channel entities to input and output
parameters for FFMpeg
A presentation by Martin de Keijzer
ENTITIES
Input
One of File / URL or RTMP
LiveBroadcast
Title, description,

Start & end time,
Stop stream when end time is reached
Channel
Facebook
YouTube
Twitch
A presentation by Martin de Keijzer
INPUT
File
Local file location
For prerecorded video
A presentation by Martin de Keijzer
INPUT
Direct url location for prerecorded video
URL
A presentation by Martin de Keijzer
INPUT
RTMP

(soon)
Live video input protocol
Great for broadcasting to multiple channels from
a lower bandwidth location.
A presentation by Martin de Keijzer
INPUT DEEP-DIVE
A presentation by Martin de Keijzer
PROCESSING
Database
Is being visited by the scheduler to see
if a broadcast needs to run or stop
The core command for reading input media
and sending it to one of the output channels
FFMPEG
OS
Process list is being checked by the scheduler
to see which broadcasts from the bundle are running
and what their PID's are
A presentation by Martin de Keijzer
OUTPUT
Twitch
Configurable with a stream key from theTwitch
dashboard
A presentation by Martin de Keijzer
OUTPUT
Needs a reviewed Facebook app to run
and allow API calls
Facebook
A presentation by Martin de Keijzer
OUTPUT
YouTube
(in active development)
Needs to authenticate an app for doing
API calls
A presentation by Martin de Keijzer
OUTPUT
Your channel
Needs to be coded by you
A presentation by Martin de Keijzer
OUTPUT ENTITY
A presentation by Martin de Keijzer
OUTPUT SERVICE
A presentation by Martin de Keijzer
BONUS:ADMIN
Spinnin' uses Sonata, so we added it as a bonus and a full
setup in a demo project which you can use to test-drive
the application
THE ROAD AHEAD
Current and future goals
A presentation by Martin de Keijzer
MORE INPUTS
Mainly RTMP, as easy and functional as possible
Ideas are going around to combine graphic layers to a single
video stream output
A presentation by Martin de Keijzer
MORE CHANNELS
YouTube Live streaming is high on the priority list.
A presentation by Martin de Keijzer
MORE QUALITY
Firmly tested code, good documentation and easier implementation.
A presentation by Martin de Keijzer
IN CONCLUSION
Live broadcasting on a professional level is hard
Bandwidth may be your enemy on remote locations
Broadcasting consists of input, processing and output
Twitch and Facebook are already there, withYoutube soon to follow
More inputs will be added shortly
Spinnin' Records invested time and resources to give this
away for free, when fixing or adding stuff a PR is much appreciated
A presentation by Martin de Keijzer
LIVE DEMOTIME?
A presentation by Martin de Keijzer
Thank you for listening,
any questions?

More Related Content

PDF
Productive & easy mobile app dev
PDF
tiCONF Amsterdam 2014 building mobile teams
PPTX
One ASP.Net - 4 frameworks, one project
PDF
WebRTC Live Q&A Session #4 - WebRTC in WebKit and the story around Apple and ...
PDF
Building Powerful Applications with AngularJS 2 and TypeScript - David Giard
PDF
How We Make Unity
PDF
Ionic App Platform Overview
PDF
Build Infrastructure: What It Is, Why You Need It, and How to Use Python to F...
Productive & easy mobile app dev
tiCONF Amsterdam 2014 building mobile teams
One ASP.Net - 4 frameworks, one project
WebRTC Live Q&A Session #4 - WebRTC in WebKit and the story around Apple and ...
Building Powerful Applications with AngularJS 2 and TypeScript - David Giard
How We Make Unity
Ionic App Platform Overview
Build Infrastructure: What It Is, Why You Need It, and How to Use Python to F...

What's hot (20)

PDF
Getting Developers hooked on your API by Nicolas Garnier at Codemotion Dubai
PPT
Get More From Your Messages with Twilio + Watson Add-Ons
PDF
MuleSoft London Community March 2022 - CloudHub Automation
PDF
Capacitor 2.0 Launch
PDF
Ionic in 30
PDF
Ionic Native: Native-powered apps, without the hassle
PPTX
Stop Configuring Varnish and Start Coding (NAMER)
PPTX
Conversational Interfaces: The Future of Retail and Digital Engagement
PPTX
Enterprise git - the hard bits
PDF
Micro frontends Web component approach con VUEJS
PDF
MuleSoft London Community September 2020 - Project Vita
PDF
Open source for a successful business
PDF
DrupalConNA2021 - Accessibility throughout your project lifecycle - A case st...
PDF
MuleSoft Online Meetup - Salesforce Streaming APIs
PPTX
Digital Disruption: Big Bad Wolf or Fairy Godmother?
PDF
Building application in a "Microfrontends" way - Prasanna N Venkatesen *XConf...
PPTX
Documentation-driven development for Python web APIs
PPTX
Blockchain for Good
PPTX
Project : DuckPad
PDF
Capacitor 1.0 launch
Getting Developers hooked on your API by Nicolas Garnier at Codemotion Dubai
Get More From Your Messages with Twilio + Watson Add-Ons
MuleSoft London Community March 2022 - CloudHub Automation
Capacitor 2.0 Launch
Ionic in 30
Ionic Native: Native-powered apps, without the hassle
Stop Configuring Varnish and Start Coding (NAMER)
Conversational Interfaces: The Future of Retail and Digital Engagement
Enterprise git - the hard bits
Micro frontends Web component approach con VUEJS
MuleSoft London Community September 2020 - Project Vita
Open source for a successful business
DrupalConNA2021 - Accessibility throughout your project lifecycle - A case st...
MuleSoft Online Meetup - Salesforce Streaming APIs
Digital Disruption: Big Bad Wolf or Fairy Godmother?
Building application in a "Microfrontends" way - Prasanna N Venkatesen *XConf...
Documentation-driven development for Python web APIs
Blockchain for Good
Project : DuckPad
Capacitor 1.0 launch
Ad

Similar to High quality live broadcasting with PHP 27 07-2016 (20)

PPTX
Video production in the cloud for live streaming
PPTX
Sps Ottawa 2015: Give your company its own streaming video service with #o365...
PDF
Richcast general 2013 02
PPTX
Magic Engage V2 (3)
PDF
Introduction to Veeting.com - General Assembly 2014 of Bitcoin Association Sw...
PDF
ECS19 - Michael Greth - Best Practice with Company Video on Microsoft Stream
PDF
Best Practice with Microsoft Stream and Company Video
PPTX
Day One Keynote
PPTX
Cloud Based Video Production and Editing
KEY
Web2 Expo Presentation
PPTX
TechTalk: What's New with Perfecto?
PPTX
Day One Keynote
PPTX
Technoserve
KEY
Wordcampnl - Embed Mobypicture using shortcodes
PDF
Platform 4.0 Meetup Launch Event
PPTX
Remote Video Production as a Service?
PPT
Video For The Web
PPTX
Leveraging the Power of Streaming Video
PPTX
PTZOptics Newtek NDI Network Setup
PDF
DIY Transparent Release Management_2024_07.pdf
Video production in the cloud for live streaming
Sps Ottawa 2015: Give your company its own streaming video service with #o365...
Richcast general 2013 02
Magic Engage V2 (3)
Introduction to Veeting.com - General Assembly 2014 of Bitcoin Association Sw...
ECS19 - Michael Greth - Best Practice with Company Video on Microsoft Stream
Best Practice with Microsoft Stream and Company Video
Day One Keynote
Cloud Based Video Production and Editing
Web2 Expo Presentation
TechTalk: What's New with Perfecto?
Day One Keynote
Technoserve
Wordcampnl - Embed Mobypicture using shortcodes
Platform 4.0 Meetup Launch Event
Remote Video Production as a Service?
Video For The Web
Leveraging the Power of Streaming Video
PTZOptics Newtek NDI Network Setup
DIY Transparent Release Management_2024_07.pdf
Ad

More from Martin de Keijzer (17)

PDF
Native Javascript apps with PhoneGap 11-04-2014 Codemotion Rome
PDF
The Environment Restaurant
PDF
Introduction to PhoneGap and PhoneGap Build
PDF
Hybrid Mobile Web Apps with Sencha Touch 2
PDF
Native Javascript apps with PhoneGap
PDF
Mobile is everywhere
KEY
2012 11-01 Hackers & founders - Boot to the web, boot 2 gecko / Firefox OS
KEY
2012 09-04 smart devcon - sencha touch 2
KEY
2012 09-04 smart devcon - boot to the web, boot 2 gecko
PDF
Sencha Touch 2
PDF
Sencha Touch 2
PDF
Let's take over the world with Zend Framework
KEY
Improving code quality with continuous integration (PHPBenelux Conference 2011)
ODP
Improving code quality using CI
PDF
Continuous integration why and how? [DPC uncon quick-prep version]
ODP
Subversion In De Praktijk
ODP
Een introductie voor Phpunit
Native Javascript apps with PhoneGap 11-04-2014 Codemotion Rome
The Environment Restaurant
Introduction to PhoneGap and PhoneGap Build
Hybrid Mobile Web Apps with Sencha Touch 2
Native Javascript apps with PhoneGap
Mobile is everywhere
2012 11-01 Hackers & founders - Boot to the web, boot 2 gecko / Firefox OS
2012 09-04 smart devcon - sencha touch 2
2012 09-04 smart devcon - boot to the web, boot 2 gecko
Sencha Touch 2
Sencha Touch 2
Let's take over the world with Zend Framework
Improving code quality with continuous integration (PHPBenelux Conference 2011)
Improving code quality using CI
Continuous integration why and how? [DPC uncon quick-prep version]
Subversion In De Praktijk
Een introductie voor Phpunit

Recently uploaded (20)

PPT
Teaching material agriculture food technology
PPTX
A Presentation on Artificial Intelligence
PDF
The Rise and Fall of 3GPP – Time for a Sabbatical?
PPTX
Digital-Transformation-Roadmap-for-Companies.pptx
PPTX
Cloud computing and distributed systems.
PDF
Diabetes mellitus diagnosis method based random forest with bat algorithm
PPTX
MYSQL Presentation for SQL database connectivity
PDF
MIND Revenue Release Quarter 2 2025 Press Release
PDF
Assigned Numbers - 2025 - Bluetooth® Document
PDF
Build a system with the filesystem maintained by OSTree @ COSCUP 2025
PDF
Spectral efficient network and resource selection model in 5G networks
PDF
NewMind AI Weekly Chronicles - August'25-Week II
PDF
Agricultural_Statistics_at_a_Glance_2022_0.pdf
PPTX
sap open course for s4hana steps from ECC to s4
PPTX
20250228 LYD VKU AI Blended-Learning.pptx
PDF
TokAI - TikTok AI Agent : The First AI Application That Analyzes 10,000+ Vira...
PDF
7 ChatGPT Prompts to Help You Define Your Ideal Customer Profile.pdf
PPTX
KOM of Painting work and Equipment Insulation REV00 update 25-dec.pptx
PPTX
VMware vSphere Foundation How to Sell Presentation-Ver1.4-2-14-2024.pptx
PPT
“AI and Expert System Decision Support & Business Intelligence Systems”
Teaching material agriculture food technology
A Presentation on Artificial Intelligence
The Rise and Fall of 3GPP – Time for a Sabbatical?
Digital-Transformation-Roadmap-for-Companies.pptx
Cloud computing and distributed systems.
Diabetes mellitus diagnosis method based random forest with bat algorithm
MYSQL Presentation for SQL database connectivity
MIND Revenue Release Quarter 2 2025 Press Release
Assigned Numbers - 2025 - Bluetooth® Document
Build a system with the filesystem maintained by OSTree @ COSCUP 2025
Spectral efficient network and resource selection model in 5G networks
NewMind AI Weekly Chronicles - August'25-Week II
Agricultural_Statistics_at_a_Glance_2022_0.pdf
sap open course for s4hana steps from ECC to s4
20250228 LYD VKU AI Blended-Learning.pptx
TokAI - TikTok AI Agent : The First AI Application That Analyzes 10,000+ Vira...
7 ChatGPT Prompts to Help You Define Your Ideal Customer Profile.pdf
KOM of Painting work and Equipment Insulation REV00 update 25-dec.pptx
VMware vSphere Foundation How to Sell Presentation-Ver1.4-2-14-2024.pptx
“AI and Expert System Decision Support & Business Intelligence Systems”

High quality live broadcasting with PHP 27 07-2016

  • 1. HIGH QUALITY LIVE BROADCASTING WITH PHP by Martin de Keijzer PHP Limburg BE - July 27, 2016
  • 2. A presentation by Martin de Keijzer ABOUT ME Martin de Keijzer Dutch web developer Working @ Spinnin' Records PHPBenelux Board Member @Martin1982 http://www.martindekeijzer.nl
  • 4. A presentation by Martin de Keijzer We digital
  • 5. A presentation by Martin de Keijzer TODAY
  • 7. A presentation by Martin de Keijzer LIVING ONTHE EDGE Live streaming is all about bringing the latest and greatest
  • 8. A presentation by Martin de Keijzer VIRTUAL PRESENCE
  • 9. A presentation by Martin de Keijzer DIRECT FEEDBACK Every modern live streaming service has a chat for direct feedback
  • 10. A presentation by Martin de Keijzer LIKE INTHE OLD DAYS
  • 11. A presentation by Martin de Keijzer BENEFITS AND USAGES • More followers • Create hype • Product presentations • Screencasts
  • 12. THE SPINNIN' HISTORY Why the tech dept. stepped in
  • 13. A presentation by Martin de Keijzer SPINNIN' SESSIONS Weekly premiere onTwitch
  • 14. A presentation by Martin de Keijzer THETECHNOLOGY
  • 15. A presentation by Martin de Keijzer THETECHNOLOGY Ingredient 1;An MP4 file
  • 16. A presentation by Martin de Keijzer THETECHNOLOGY Ingredient 2:An old Windows desktop
  • 17. A presentation by Martin de Keijzer THETECHNOLOGY Ingredient 3: Open Broadcaster Software
  • 18. A presentation by Martin de Keijzer THETECHNOLOGY Ingredient 4:A human being at the controls
  • 19. A presentation by Martin de Keijzer THETECHNOLOGY What could possibly go wrong?
  • 20. A presentation by Martin de Keijzer THE RESULT
  • 21. A presentation by Martin de Keijzer THE RESULT The good: People were eager to hear the radio show early
  • 22. A presentation by Martin de Keijzer THE RESULT The bad: We were struggling with technology to deliver on time
  • 23. A presentation by Martin de Keijzer THE RESULT The ugly: Jenny got frustrated by technology issues and viewers start complaining in chat
  • 24. A presentation by Martin de Keijzer OTHER COMPLICATIONS Bandwidth when sending a stream to multiple social networks
  • 25. A presentation by Martin de Keijzer OTHER COMPLICATIONS Power outages
  • 26. A presentation by Martin de Keijzer OTHER COMPLICATIONS Technical knowledge about accepted stream settings
  • 27. A presentation by Martin de Keijzer OTHER COMPLICATIONS Manually starting streams for timezone targeting
  • 28. LIVE BROADCAST BUNDLE The path to salvation
  • 29. A presentation by Martin de Keijzer GET ITTODAY Demo project: git clone git@github.com:Martin1982/live-broadcast-demo.git Runs with SQLite / Local php server
  • 30. A presentation by Martin de Keijzer SUPPORT
  • 31. A presentation by Martin de Keijzer GET ITTODAY composer require martin1982/live-broadcast-bundle Just the bundle: Still in alpha; we release early & often
  • 32. A presentation by Martin de Keijzer HIGH LEVEL OVERVIEW Input
 
 File Url RTMP Processing 
 Database FFMPEG OS PID's Twitch Facebook Youtube Twitch Outputs
  • 34. A presentation by Martin de Keijzer SCHEDULER • Retrieves the LiveBroadcast entities • Checks running broadcasts • Decides to start/stop or leave a broadcast alone
  • 35. A presentation by Martin de Keijzer I/O STREAM SERVICES Converts the Input and Channel entities to input and output parameters for FFMpeg
  • 36. A presentation by Martin de Keijzer ENTITIES Input One of File / URL or RTMP LiveBroadcast Title, description,
 Start & end time, Stop stream when end time is reached Channel Facebook YouTube Twitch
  • 37. A presentation by Martin de Keijzer INPUT File Local file location For prerecorded video
  • 38. A presentation by Martin de Keijzer INPUT Direct url location for prerecorded video URL
  • 39. A presentation by Martin de Keijzer INPUT RTMP
 (soon) Live video input protocol Great for broadcasting to multiple channels from a lower bandwidth location.
  • 40. A presentation by Martin de Keijzer INPUT DEEP-DIVE
  • 41. A presentation by Martin de Keijzer PROCESSING Database Is being visited by the scheduler to see if a broadcast needs to run or stop The core command for reading input media and sending it to one of the output channels FFMPEG OS Process list is being checked by the scheduler to see which broadcasts from the bundle are running and what their PID's are
  • 42. A presentation by Martin de Keijzer OUTPUT Twitch Configurable with a stream key from theTwitch dashboard
  • 43. A presentation by Martin de Keijzer OUTPUT Needs a reviewed Facebook app to run and allow API calls Facebook
  • 44. A presentation by Martin de Keijzer OUTPUT YouTube (in active development) Needs to authenticate an app for doing API calls
  • 45. A presentation by Martin de Keijzer OUTPUT Your channel Needs to be coded by you
  • 46. A presentation by Martin de Keijzer OUTPUT ENTITY
  • 47. A presentation by Martin de Keijzer OUTPUT SERVICE
  • 48. A presentation by Martin de Keijzer BONUS:ADMIN Spinnin' uses Sonata, so we added it as a bonus and a full setup in a demo project which you can use to test-drive the application
  • 49. THE ROAD AHEAD Current and future goals
  • 50. A presentation by Martin de Keijzer MORE INPUTS Mainly RTMP, as easy and functional as possible Ideas are going around to combine graphic layers to a single video stream output
  • 51. A presentation by Martin de Keijzer MORE CHANNELS YouTube Live streaming is high on the priority list.
  • 52. A presentation by Martin de Keijzer MORE QUALITY Firmly tested code, good documentation and easier implementation.
  • 53. A presentation by Martin de Keijzer IN CONCLUSION Live broadcasting on a professional level is hard Bandwidth may be your enemy on remote locations Broadcasting consists of input, processing and output Twitch and Facebook are already there, withYoutube soon to follow More inputs will be added shortly Spinnin' Records invested time and resources to give this away for free, when fixing or adding stuff a PR is much appreciated
  • 54. A presentation by Martin de Keijzer LIVE DEMOTIME?
  • 55. A presentation by Martin de Keijzer Thank you for listening, any questions?