Learning WebRTC
eBook - ePub

Learning WebRTC

Dan Ristic

Share book
  1. 186 pages
  2. English
  3. ePUB (mobile friendly)
  4. Available on iOS & Android
eBook - ePub

Learning WebRTC

Dan Ristic

Book details
Book preview
Table of contents
Citations

Frequently asked questions

How do I cancel my subscription?
Simply head over to the account section in settings and click on ā€œCancel Subscriptionā€ - itā€™s as simple as that. After you cancel, your membership will stay active for the remainder of the time youā€™ve paid for. Learn more here.
Can/how do I download books?
At the moment all of our mobile-responsive ePub books are available to download via the app. Most of our PDFs are also available to download and we're working on making the final remaining ones downloadable now. Learn more here.
What is the difference between the pricing plans?
Both plans give you full access to the library and all of Perlegoā€™s features. The only differences are the price and subscription period: With the annual plan youā€™ll save around 30% compared to 12 months on the monthly plan.
What is Perlego?
We are an online textbook subscription service, where you can get access to an entire online library for less than the price of a single book per month. With over 1 million books across 1000+ topics, weā€™ve got you covered! Learn more here.
Do you support text-to-speech?
Look out for the read-aloud symbol on your next book to see if you can listen to it. The read-aloud tool reads text aloud for you, highlighting the text as it is being read. You can pause it, speed it up and slow it down. Learn more here.
Is Learning WebRTC an online PDF/ePUB?
Yes, you can access Learning WebRTC by Dan Ristic in PDF and/or ePUB format, as well as other popular books in Informatik & Webentwicklung. We have over one million books available in our catalogue for you to explore.

Information

Year
2015
ISBN
9781783983667
Edition
1

Learning WebRTC


Table of Contents

Learning WebRTC
Credits
About the Author
About the Reviewers
www.PacktPub.com
Support files, eBooks, discount offers, and more
Why subscribe?
Free access for Packt account holders
Preface
What this book covers
What you need for this book
Who this book is for
Conventions
Reader feedback
Customer support
Downloading the example code
Errata
Piracy
Questions
1. Getting Started with WebRTC
Audio and video communication today
Enabling audio and video on the Web
Camera and microphone capture
Encoding and decoding audio and video
Transportation layer
Session management
Creating web standards
Browser support
Compatibility with Chrome, Firefox, and Opera
Compatibility with Android OS
Compatibilty with Apple
Compatibility with Internet Explorer
Using WebRTC in your browser
Applications enabled by WebRTC
Self-test questions
Summary
2. Getting the User's Media
Getting access to media devices
Setting up a static server
Creating our first MediaStream page
Constraining the media stream
Constraining the video capture
Handling multiple devices
Creating a photo booth application
Modifying the media stream
Self-test questions
Summary
3. Creating a Basic WebRTC Application
Understanding UDP transport and real-time transfer
The WebRTC API
The RTCPeerConnection object
Signaling and negotiation
Session Description Protocol
Finding a clear route to another user
Session Traversal Utilities for NAT
Traversal Using Relays around NAT
Interactive Connectivity Establishment
Building a basic WebRTC application
Creating a RTCPeerConnection
Creating the SDP offer and response answer
Finding ICE candidates
Adding streams and polishing
Running your first WebRTC application
Self-test questions
Summary
4. Creating a Signaling Server
Building a signaling server
Setting up our environment
Getting a connection
Testing our server
Identifying users
Initiating a call
Answering a call
Handling ICE candidates
Hanging up a call
Complete signaling server
Signaling in the real world
The woes of WebSockets
Connecting with other services
XMPP
Session Initiation Protocol
Self-test questions
Summary
5. Connecting Clients Together
The client application
Setting up the page
Getting a connection
Logging in to the application
Starting a peer connection
Initiating a call
Inspecting the traffic
Hanging up a call
A complete WebRTC client
Improving the application
Self-test questions
Summary
6. Sending Data with WebRTC
Stream Control Transmission Protocol and data transportation
The RTCDataChannel object
Data channel options
Sending data
Encryption and security
Adding text-based chat
Use cases
Self-test questions
Summary
7. File Sharing
Getting a file with the File API
Setting up our page
Getting a reference to a file
Breaking down a file into chunks
Making chunks readable
Reading and sending the file
Putting it together on the other side
Showing progress to the user
Self-test questions
Summary
8. Advanced Security and Large-scale Optimization
Securing the signaling server
Using encryption
Using an OAuth provider
Supporting mobile devices
Introduction to mesh networking
Types of network meshes
Everyone to everyone
Star network
Partial mesh
Limits of mesh networking
Video conferencing with more users
The future of conference calls
Self-test questions
Summary
A. Answers to Self-test Questions
Chapter 1, Getting Started with WebRTC
Chapter 2, Getting the User's Media
Chapter 3, Creating a Basic WebRTC Application
Chapter 4, Creating a Signaling Server
Chapter 5, Connecting Clients Together
Chapter 6, Sending Data with WebRTC
Chapter 7, File Sharing
Chapter 8, Advanced Security and Large-scale Optimization
Index

Learning WebRTC

Copyright Ā© 2015 Packt Publishing
All rights reserved. No part of this book may be reproduced, stored in a retrieval system, or transmitted in any form or by any means, without the prior written permission of the publisher, except in the case of brief quotations embedded in critical articles or reviews.
Every effort has been made in the preparation of this book to ensure the accuracy of the information presented. However, the information contained in this book is sold without warranty, either express or implied. Neither the author, nor Packt Publishing, and its dealers and distributors will be held liable for any damages caused or alleged to be caused directly or indirectly by this book.
Packt Publishing has endeavored to provide trademark information about all of the companies and products mentioned in this book by the appropriate use of capitals. However, Packt Publishing cannot guarantee the accuracy of this information.
First published: June 2015
Production reference: 1250615
Published by Packt Publishing Ltd.
Livery Place
35 Livery Street
Birmingham B3 2PB, UK.
ISBN 978-1-78398-366-7
www.packtpub.com

Credits

Author
Dan Ristic
Reviewers
Roy Binux
Tsahi Levent-Levi
Andrii Sergiienko
Commissioning Editor
Andrew Duckworth
Acquisition Editor
Nikhil Karkal
Content Development Editor
Manasi Pandire
Technical Editor
Rahul C. Shah
Copy Editors
Sonia Michelle Cheema
Swati Priya
Neha Vyas
Project Coordinator
Bijal Patel
Proofreader
Safis Editing
Indexer
Monica Ajmera Mehta
Graphics
Disha Haria
Production Coordinator
Conidon Miranda
Cover Work
Conidon Miranda

About the Author

Dan Ristic is a frontend engineer and evangelist for Open Web. He strives to push the Web forward with new and creative ideas using the latest technologies. He attended the University of Advancing Technology, Arizona, where he furthered his engineering knowledge and fueled his passion for the Web. He has been writing applications on the Web ever since.
He currently lives and works in San Francisco as a senior software engineer at Sony Network Entertainment International. At Sony, he is responsible for managing the frontend application architecture and delivering the PlayStation Store to millions of users. In his free time, he can be found hiking, exploring, working on projects, and attending events.

About the Reviewers

Roy Binux is a software engineer and an open source developer. He focuses on information extraction and the Spider System at work and builds interesting things online for fun. He is open to new technologies and tries to make the process of getting knowledge from the Web easier and build something useful with the power of the Web. Most of his work is open source, and you can find him on GitHub at http://github.com/binux.
Tsahi Levent-Levi is an independent analyst and consultant for WebRTC.
He has 15 years of experience in telecommunications, VoIP, and the 3G industry as an engineer, manager, marketer, and CTO. He is an entrepreneur, independent analyst, and consultant and assists companies to form a bridge between technologies and business strategies in the domain of telecommunications.
He has an MSc degree in computer science and an MBA degree, with specialization in entrepreneurship and strategy. He has been granted three patents related to 3G-324M and VoIP. He was the chairman of various activity groups within IMTC, an organization focusing on the interoperability of multimedia communications.
He is also the author and editor of his blog https://bloggeek.me, which focuses on the ecosystem and business opportunities around WebRTC.
Andrii Sergiienko is an entrepreneur who is passionate about information technology and travelling. He has lived in different places, such as Ukraine, Russia, Belarus, Mongolia, Buryatia, and Siberiaā€”and has spent many years in every place. He also likes to travel by auto.
From his early childhood, he was interested in computer programming and hardware. He took his first step in these fields more than 20 years ago. He has experience working with a wide set of languages and technologies, including C, C++, Java, Assembler, Erlang, JavaScript, PHP, Riak, shell scripting, computer networks, security, and so on.
During his career, he has worked for both small ...

Table of contents