Mute unmute video issue

Hi there! Have a problem with unmute for video tracks. For audio everything works fine. In documentation i couldn’t find solution of this problem. Or somebody can show me the best to mute and unmute audio/video tracks?

What API are you using? iframe, lib-jitsi-meet?

lib-jitsi-meet

@saghul little update. This issue appear only when i unmute my local video. Another participants can see me after unmute

Can you paste your unmute code here?

@iDLE i’m using Vue.js in my project. Maybe after unmute i should do something else but on another hand participants after unmute see me

mute() {
      this.room.getLocalTracks().forEach((track) => {
        if (!track.isMuted()) {
          track.mute();
        }
      });
    },
    unmute() {
      this.room.getLocalTracks().forEach((track) => {
        if (track.isMuted()) {
          track.unmute();
        }
      });
  1. try remove current state check
  1. before mute add event listener and try debug here

this.room.getLocalTracks().addEventListener(
this.JitsiMeetJS.events.track.TRACK_MUTE_CHANGED,
(track) => {
if (track.isMuted())
console.log(track.getType() + " muted");
});

@iDLE i did like that and track was muted. I think problem with wrong attaching after unmute

Do you mean you did solved the problem?

@iDLE suddenly no. I still can’t see local video after unmute

It’s normal. you can’t see your image when you unmute.

If you want “mute+see my video”, you should call removeTrack

for (let i = 0; i < this.localTracks.length; i++) {
this.jitsiRoom.removeTrack(this.localTracks[i]);
}

@iDLE oh, if i understood correctly. When i want to turn on my video after mute i should delete old local tracks and create new one’s?

for example:

  1. mute local tracks
  2. remove local tracks
  3. create new tracks

?

you should not call mute in your case.

  1. remove local tracks(when you need your “mute”)
  2. add local tracks(when you need your “unmute”)

That’s all. :hugs:

@iDLE Thank you! but in case of live conference what the best practice for mute and unmute?

Because others can’t see your image, you also don’t need your image.
We need our image because “how will they look me? Ain’t too ugly? :see_no_evil:
As long as they don’t see your image, why need it?

Mute is enough, I think.

@iDLE clear. Thank you!

1 Like