[mirotalk] - fix: resolve peer volume indicator not showing after mic toggle

This commit is contained in:
Miroslav Pejic
2026-04-28 11:45:00 +02:00
parent 2c63316e59
commit b333fdb24d
9 changed files with 11 additions and 13 deletions
+1 -1
View File
@@ -1,5 +1,5 @@
# ====================================================
# MiroTalk P2P v.1.8.16 - Environment Configuration
# MiroTalk P2P v.1.8.17 - Environment Configuration
# ====================================================
# App environment
+1 -1
View File
@@ -2,7 +2,7 @@
/**
* ==============================================
* MiroTalk P2P v.1.8.16 - Configuration File
* MiroTalk P2P v.1.8.17 - Configuration File
* ==============================================
*
* This file is the central configuration source.
+1 -1
View File
@@ -45,7 +45,7 @@ dependencies: {
* @license For commercial use or closed source, contact us at license.mirotalk@gmail.com or purchase directly from CodeCanyon
* @license CodeCanyon: https://codecanyon.net/item/mirotalk-p2p-webrtc-realtime-video-conferences/38376661
* @author Miroslav Pejic - miroslav.pejic.85@gmail.com
* @version 1.8.16
* @version 1.8.17
*
*/
+2 -2
View File
@@ -1,12 +1,12 @@
{
"name": "mirotalk",
"version": "1.8.16",
"version": "1.8.17",
"lockfileVersion": 3,
"requires": true,
"packages": {
"": {
"name": "mirotalk",
"version": "1.8.16",
"version": "1.8.17",
"license": "AGPL-3.0",
"dependencies": {
"@mattermost/client": "11.6.0",
+1 -1
View File
@@ -1,6 +1,6 @@
{
"name": "mirotalk",
"version": "1.8.16",
"version": "1.8.17",
"description": "A free WebRTC browser-based video call",
"main": "server.js",
"scripts": {
+1 -1
View File
@@ -109,7 +109,7 @@ let brand = {
},
about: {
imageUrl: '../images/mirotalk-logo.gif',
title: 'WebRTC P2P v1.8.16',
title: 'WebRTC P2P v1.8.17',
html: `
<button
id="support-button"
+2 -2
View File
@@ -15,7 +15,7 @@
* @license For commercial use or closed source, contact us at license.mirotalk@gmail.com or purchase directly from CodeCanyon
* @license CodeCanyon: https://codecanyon.net/item/mirotalk-p2p-webrtc-realtime-video-conferences/38376661
* @author Miroslav Pejic - miroslav.pejic.85@gmail.com
* @version 1.8.16
* @version 1.8.17
*
*/
@@ -15532,7 +15532,7 @@ function showAbout() {
Swal.fire({
background: swBg,
position: 'center',
title: brand.about?.title && brand.about.title.trim() !== '' ? brand.about.title : 'WebRTC P2P v1.8.16',
title: brand.about?.title && brand.about.title.trim() !== '' ? brand.about.title : 'WebRTC P2P v1.8.17',
imageUrl: brand.about?.imageUrl && brand.about.imageUrl.trim() !== '' ? brand.about.imageUrl : images.about,
customClass: { image: 'img-about' },
html: `
-1
View File
@@ -35,7 +35,6 @@ async function getMicrophoneVolumeIndicator(stream) {
workletNode = new AudioWorkletNode(audioContext, 'volume-processor', {
processorOptions: {
peerId: myPeerId, // Your peer ID
myAudioStatus: myAudioStatus, // Your audio status
threshold: 10, // Volume threshold
silenceThreshold: 0.01, // Silence threshold
},
+2 -3
View File
@@ -4,7 +4,6 @@ class VolumeProcessor extends AudioWorkletProcessor {
super();
this.threshold = options.processorOptions.threshold || 10;
this.peerId = options.processorOptions.peerId || '';
this.myAudioStatus = options.processorOptions.myAudioStatus || false;
this.silenceThreshold = options.processorOptions.silenceThreshold || 0.01;
}
@@ -32,8 +31,8 @@ class VolumeProcessor extends AudioWorkletProcessor {
const volume = Math.max(0, Math.min(1, rms * 10));
const finalVolume = Math.round(volume * 100);
// Only send data when volume exceeds threshold and status is true
if (this.myAudioStatus && finalVolume > this.threshold) {
// Only send data when volume exceeds threshold
if (finalVolume > this.threshold) {
this.port.postMessage({
type: 'micVolume',
peer_id: this.peerId,