WebRTC samples

This is a repository for client-side WebRTC code samples and the AppRTC video chat client. The source for these samples is available at github.com/GoogleChrome/webrtc.

Some of the samples use new browser features. They may only work in Chrome Canary and/or Firefox Beta, and may require flags to be set.

Most of the samples use adapter.js, a shim to insulate apps from spec changes and prefix differences. (In fact, the standards and protocols used for WebRTC implementations are highly stable, and there are only a few prefixed names. For full interop information, see webrtc.org/interop.)

Please note that all samples that use getUserMedia() must be run from a server. Calling getUserMedia() from a file:// URL will result in a PERMISSION_DENIED NavigatorUserMediaError.

For more information about WebRTC, we maintain a list of WebRTC Resources. If you've never worked with WebRTC, we recommend you start with the 2013 Google I/O WebRTC presentation.

Patches and issues welcome!

The demos

getUserMedia

Basic getUserMedia demo

Use getUserMedia with canvas

Use getUserMedia with canvas and CSS filters

Choose camera resolution

Choose camera and microphone

Audio-only getUserMedia() output to local audio element

Audio-only getUserMedia() displaying volume

Face tracking, using getUserMedia and canvas

RTCPeerConnection

Basic peer connection demo

Audio-only peer connection demo

Multiple peer connections at once

Forward the output of one PC into another

Munge SDP parameters

Use pranswer when setting up a peer connection

Constraints and stats

Display createOffer output for various scenarios

Use RTCDTMFSender

Display peer connection states

ICE candidate gathering from STUN/TURN servers

Web Audio output as input to peer connection

RTCDataChannel

Basic data channel demo

Video chat

AppRTC video chat client powered by Google App Engine

AppRTC URL parameters

Test pages

Audio and video streams

Constraints

Iframe apprtc

Iframe video

Multiple audio streams

Multiple peerconnections

Multiple video streams

Multiple video devices

Peer2peer

Peer2peer iframe

Single audio stream

Single video stream

github.com/GoogleChrome/webrtc