SimpleWebRTC-master
所属分类:JavaScript/JQuery
开发工具:JavaScript
文件大小:7KB
下载次数:18
上传日期:2013-03-09 10:03:08
上 传 者:
kkpudn48a
说明: SimpleWebRTC.js封装了WebRTC技术的JavaScript,帮你简化WebRTC应用开发。
(The encapsulate WebRTC technology JavaScript SimpleWebRTC.js help you simplify WebRTC application development.)
文件列表:
index.html (3838, 2013-02-06)
package.json (190, 2013-02-06)
webrtc.js (13932, 2013-02-06)
# SimpleWebRTC - World's easiest WebRTC lib
Check out the demo: http://conversat.io
## It's so easy:
### 1. Some basic html
```html
```
### 1. Create our WebRTC object
```js
var webrtc = new WebRTC({
// the id/element dom element that will hold "our" video
localVideoEl: 'localVideo',
// the id/element dom element that will hold remote videos
remoteVideosEl: 'remotesVideos',
// immediately ask for camera access
autoRequestMedia: true
});
```
### 2. Tell it to join a room when ready
```js
// we have to wait until it's ready
webrtc.on('readyToCall', function () {
// you can name it anything
webrtc.joinRoom('your awesome room name');
});
```
近期下载者:
相关文件:
收藏者: