Chrome Android getUserMedia will not start playing in second Tab of published Project not using iFrame

Hello fellow PC Developers.

So I’ve noticed some weird behaviour for a published Project when testing on a phone with google Chrome.

The Method getUserMedia() which is used to get the camera of a phone doesn’t seem to be able to start playing and get a “canPlay” event when opening a published Project in a second tab with chrome, but only if the second tab is opened by pasting the same link. If you create a QR-Code of the link and scan it twice to open two tabs, everything works fine (on my pixel 6 atleast, friends have reported, that even with qr code scanning it doesn’t work with 2 tabs).

You can test this on the following project:

To replicate

  1. open the link on a mobile device (tested with a pixel 6) chrome
  2. Wait for the video feed to start
  3. Copy the link of the Project
  4. Go to the Tab selection and press the + to add a new Tab
  5. Paste the copied link

Also this behaviour only appears if I use the “/e/” in the link so that no iframe is used. If you remove the “/e/” part then it works just fine.

The thing is, you get the same media track from getUserMedia(), but somehow the video has a videoHeight and videoWidth of 0. This leads to no canPlay event being emitted.

This is problematic because when exporting a project and hosting it on a website, it is by default not embedded in an iframe.

Has anyone got any clues, as to why this might happening?

Also to mention is, that I have a synchronization using localStorage, where I disable the media stream track in other tabs. This works fine because when I have multiple tabs opened with the QR (which works on my mobile phone atleast), I can freely switch between them and it always stops the track on the other tabs and resumes it in the current tab.

And it wouldn’t make sense anyways, that it works in projects which use the iframe and doesn’t work in ones that do not use the iframe.