mirror of
https://github.com/eliasstepanik/vdo.ninja.git
synced 2026-01-17 16:48:33 +00:00
&slots and &sstype=3 added/fixed
This commit is contained in:
parent
1a5e0852a7
commit
4da462d9ab
45
index.html
45
index.html
@ -138,12 +138,15 @@
|
||||
<div id="mutevideobutton" onmousedown="event.preventDefault(); event.stopPropagation();" title="Disable the Camera" alt="Disable the Camera" onclick="toggleVideoMute()" tabindex="19" role="button" aria-pressed="false" onkeyup="enterPressedClick(event,this);" class="advanced float" style="cursor: pointer;">
|
||||
<i id="mutevideotoggle" onmousedown="event.preventDefault(); event.stopPropagation();" class="toggleSize las la-video my-float"></i>
|
||||
</div>
|
||||
<div id="screensharebutton" onmousedown="event.preventDefault(); event.stopPropagation();" title="Share a Screen with others" alt="Share a Screen with others" onclick="toggleScreenShare()" tabindex="20" role="button" aria-pressed="false" onkeyup="enterPressedClick(event,this);" class="float advanced" style="cursor: pointer;">
|
||||
<div id="screensharebutton" onmousedown="event.preventDefault(); event.stopPropagation();" title="Share a Screen with others" alt="Share a Screen with others" onclick="screenshareTypeDecider(1)" tabindex="20" role="button" aria-pressed="false" onkeyup="enterPressedClick(event,this);" class="float advanced" style="cursor: pointer;">
|
||||
<i id="screensharetoggle" onmousedown="event.preventDefault(); event.stopPropagation();" class="toggleSize las la-desktop my-float"></i>
|
||||
</div>
|
||||
<div id="screenshare2button" onmousedown="event.preventDefault(); event.stopPropagation();" title="Create a Secondary Stream" alt="Create a Secondary Stream" onclick="createIframePopup()" tabindex="20" role="button" aria-pressed="false" onkeyup="enterPressedClick(event,this);" class="float advanced" style="cursor: pointer;">
|
||||
<div id="screenshare2button" onmousedown="event.preventDefault(); event.stopPropagation();" title="Create a Secondary Stream" alt="Create a Secondary Stream" onclick="screenshareTypeDecider(2)" tabindex="20" role="button" aria-pressed="false" onkeyup="enterPressedClick(event,this);" class="float advanced" style="cursor: pointer;">
|
||||
<i id="screenshare2toggle" onmousedown="event.preventDefault(); event.stopPropagation();" class="toggleSize las la-tv my-float"></i>
|
||||
</div>
|
||||
<div id="screenshare3button" onmousedown="event.preventDefault(); event.stopPropagation();" title="Create a Third Stream" alt="Create a Third Stream" onclick="screenshareTypeDecider(3)" tabindex="20" role="button" aria-pressed="false" onkeyup="enterPressedClick(event,this);" class="float advanced" style="cursor: pointer;">
|
||||
<i id="screenshare3toggle" onmousedown="event.preventDefault(); event.stopPropagation();" class="toggleSize las la-tv my-float"></i>
|
||||
</div>
|
||||
<div id="websitesharebutton" onmousedown="event.preventDefault(); event.stopPropagation();" title="Share a website as an embedded iFRAME" alt="Share a website as an embedded iFRAME" onclick="shareWebsite(false, event)" tabindex="21" role="button" aria-pressed="false" onkeyup="enterPressedClick(event,this);" class="float advanced" style="cursor: pointer;">
|
||||
<i id="websitesharetoggle" onmousedown="event.preventDefault(); event.stopPropagation();" class="toggleSize las la-window-maximize my-float"></i>
|
||||
</div>
|
||||
@ -340,6 +343,10 @@
|
||||
|
||||
<i class="las la-cog" style="font-size: 140%; vertical-align: middle;" aria-hidden="true"></i>
|
||||
</span>
|
||||
<div id="cameraTip1" class="cameraTip advanced">
|
||||
<i class="las la-info-circle"></i>
|
||||
<p><span id="cameraTipContext1"></span></p>
|
||||
</div>
|
||||
</span>
|
||||
<br />
|
||||
<center>
|
||||
@ -1166,21 +1173,21 @@
|
||||
<div id="controls_blank" style="display: none;">
|
||||
<div class="controlsGrid">
|
||||
|
||||
<button data-action-type="forward" data-value="0" title="Move the user to another room, controlled by another director" onclick="directMigrate(this, event);">
|
||||
<button data-action-type="forward" class="mainonly" data-value="0" title="Move the user to another room, controlled by another director" onclick="directMigrate(this, event);">
|
||||
<i class="las la-paper-plane"></i>
|
||||
<span data-translate="forward-to-room">Transfer</span>
|
||||
</button>
|
||||
|
||||
<button data-action-type="direct-chat" title="Send a Direct Message to this user." onclick="directorSendMessage(this);">
|
||||
<button data-action-type="direct-chat" class="mainonly" title="Send a Direct Message to this user." onclick="directorSendMessage(this);">
|
||||
<span data-translate="send-direct-chat"><i class="las la-envelope"></i> Message</span>
|
||||
</button>
|
||||
|
||||
<button data-action-type="hangup" data-value="0" title="Force the user to Disconnect. They can always reconnect." onclick="directHangup(this, event);">
|
||||
<button data-action-type="hangup" class="mainonly" data-value="0" title="Force the user to Disconnect. They can always reconnect." onclick="directHangup(this, event);">
|
||||
<i class="las la-sign-out-alt" style="color:#900"></i>
|
||||
<span data-translate="disconnect-guest" >Hangup</span>
|
||||
</button>
|
||||
|
||||
<button data-action-type="solo-chat" title="Toggle solo voice chat or hold CTRL/CMD when selecting to make it two-way private." onclick="session.toggleSoloChat(this.dataset.UUID, event);">
|
||||
<button data-action-type="solo-chat" class="mainonly" title="Toggle solo voice chat or hold CTRL/CMD when selecting to make it two-way private." onclick="session.toggleSoloChat(this.dataset.UUID, event);">
|
||||
<span data-translate="voice-chat"><i class="las la-microphone" style="color:#090"></i> Solo Talk</span>
|
||||
</button>
|
||||
|
||||
@ -1203,8 +1210,8 @@
|
||||
<span data-translate="add-to-scene2">add to scene 2</span>
|
||||
</button>
|
||||
|
||||
<button data-action-type="mute-scene" class="hidden" data-cluster="1" title="Remotely Mute this Audio in all remote '&scene' views" onclick="directMute(this, event);">
|
||||
<i class="las la-microphone-slash" style="color:#900"></i>
|
||||
<button data-action-type="mute-scene" class="hidden" data-cluster="1" title="Remotely Mute this Audio in all remote '&scene' views" onclick="directMute(this, event);">
|
||||
<i class="las la-microphone-slash" style="color:#900"></i>
|
||||
<span data-translate="mute-scene" >mute in scene</span>
|
||||
</button>
|
||||
|
||||
@ -1256,11 +1263,11 @@
|
||||
<span data-translate="hide-guest" >hide guest</span>
|
||||
</button>
|
||||
|
||||
<button class="hidden" data-cluster="2" data-action-type="toggle-remote-speaker"title="Toggle the remote guest's speaker output" onclick="remoteSpeakerMute(this, event);">
|
||||
<button class="hidden mainonly" data-cluster="2" data-action-type="toggle-remote-speaker"title="Toggle the remote guest's speaker output" onclick="remoteSpeakerMute(this, event);">
|
||||
<i class="las la-volume-off"></i> <span data-translate="toggle-remote-speaker">Deafen Guest</span>
|
||||
</button>
|
||||
|
||||
<button class="hidden" data-cluster="2" data-action-type="toggle-remote-display" title="Toggle the remote guest's display output" onclick="remoteDisplayMute(this, event);">
|
||||
<button class="hidden mainonly" data-cluster="2" data-action-type="toggle-remote-display" title="Toggle the remote guest's display output" onclick="remoteDisplayMute(this, event);">
|
||||
<i class="las la-eye-slash"></i> <span data-translate="toggle-remote-display">Blind Guest</span>
|
||||
</button>
|
||||
|
||||
@ -1277,18 +1284,16 @@
|
||||
</button>
|
||||
</span>
|
||||
|
||||
<button class="hidden" data-cluster="2" data-action-type="change-url" data-value="0" title="Remotely reload the guest's page with a new URL" onclick="directPageReload(this, event);">
|
||||
<button class="hidden mainonly" data-cluster="2" data-action-type="change-url" data-value="0" title="Remotely reload the guest's page with a new URL" onclick="directPageReload(this, event);">
|
||||
<i class="las la-sync"></i>
|
||||
<span data-translate="change-url">Change URL</span>
|
||||
</button>
|
||||
|
||||
<button class="hidden" data-cluster="2" data-action-type="change-params" style="display:none" title="Change user parameters" onclick="promptUser('transferSettingsTemplate', this.dataset.UUID);">
|
||||
<button class="hidden mainonly" data-cluster="2" data-action-type="change-params" style="display:none" title="Change user parameters" onclick="promptUser('transferSettingsTemplate', this.dataset.UUID);">
|
||||
<i class="las la-cog"></i>
|
||||
<span data-translate="change-params">URL Params</span>
|
||||
</button>
|
||||
|
||||
|
||||
|
||||
<button class="hidden" data-cluster="2" data-action-type="recorder-local" title="Start Recording this remote stream to this local drive. *experimental*'" onclick="recordVideo(this, event)">
|
||||
<i class="las la-circle"></i>
|
||||
<span data-translate="record-local"> Record Local</span>
|
||||
@ -1298,12 +1303,12 @@
|
||||
<span data-translate="record-remote"> Record Remote</span>
|
||||
</button>
|
||||
|
||||
<button class="hidden" data-cluster="2" data-action-type="open-file-share" data-value="0" title="Allow the guest to select a file to upload to the director. Once shared, it will show in the chat as a download link." onclick="requestFileUpload(this)">
|
||||
<button class="hidden mainonly" data-cluster="2" data-action-type="open-file-share" data-value="0" title="Allow the guest to select a file to upload to the director. Once shared, it will show in the chat as a download link." onclick="requestFileUpload(this)">
|
||||
<i class="las la-file-upload"></i>
|
||||
<span data-translate="request-upload"> Request File</span>
|
||||
</button>
|
||||
|
||||
<button class="hidden" data-cluster="2" data-action-type="create-timer" data-value="0" title="Set a countdown timer that this guest sees" onclick="directTimer(this, event);">
|
||||
<button class="hidden mainonly" data-cluster="2" data-action-type="create-timer" data-value="0" title="Set a countdown timer that this guest sees" onclick="directTimer(this, event);">
|
||||
<i class="las la-clock"></i>
|
||||
<span data-translate="create-timer">Create Timer</span>
|
||||
</button>
|
||||
@ -1382,7 +1387,7 @@
|
||||
<button class="hidden" data-cluster="2" data-action-type="advanced-audio-settings" data-active="false" title="Remote Audio Settings" onclick="requestAudioSettings(this);">
|
||||
<span data-translate="advanced-audio-settings"><i class="las la-sliders-h"></i> Audio Settings</span>
|
||||
</button>
|
||||
<button class="hidden" data-cluster="2" data-action-type="advanced-camera-settings" data-active="false" title="Advanced Video Settings" onclick="requestVideoSettings(this);">
|
||||
<button class="hidden mainonly" data-cluster="2" data-action-type="advanced-camera-settings" data-active="false" title="Advanced Video Settings" onclick="requestVideoSettings(this);">
|
||||
<span data-translate="advanced-camera-settings"><i class="las la-sliders-h"></i> Video Settings</span>
|
||||
</button>
|
||||
|
||||
@ -1724,9 +1729,9 @@
|
||||
<i class="las la-signal"></i>
|
||||
<i class="las la-fire-alt"></i>
|
||||
</div>
|
||||
<div id="voiceMeterTemplate" class="video-meter">
|
||||
<div id="voiceMeterTemplate" class="video-meter advanced">
|
||||
</div>
|
||||
<div id="voiceMeterTemplate2" class="video-meter2">
|
||||
<div id="voiceMeterTemplate2" class="video-meter2 advanced">
|
||||
</div>
|
||||
<div id="muteStateTemplate" style="display:none;" class="video-mute-state">
|
||||
<i class="las la-microphone-slash"></i>
|
||||
@ -1877,7 +1882,7 @@
|
||||
// session.introOnClean = true; // this will load the page with the webcam selection screen if &push or &room is in the URL; no need to use &webcam.
|
||||
</script>
|
||||
<script type="text/javascript" crossorigin="anonymous" src="./thirdparty/aes.js"></script>
|
||||
<script type="text/javascript" crossorigin="anonymous" id="lib-js" src="./lib.js?ver=242"></script>
|
||||
<script type="text/javascript" crossorigin="anonymous" id="lib-js" src="./lib.js?ver=243"></script>
|
||||
<!--
|
||||
// If you wish to change branding, blank offers a good clean start.
|
||||
<script type="text/javascript" id="main-js" src="./main.js" data-translation="blank"></script>
|
||||
|
||||
55
main.css
55
main.css
@ -1300,6 +1300,18 @@ input[type=range]:focus::-ms-fill-upper {
|
||||
#screenshare2button.float2{
|
||||
background-color: #335c3a;
|
||||
}
|
||||
#screenshare3button.float2{
|
||||
background-color: #2bf96e88;
|
||||
animation: pulse 5s infinite;
|
||||
}
|
||||
#previewWebcam.miconly {
|
||||
display:none;
|
||||
}
|
||||
|
||||
.notmain > .mainonly {
|
||||
display:none!important;
|
||||
}
|
||||
|
||||
#popupSelector {
|
||||
background: linear-gradient(6deg, rgba(221, 221, 221, 0) 4%, rgb(221, 221, 221, 0.2) 30%, rgba(120, 120, 100, .5) 100%);
|
||||
transition: all 0.2s linear 0s;
|
||||
@ -1745,6 +1757,7 @@ img {
|
||||
|
||||
.ondeck {
|
||||
border: grey solid 2px !important;
|
||||
display: block !important;
|
||||
}
|
||||
|
||||
.recording{
|
||||
@ -2825,6 +2838,23 @@ span#guestTips {
|
||||
pointer-events:none;
|
||||
border: 1px black solid;
|
||||
}
|
||||
|
||||
.video-meter-2 {
|
||||
padding:0;
|
||||
display:block;
|
||||
width:100%;
|
||||
height:100%;
|
||||
min-width:10px;
|
||||
min-height:10px;
|
||||
top: 0;
|
||||
right: 0;
|
||||
background-color:unset;
|
||||
position:absolute;
|
||||
border-radius: 5px;
|
||||
pointer-events:none;
|
||||
border: 5px green solid;
|
||||
}
|
||||
|
||||
.video-meter-director {
|
||||
width: 10px;
|
||||
height: 10px;
|
||||
@ -3118,6 +3148,31 @@ input:checked + .slider:before {
|
||||
padding: 2px 0 0 0;
|
||||
}
|
||||
|
||||
.cameraTip {
|
||||
width: 100%;
|
||||
display: block;
|
||||
border-left: 4px solid #50cef1;
|
||||
background: #dbf0ff;
|
||||
padding: 10px;
|
||||
align-items: center;
|
||||
position: relative;
|
||||
margin: 8px auto 0px auto;
|
||||
box-shadow: 0px 5px 10px -5px #a9a9a9;
|
||||
text-align: left;
|
||||
}
|
||||
.cameraTip > p {
|
||||
text-align: left;
|
||||
display:inline-block;
|
||||
padding-left: 32px;
|
||||
vertical-align: middle;
|
||||
|
||||
}
|
||||
.cameraTip > i {
|
||||
position: absolute;
|
||||
font-size: 1.5em;
|
||||
padding: 2px 0 0 0;
|
||||
}
|
||||
|
||||
#consentWarning{
|
||||
margin: 0 auto 20px auto;
|
||||
}
|
||||
|
||||
184
main.js
184
main.js
@ -407,6 +407,7 @@ async function main(){ // main asyncronous thread; mostly initializes the user s
|
||||
//session.autostart = true;
|
||||
getById("mutevideobutton").style.setProperty("display", "none", "important");
|
||||
getById("videoMenu3").style.setProperty("display", "none", "important");
|
||||
getById("previewWebcam").classList.add("miconly");
|
||||
//if (session.consent){
|
||||
// setTimeout(function(){
|
||||
// warnUser("⚠ Privacy warning: The director of this room can remotely switch your camera or microphone without permission.", 8000);
|
||||
@ -448,7 +449,13 @@ async function main(){ // main asyncronous thread; mostly initializes the user s
|
||||
if (urlParams.get('screenshare2') || urlParams.get('ss2')){
|
||||
session.screenshare = urlParams.get('screenshare2') || urlParams.get('ss2');
|
||||
}
|
||||
}
|
||||
|
||||
if (urlParams.has('sstype') || urlParams.has('screensharetype')) { // wha type of screen sharing is used; track replace, iframe, or secondary try
|
||||
session.screensharetype = urlParams.get('sstype') || urlParams.get('screensharetype');
|
||||
session.screensharetype = parseInt(session.screensharetype) || false;
|
||||
}
|
||||
|
||||
if (urlParams.has('intro') || urlParams.has('ib')) {
|
||||
session.introButton = true;
|
||||
}
|
||||
@ -460,7 +467,11 @@ async function main(){ // main asyncronous thread; mostly initializes the user s
|
||||
if (urlParams.has('ssb')) {
|
||||
session.screensharebutton = true;
|
||||
}
|
||||
|
||||
|
||||
if (urlParams.has('ssb')) {
|
||||
session.screensharebutton = true;
|
||||
}
|
||||
|
||||
if (urlParams.has('mute') || urlParams.has('muted') || urlParams.has('m')) {
|
||||
session.muted = true;
|
||||
}
|
||||
@ -610,6 +621,18 @@ async function main(){ // main asyncronous thread; mostly initializes the user s
|
||||
session.audioEffects = false;
|
||||
session.audioMeterGuest = false;
|
||||
}
|
||||
|
||||
if (urlParams.has('autoadd')) { // the streams we want to view; if set, but let blank, we will request no streams to watch.
|
||||
session.autoadd = urlParams.get('autoadd') || null; // this value can be comma seperated for multiple streams to pull
|
||||
|
||||
if (session.autoadd == null) {
|
||||
session.autoadd = false;
|
||||
}
|
||||
if (session.autoadd) {
|
||||
session.autoadd = session.autoadd.split(",");
|
||||
}
|
||||
}
|
||||
|
||||
//if (session.scene!=="1"){ // scene =0 and 1 should load instantly.
|
||||
// session.hiddenSceneViewBitrate = 0; // By default this is ~ 400kbps, but if you have 10 scenes, i don't want to kill things.
|
||||
//}
|
||||
@ -1101,6 +1124,36 @@ async function main(){ // main asyncronous thread; mostly initializes the user s
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
if (session.view_set){
|
||||
session.allowScreen = [];
|
||||
session.allowVideos = [];
|
||||
var i = session.view_set.length;
|
||||
while (i--){
|
||||
var split = session.view_set[i].split(":s");
|
||||
if (split.length>1){
|
||||
session.allowScreen.push(split[0]);
|
||||
session.view_set.splice(i, 1);
|
||||
if (!(split[0] in session.view_set)){
|
||||
session.view_set.push(split[0]);
|
||||
}
|
||||
} else {
|
||||
session.allowVideos.push(split[0]);
|
||||
}
|
||||
}
|
||||
|
||||
} else if (session.view){
|
||||
session.allowScreen = [];
|
||||
session.allowVideos = [];
|
||||
var split = session.view.split(":s");
|
||||
if (split.length>1){
|
||||
session.allowScreen.push(split[0]);
|
||||
session.view = split[0];
|
||||
} else {
|
||||
session.allowVideos.push(split[0]);
|
||||
}
|
||||
}
|
||||
|
||||
//if (urlParams.has('directorview') || urlParams.has('dv')){
|
||||
// session.directorView = true;
|
||||
@ -1387,16 +1440,10 @@ async function main(){ // main asyncronous thread; mostly initializes the user s
|
||||
// whatever the user entered I guess, santitized.
|
||||
session.videoDevice = session.videoDevice.replace(/[\W]+/g, "_").toLowerCase();
|
||||
}
|
||||
|
||||
if (session.videoDevice === 0) {
|
||||
getById("add_camera").innerHTML = "Share your Microphone";
|
||||
miniTranslate(getById("add_camera"), "share-your-mic");
|
||||
}
|
||||
|
||||
getById("videoMenu").style.display = "none";
|
||||
log("session.videoDevice:" + session.videoDevice);
|
||||
}
|
||||
|
||||
|
||||
// audioDevice
|
||||
if (urlParams.has('audiodevice') || urlParams.has('adevice') || urlParams.has('ad') || urlParams.has('device') || urlParams.has('d')) {
|
||||
|
||||
@ -1429,19 +1476,6 @@ async function main(){ // main asyncronous thread; mostly initializes the user s
|
||||
session.audioDevice = session.audioDevice.replace(/[\W]+/g, "_").toLowerCase();
|
||||
}
|
||||
|
||||
|
||||
if (session.videoDevice === 0) {
|
||||
if (session.audioDevice === 0) {
|
||||
getById("add_camera").innerHTML = "Click Start to Join";
|
||||
miniTranslate(getById("add_camera"), "click-start-to-join");
|
||||
getById("container-2").className = 'column columnfade advanced'; // Hide screen share on mobile
|
||||
getById("container-3").classList.add("skip-animation");
|
||||
getById("container-3").classList.remove('pointer');
|
||||
delayedStartupFuncs.push([previewWebcam]);
|
||||
session.webcamonly = true;
|
||||
}
|
||||
}
|
||||
|
||||
log("session.audioDevice:" + session.audioDevice);
|
||||
|
||||
getById("audioMenu").style.display = "none";
|
||||
@ -1450,6 +1484,21 @@ async function main(){ // main asyncronous thread; mostly initializes the user s
|
||||
getById("audioScreenShare1").style.display = "none";
|
||||
|
||||
}
|
||||
|
||||
if (session.videoDevice === 0) {
|
||||
getById("add_camera").innerHTML = "Share your Microphone";
|
||||
miniTranslate(getById("add_camera"), "share-your-mic");
|
||||
getById("previewWebcam").classList.add("miconly");
|
||||
if (session.audioDevice === 0) {
|
||||
getById("add_camera").innerHTML = "Click Start to Join";
|
||||
miniTranslate(getById("add_camera"), "click-start-to-join");
|
||||
getById("container-2").className = 'column columnfade advanced'; // Hide screen share on mobile
|
||||
getById("container-3").classList.add("skip-animation");
|
||||
getById("container-3").classList.remove('pointer');
|
||||
delayedStartupFuncs.push([previewWebcam]);
|
||||
session.webcamonly = true;
|
||||
}
|
||||
}
|
||||
|
||||
if (session.mobile){
|
||||
getById("shareScreenGear").style.display = "none";
|
||||
@ -1532,7 +1581,7 @@ async function main(){ // main asyncronous thread; mostly initializes the user s
|
||||
}
|
||||
log("disable audio playback");
|
||||
}
|
||||
|
||||
|
||||
if (urlParams.has('forceios')) {
|
||||
log("allow iOS to work in video group chat; for this user at least");
|
||||
session.forceios = true;
|
||||
@ -1552,7 +1601,6 @@ async function main(){ // main asyncronous thread; mostly initializes the user s
|
||||
}
|
||||
`;
|
||||
document.head.appendChild(styletmp);
|
||||
|
||||
}
|
||||
|
||||
if (urlParams.has('cursor') || urlParams.has('screensharecursor')) {
|
||||
@ -1571,6 +1619,10 @@ async function main(){ // main asyncronous thread; mostly initializes the user s
|
||||
session.slot = parseInt(urlParams.get('slot')) || 0;
|
||||
}
|
||||
|
||||
if (urlParams.has('slots')) {
|
||||
session.slots = parseInt(urlParams.get('slots')) || 4;
|
||||
}
|
||||
|
||||
if (urlParams.has('debug')){
|
||||
debugStart();
|
||||
}
|
||||
@ -2039,33 +2091,6 @@ async function main(){ // main asyncronous thread; mostly initializes the user s
|
||||
log("ICE FILTER ENABLED");
|
||||
session.icefilter = urlParams.get('icefilter');
|
||||
}
|
||||
|
||||
|
||||
if (urlParams.has('effects') || urlParams.has('effect')) {
|
||||
session.effects = urlParams.get('effects') || urlParams.get('effect') || null;
|
||||
if (session.effects === null){
|
||||
getById("effectsDiv").style.display = "block";
|
||||
session.effects = "0";
|
||||
} else if (session.effects === "0" || session.effects === "false" || session.effects === "off"){
|
||||
session.effects = false;
|
||||
getById("effectSelector3").style.display = "none";
|
||||
getById("effectsDiv3").style.display = "none";
|
||||
getById("effectSelector").style.display = "none";
|
||||
getById("effectsDiv").style.display = "none";
|
||||
}
|
||||
|
||||
if (session.effects === "5"){
|
||||
getById("selectImageTFLITE").style.display = "block";
|
||||
getById("selectImageTFLITE3").style.display = "block";
|
||||
getById("effectSelector").style.display = "none";
|
||||
getById("effectsDiv").style.display = "block";
|
||||
}
|
||||
// mirror == 2
|
||||
// face == 1
|
||||
// blur = 3
|
||||
// green = 4
|
||||
// image = 5
|
||||
}
|
||||
|
||||
//if (!(getChromeVersion()>=57)){
|
||||
// getById("effectSelector").disabled=true;
|
||||
@ -2139,11 +2164,12 @@ async function main(){ // main asyncronous thread; mostly initializes the user s
|
||||
session.animatedMoves=false;
|
||||
}
|
||||
|
||||
if (urlParams.has('meter') || urlParams.has('meterstyle')){
|
||||
if (urlParams.has('meter') || urlParams.has('meterstyle')){ // same as also adding &style=3
|
||||
session.meterStyle = urlParams.get('meter') || urlParams.get('meterstyle') || 1;
|
||||
session.meterStyle = parseInt(session.meterStyle);
|
||||
session.style = 3;
|
||||
session.audioEffects = true;
|
||||
}
|
||||
|
||||
|
||||
|
||||
if (urlParams.has('directorchat') || urlParams.has('dc')){
|
||||
session.directorChat = true;
|
||||
@ -2156,11 +2182,15 @@ async function main(){ // main asyncronous thread; mostly initializes the user s
|
||||
} else if ((parseInt(session.style) == 2) || (session.style == "waveform")) { // audio waveform
|
||||
session.style = 2;
|
||||
session.audioEffects = true; ////!!!!!!! Do I want to enable the audioEffects myself? or do it here?
|
||||
} else if ((parseInt(session.style) == 3) || (session.style == "volume")) { // photo is taken? upload option? canvas?
|
||||
} else if ((parseInt(session.style) == 3) || (session.style == "volume")) { // audio meter ; see &meterstyle , where optios include default(false), 1, and 2.
|
||||
session.style = 3;
|
||||
session.audioEffects = true;
|
||||
} else if (parseInt(session.style) == 4) { // photo is taken? upload option? canvas?
|
||||
} else if (parseInt(session.style) == 4) { // black background
|
||||
session.style = 4;
|
||||
} else if (parseInt(session.style) == 5) { // random colored background
|
||||
session.style = 5;
|
||||
} else if (parseInt(session.style)) { // 6 is the first letter of the name, surrounded with a colored circle
|
||||
session.style = parseInt(session.style);
|
||||
} else {
|
||||
session.style = 1;
|
||||
}
|
||||
@ -2443,6 +2473,40 @@ async function main(){ // main asyncronous thread; mostly initializes the user s
|
||||
session.roomid = sanitizeRoomName(roomid);
|
||||
}
|
||||
|
||||
if ((session.permaid===false) && (session.roomid===false) && (session.view===false) && (session.effects===false) && (session.director===false)){
|
||||
session.effects = null;
|
||||
}
|
||||
|
||||
|
||||
if (urlParams.has('effects') || urlParams.has('effect')) {
|
||||
session.effects = urlParams.get('effects') || urlParams.get('effect') || null;
|
||||
}
|
||||
|
||||
if (session.effects!==false){
|
||||
if (session.effects === null){
|
||||
getById("effectsDiv").style.display = "block";
|
||||
session.effects = "0";
|
||||
} else if (session.effects === "0" || session.effects === "false" || session.effects === "off" || session.effects === 0){
|
||||
session.effects = false;
|
||||
getById("effectSelector3").style.display = "none";
|
||||
getById("effectsDiv3").style.display = "none";
|
||||
getById("effectSelector").style.display = "none";
|
||||
getById("effectsDiv").style.display = "none";
|
||||
}
|
||||
|
||||
if (session.effects === "5"){
|
||||
getById("selectImageTFLITE").style.display = "block";
|
||||
getById("selectImageTFLITE3").style.display = "block";
|
||||
getById("effectSelector").style.display = "none";
|
||||
getById("effectsDiv").style.display = "block";
|
||||
}
|
||||
// mirror == 2
|
||||
// face == 1
|
||||
// blur = 3
|
||||
// green = 4
|
||||
// image = 5
|
||||
}
|
||||
|
||||
if (session.webcamonly == true) {
|
||||
if (session.introButton){
|
||||
getById("container-2").className = 'column columnfade advanced'; // Hide screen share
|
||||
@ -2455,7 +2519,7 @@ async function main(){ // main asyncronous thread; mostly initializes the user s
|
||||
delayedStartupFuncs.push([previewWebcam]);
|
||||
}
|
||||
}
|
||||
if (session.introOnClean && (session.permaid===false) && (session.roomid===false)){
|
||||
if (session.introOnClean && (session.permaid===false) && (session.roomid===false)){
|
||||
//getById("container-2").className = 'column columnfade advanced'; // Hide screen share
|
||||
getById("head3").classList.add('advanced');
|
||||
getById("head3a").classList.add('advanced');
|
||||
@ -2592,13 +2656,7 @@ async function main(){ // main asyncronous thread; mostly initializes the user s
|
||||
window.onresize = updateMixer;
|
||||
window.onorientationchange = function(){
|
||||
setTimeout(updateMixer, 200);
|
||||
//if (session.effects){
|
||||
// if (session.streamSrc){
|
||||
// setTimeout(function(){
|
||||
// updateRenderOutpipe(session.streamSrc, true);
|
||||
// },500);
|
||||
// }
|
||||
//}
|
||||
|
||||
};
|
||||
joinRoom(session.roomid); // this is a scene, so we want high resolutions
|
||||
getById("main").style.overflow = "hidden";
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user