Skip to content

drop-in client code for webrtc.io Highly experimental technology

Notifications You must be signed in to change notification settings

spiritwindy/webrtc.io-client

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

webrtc.io Build Status

A library that is to webRTC like socket.io is to WebSockets.

This will eventually be bundled with the server code.

Installation

Currently, webrtc.io depends on socket.io, so include the socket.io client as well. After including socket.io-client, drop in lib/io.js. You'll also need a webrtc.io server running.

Now you can start using webRTC commands with our abstraction.

Usage

rtc.createStream({"video": true, "audio":true}, function(stream){
  // get local stream for manipulation
}
rtc.connect('ws://yourserveraddress:8001', optionalRoom);
//then a bunch of callbacks are available

You can set the STUN server by calling rtc.SERVER = "STUN stun.l.google.com:19302" and set your server. The default STUN server used by the library is one from google.

授权

自由使用, 但不得用于商业用途以及 MIT 协议源码

About

drop-in client code for webrtc.io Highly experimental technology

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • JavaScript 100.0%