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
59
0
Share
Embed
Copy iframe code
Copy JS code
Copy link
Start on current slide
Real World WebRTC
Given at dot.js in Paris, 2015
Eric Schoffstall
March 02, 2016
More Decks by Eric Schoffstall
See All by Eric Schoffstall
CoffeeScript 101
contra
3
240
Websocket Messaging Patterns
contra
4
1.7k
Warlock : DSTM via Websockets
contra
1
160
Other Decks in Programming
See All in Programming
これって Effect でできたのでは? / TSKaigi Mashup Kansai #2
susisu
0
140
ルールを書いて終わらせないハーネスエンジニアリング
yug1224
4
1.8k
komatsuna「分散システムにおけるバグ分析手法」
komatsunaqa
0
180
ここ半年くらいでAIに作らせたR用ツール
eitsupi
0
360
Detecting Compromised CI with eBPF and Cilium Tetragon
lizrice
0
120
その節約、円になってますか?
isamumumu
1
670
Claude Team Plan導入・ガイド
tk3fftk
0
250
生成AI導入の「期待外れ」を乗り越える ー 開発フロー改革が目指す、真の組織変革
starfish719
0
3.7k
The Past, Present, and Future of Enterprise Java
ivargrimstad
0
510
言語を使う側から、作る側へ。 自作 Lisp で得た新たな気づき。
andpad
0
150
型も通る、synthも通る、それでも危ない 〜AIのCDKの権限とコストを機械で検証する〜 / It Passes Type Checks, It Passes Synth Checks, but It’s Still Risky — Automatically Verifying Permissions and Costs in AI’s CDK —
seike460
PRO
1
520
Claude Opus 4.6以後の受託開発エンジニアの変化(Claude Code開発ノウハウ大公開スペシャルbyクラスメソッド)
iidatakuma
1
950
Featured
See All Featured
Balancing Empowerment & Direction
lara
6
1.2k
Large-scale JavaScript Application Architecture
addyosmani
515
110k
First, design no harm
axbom
PRO
2
1.2k
Jess Joyce - The Pitfalls of Following Frameworks
techseoconnect
PRO
1
320
Learning to Love Humans: Emotional Interface Design
aarron
275
41k
Ethics towards AI in product and experience design
skipperchong
2
340
Avoiding the “Bad Training, Faster” Trap in the Age of AI
tmiket
0
200
The Invisible Side of Design
smashingmag
301
52k
Intergalactic Javascript Robots from Outer Space
tanoku
273
27k
Let's Do A Bunch of Simple Stuff to Make Websites Faster
chriscoyier
508
140k
Collaborative Software Design: How to facilitate domain modelling decisions
baasie
1
270
Save Time (by Creating Custom Rails Generators)
garrettdimon
PRO
32
4.1k
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