diff --git a/app.js b/app.js
index 1251849a4..c15fd864b 100644
--- a/app.js
+++ b/app.js
@@ -448,8 +448,9 @@ function statsUpdated(statsCollector)
var peerStats = statsCollector.jid2stats[jid];
Object.keys(peerStats.ssrc2AudioLevel).forEach(function (ssrc)
{
-// console.info(jid + " audio level: " +
-// peerStats.ssrc2AudioLevel[ssrc] + " of ssrc: " + ssrc);
+ if (jid !== connection.emuc.myRoomJid)
+ AudioLevels.updateAudioLevel( Strophe.getResourceFromJid(jid),
+ peerStats.ssrc2AudioLevel[ssrc]);
});
});
}
@@ -461,7 +462,10 @@ function statsUpdated(statsCollector)
*/
function localStatsUpdated(statsCollector)
{
-// console.info("Local audio level: " + statsCollector.audioLevel);
+ if (connection.emuc.myRoomJid)
+ AudioLevels.updateAudioLevel(
+ Strophe.getResourceFromJid(connection.emuc.myRoomJid),
+ statsCollector.audioLevel);
}
/**
diff --git a/chat.js b/chat.js
index 051829dac..afb06c771 100644
--- a/chat.js
+++ b/chat.js
@@ -175,7 +175,13 @@ var Chat = (function (my) {
$('#remoteVideos>span').animate({height: thumbnailsHeight,
width: thumbnailsWidth},
{queue: false,
- duration: 500});
+ duration: 500,
+ complete: function() {
+ $(document).trigger(
+ "remotevideo.resized",
+ [thumbnailsWidth,
+ thumbnailsHeight]);
+ }});
$('#largeVideoContainer').animate({ width: videospaceWidth,
height: videospaceHeight},
@@ -219,7 +225,12 @@ var Chat = (function (my) {
$('#remoteVideos>span').animate({height: thumbnailsHeight,
width: thumbnailsWidth},
{queue: false,
- duration: 500});
+ duration: 500,
+ complete: function() {
+ $(document).trigger(
+ "remotevideo.resized",
+ [thumbnailsWidth, thumbnailsHeight]);
+ }});
$('#largeVideoContainer').animate({ width: videospaceWidth,
height: videospaceHeight},
diff --git a/config.js b/config.js
index b68914179..db9c3b195 100644
--- a/config.js
+++ b/config.js
@@ -12,7 +12,7 @@ var config = {
desktopSharing: 'ext', // Desktop sharing method. Can be set to 'ext', 'webrtc' or false to disable.
chromeExtensionId: 'diibjkoicjeejcmhdnailmkgecihlobk', // Id of desktop streamer Chrome extension
minChromeExtVersion: '0.1', // Required version of Chrome extension
- enableRtpStats: false, // Enables RTP stats processing
+ enableRtpStats: true, // Enables RTP stats processing
openSctp: true, // Toggle to enable/disable SCTP channels
// channelLastN: -1, // The default value of the channel attribute last-n.
enableRecording: false
diff --git a/css/videolayout_default.css b/css/videolayout_default.css
index f140071b8..b87782db4 100644
--- a/css/videolayout_default.css
+++ b/css/videolayout_default.css
@@ -49,8 +49,16 @@
-webkit-animation-name: greyPulse;
-webkit-animation-duration: 2s;
-webkit-animation-iteration-count: 1;
- -webkit-box-shadow: 0 0 18px #388396;
- border: 2px solid #388396;
+}
+
+#remoteVideos .videocontainer:hover {
+ -webkit-box-shadow: inset 0 0 10px #FFFFFF, 0 0 10px #FFFFFF;
+ border: 2px solid #FFFFFF;
+}
+
+#remoteVideos .videocontainer.videoContainerFocused {
+ -webkit-box-shadow: inset 0 0 28px #006d91;
+ border: 2px solid #006d91;
}
#localVideoWrapper {
@@ -291,3 +299,10 @@
background-image:url(../images/rightwatermark.png);
background-position: center right;
}
+
+.audiolevel {
+ display: inline-block;
+ position: absolute;
+ z-index: 0;
+ border-radius:10px;
+}
diff --git a/index.html b/index.html
index c197e091d..ef310d7a7 100644
--- a/index.html
+++ b/index.html
@@ -22,14 +22,14 @@
-
+
-
+
-
+
@@ -39,12 +39,14 @@
-
+
+
+
-
+
diff --git a/local_stats.js b/local_stats.js
index 2802fe455..6b2c44277 100644
--- a/local_stats.js
+++ b/local_stats.js
@@ -32,7 +32,6 @@ var LocalStatsCollector = (function() {
this.audioLevel = 0;
}
-
/**
* Starts the collecting the statistics.
*/
@@ -61,8 +60,7 @@ var LocalStatsCollector = (function() {
},
this.intervalMilis
);
-
- }
+ };
/**
* Stops collecting the statistics.
@@ -72,8 +70,7 @@ var LocalStatsCollector = (function() {
clearInterval(this.intervalId);
this.intervalId = null;
}
- }
-
+ };
/**
* Converts frequency data array to audio level.
@@ -91,7 +88,7 @@ var LocalStatsCollector = (function() {
}
return maxVolume / 255;
- }
+ };
return LocalStatsCollectorProto;
})();
\ No newline at end of file
diff --git a/videolayout.js b/videolayout.js
index 11c2dbb1c..0c94799f3 100644
--- a/videolayout.js
+++ b/videolayout.js
@@ -26,6 +26,8 @@ var VideoLayout = (function (my) {
var localVideoContainer = document.getElementById('localVideoWrapper');
localVideoContainer.appendChild(localVideo);
+ AudioLevels.updateAudioLevelCanvas();
+
var localVideoSelector = $('#' + localVideo.id);
// Add click handler to both video and video wrapper elements in case
// there's no video.
@@ -313,6 +315,8 @@ var VideoLayout = (function (my) {
addRemoteVideoMenu(peerJid, container);
remotes.appendChild(container);
+ AudioLevels.updateAudioLevelCanvas(peerJid);
+
return container;
};
@@ -579,6 +583,8 @@ var VideoLayout = (function (my) {
$('#remoteVideos').height(height);
$('#remoteVideos>span').width(width);
$('#remoteVideos>span').height(height);
+
+ $(document).trigger("remotevideo.resized", [width, height]);
};
/**
@@ -958,3 +964,5 @@ var VideoLayout = (function (my) {
return my;
}(VideoLayout || {}));
+
+