forked from webrtc/apprtc
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* Adds the required files for a chrome app * Add generates a random room id and connects
- Loading branch information
Showing
14 changed files
with
230 additions
and
12 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,51 @@ | ||
<!DOCTYPE html> | ||
<!-- | ||
* Copyright (c) 2014 The WebRTC project authors. All Rights Reserved. | ||
* | ||
* Use of this source code is governed by a BSD-style license | ||
* that can be found in the LICENSE file in the root of the source | ||
* tree. | ||
--> | ||
<html> | ||
|
||
<head> | ||
|
||
<title>WebRTC Reference App</title> | ||
|
||
<meta charset="utf-8"> | ||
<meta name="description" content="WebRTC reference app"> | ||
<meta name="viewport" content="width=device-width, user-scalable=no, initial-scale=1, maximum-scale=1"> | ||
<link rel="stylesheet" href="/css/main.css"> | ||
|
||
</head> | ||
|
||
<body> | ||
|
||
<div id="videos"> | ||
<video id="mini-video" autoplay muted></video> | ||
<canvas id="remote-canvas"></canvas> | ||
<video id="remote-video" autoplay></video> | ||
<video id="local-video" autoplay muted></video> | ||
</div> | ||
|
||
<footer id="footer"> | ||
<div id="sharing"> | ||
<div>Waiting for someone to join this room: <a id="room-link" href="" target="_blank"></a></div> | ||
</div> | ||
<div id="info"></div> | ||
<div id="status"></div> | ||
</footer> | ||
|
||
<script src="/js/stats.js"></script> | ||
<!-- {{ include_loopback_js }} --> | ||
<script src="/js/signaling.js"></script> | ||
<script src="/js/infobox.js"></script> | ||
<script src="/js/sdputils.js"></script> | ||
<script src="/js/util.js"></script> | ||
<script src="/js/main.js"></script> | ||
<!-- {{ include_vr_js }} --> | ||
<script src="/js/adapter.js"></script> | ||
<script src="/js/appwindow.js"></script> | ||
|
||
</body> | ||
</html> |
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,75 @@ | ||
/* | ||
* Copyright (c) 2014 The WebRTC project authors. All Rights Reserved. | ||
* | ||
* Use of this source code is governed by a BSD-style license | ||
* that can be found in the LICENSE file in the root of the source | ||
* tree. | ||
*/ | ||
|
||
/* More information about these options at jshint.com/docs/options */ | ||
// Variables defined in and used from main.js. | ||
/* globals randomString, initialize */ | ||
/* exported params */ | ||
'use strict'; | ||
|
||
// Provide params var, provided inline in index.html. | ||
var params; | ||
|
||
// Generate random room id and connect. | ||
var room = randomString(9); | ||
|
||
// Provide default params set to the values returned by apprtc.appspot.com. | ||
var params = { | ||
errorMessages: [], | ||
isLoopback: false, | ||
mediaConstraints: { | ||
'audio': true, | ||
'video': { | ||
'optional': [{ | ||
'minWidth': '1280' | ||
}, { | ||
'minHeight': '720' | ||
}], | ||
'mandatory': {} | ||
} | ||
}, | ||
offerConstraints: { | ||
'optional': [], | ||
'mandatory': {} | ||
}, | ||
peerConnectionConfig: { | ||
'iceServers': [] | ||
}, | ||
peerConnectionConstraints: { | ||
'optional': [{ | ||
'googImprovedWifiBwe': true | ||
}] | ||
}, | ||
turnRequestUrl: 'https://computeengineondemand.appspot.com/turn?username=073557600&key=4080218913', | ||
turnTransports: '', | ||
audioSendBitrate: '', | ||
audioSendCodec: '', | ||
audioRecvBitrate: '', | ||
audioRecvCodec: '', | ||
isStereoscopic: '', | ||
opusMaxPbr: '', | ||
opusFec: '', | ||
opusStereo: '', | ||
videoSendBitrate: '', | ||
videoSendInitialBitrate: '', | ||
videoSendCodec: '', | ||
videoRecvBitrate: '', | ||
videoRecvCodec: '', | ||
wssUrl: 'wss://apprtc-ws.webrtc.org:443/ws', | ||
wssPostUrl: 'https://apprtc-ws.webrtc.org:443' | ||
}; | ||
|
||
params.roomId = room; | ||
params.roomLink = 'https://apprtc.appspot.com/room/' + room; | ||
params.server = 'https://apprtc.appspot.com'; | ||
|
||
var joinRoomLink = document.querySelector('#room-link'); | ||
joinRoomLink.href = params.roomLink; | ||
joinRoomLink.text = params.roomLink; | ||
|
||
initialize(); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
/* | ||
* Copyright (c) 2014 The WebRTC project authors. All Rights Reserved. | ||
* | ||
* Use of this source code is governed by a BSD-style license | ||
* that can be found in the LICENSE file in the root of the source | ||
* tree. | ||
*/ | ||
|
||
/* More information about these options at jshint.com/docs/options */ | ||
|
||
// Variables defined in and used from chrome. | ||
/* globals chrome */ | ||
|
||
'use strict'; | ||
chrome.app.runtime.onLaunched.addListener(function() { | ||
chrome.app.window.create('appwindow.html', { | ||
'width': 800, | ||
'height': 600, | ||
'left': 0, | ||
'top': 0 | ||
}); | ||
}); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
{ | ||
"name": "AppRTC", | ||
"description": "AppRTC video chat application", | ||
"version": "0.1", | ||
"manifest_version": 2, | ||
"app": { | ||
"background": { | ||
"scripts": ["js/background.js"] | ||
} | ||
}, | ||
"icons": { | ||
"16": "images/apprtc-16.png", | ||
"22": "images/apprtc-22.png", | ||
"32": "images/apprtc-32.png", | ||
"48": "images/apprtc-48.png", | ||
"128": "images/apprtc-128.png" | ||
}, | ||
"permissions": [ | ||
"audioCapture", | ||
"videoCapture", | ||
"storage", | ||
"https://apprtc.appspot.com/", | ||
"https://computeengineondemand.appspot.com/" | ||
] | ||
} |