TUMFARSynchrony / SynthARium

An online tool for researchers to host and conduct customizable remote experiments with adaptable vision and audio pipelines in a multiuser setting.
GNU General Public License v3.0
30 stars 4 forks source link

Set unique key for each video #258

Closed MEnesDeniz closed 4 months ago

MEnesDeniz commented 4 months ago

https://github.com/TUMFARSynchrony/experimental-hub/issues/200

Overview

This PR updates the VideoCanvas component to assign unique keys to video elements based on their stream IDs, ensuring more reliable rendering and updates within React's virtual DOM.

Changes

The key assignment for video components within the VideoCanvas was modified to use the unique id property from each media stream, addressing issues with component re-rendering when streams change or update.

How to test?

Running a session where multiple participants join or leave, checking if video streams maintain consistent rendering without any muted participants video or error.

Checklist

gulbikeimge commented 4 months ago

Looks great, I haven't faced a black screen issue while testing!