Robert-Beier / jitsi-speaker-stats-exporter

This extension for Google Chrome exports the speaker statistics of an open jitsi room as a CSV file.
0 stars 1 forks source link

Own name and speaker time have wrong values #8

Open Robert-Beier opened 4 years ago

Robert-Beier commented 4 years ago

When using the function APP.conference.getSpeakerStats the user himself has the displayName = null and totalDominantSpeakerTime = 0, although the speaker stats you can see in jitsi show the name and dominant speaker time. So this function doesn't provide this information, but this information needs to be somewhere. We should have a look into the jitsi source code to find out how we can access it.

BuckUbel commented 4 years ago

A page reload after you typed your name avoids the problem. Another idea for the name is to look in the DOM.

Robert-Beier commented 4 years ago

I tried reloading the page. And I see my name in the statistics. But this is because Jitsi doesn't seem to recognize me as the same person. So there is a "Robert" in the statistics, which is my old session, and me. I looked at the code of the speaker stats component. For the local user, you have to get the display name will always be null, but _isLocalStats will be true. In this case we have to get the localDisplayName from another source. I used window.APP.conference.getLocalDisplayName() in the fix for this.

Robert-Beier commented 4 years ago

About the time: If you talk for a while, the dominantSpeakerTime for the local user will be > 0. The speaker stats just don't seem to be updated so often. I will reopen this issue because I think we may find a place to get the current time for the local user.