Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
Real World WebRTC
Search
Eric Schoffstall
March 02, 2016
Programming
0
46
Real World WebRTC
Given at dot.js in Paris, 2015
Eric Schoffstall
March 02, 2016
Tweet
Share
More Decks by Eric Schoffstall
See All by Eric Schoffstall
CoffeeScript 101
contra
3
220
Websocket Messaging Patterns
contra
4
1.6k
Warlock : DSTM via Websockets
contra
1
130
Other Decks in Programming
See All in Programming
Deoptimization: How YJIT Speeds Up Ruby by Slowing Down / RubyKaigi 2025
k0kubun
0
500
新しいPHP拡張モジュールインストール方法「PHP Installer for Extensions (PIE)」を使ってみよう!
cocoeyes02
0
340
趣味全開のAITuber開発
kokushin
0
190
Defying Front-End Inertia: Inertia.js on Rails
skryukov
0
460
Qiita Bash
mercury_dev0517
1
190
Chrome Extension Techniques from Hell
moznion
1
160
Vibe Codingをせずに Clineを使っている
watany
17
6.1k
Coding Experience Cpp vs Csharp - meetup app osaka@9
harukasao
0
730
Devinのメモリ活用の学びを自社サービスにどう組み込むか?
itarutomy
0
2.1k
Ruby's Line Breaks
yui_knk
2
480
国漢文混用体からHolloまで
minhee
1
170
php-fpm がリクエスト処理する仕組みを追う / Tracing-How-php-fpm-Handles-Requests
shin1x1
5
2.9k
Featured
See All Featured
"I'm Feeling Lucky" - Building Great Search Experiences for Today's Users (#IAC19)
danielanewman
227
22k
Raft: Consensus for Rubyists
vanstee
137
6.9k
Adopting Sorbet at Scale
ufuk
76
9.3k
Into the Great Unknown - MozCon
thekraken
37
1.7k
The Art of Programming - Codeland 2020
erikaheidi
53
13k
Performance Is Good for Brains [We Love Speed 2024]
tammyeverts
9
740
The Success of Rails: Ensuring Growth for the Next 100 Years
eileencodes
45
7.2k
Rebuilding a faster, lazier Slack
samanthasiow
80
8.9k
Rails Girls Zürich Keynote
gr2m
94
13k
Java REST API Framework Comparison - PWX 2021
mraible
30
8.5k
GraphQLとの向き合い方2022年版
quramy
46
14k
Scaling GitHub
holman
459
140k
Transcript
Real World WebRTC
WebRTC
WebRTC is rad
WebRTC is cheap
WebRTC is cutting-edge
WebRTC is difficult
WebRTC is difficult Adapters? Plugins? Polyfills? Native? Prefixes? Extensions?
High Level
Camera Access
navigator.getUserMedia
var opt = {video: true}; navigator.getUserMedia(opt, onSuccess, onError);
var opt = {video: true, audio: true}; navigator.getUserMedia(opt, onSuccess, onError);
getUserMedia(opt, onSuccess, onError);
element.srcObject = stream;
codepen.io/contra/full/eyjgf (PLEASE MUTE)
P2P
PeerConnection
PeerConnection - Offer var pc = new PeerConnection(); pc.addStream(stream); pc.createOffer(function(offer)
{ var sdp = new SessionDescription(offer); pc.setLocalDescription(sdp, function() { // TODO: send to other user }); });
PeerConnection - Answer var pc = new PeerConnection(); pc.addStream(stream); var
offer = new SessionDescription(msg); pc.setRemoteDescription(offer, function() { pc.createAnswer(function(answer) { var sdp = new SessionDescription(answer); pc.setLocalDescription(sdp, function() { // TODO: send to other user }); }); });
DataChannel
DataChannel var dataChannel = pc.createDataChannel('cool-stuff'); dataChannel.onopen = function() { dataChannel.send('yo
sup'); };
DataChannel TCP UDP SCTP Reliability reliable unreliable configurable Delivery ordered
unordered configurable Transmission byte-oriented message-oriented message-oriented Flow Control yes no yes
Making a Real Product
Initial Prototype
"Oops" Realization
Do we need to?
Do we need to? YES
Android
Android <3 Crosswalk
iOS
iOS <3 iosrtc
iOS <3 iosrtc
IE/Safari
IE/Safari <3 Temasys
RTC Everywhere
http://rtc.works
http://rtc.works Chrom e Firefox Safari IE Android Edge iOS Node.js
None
None
None
None
None