Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix jumpy speaker tiles in spotlight mode #1906

Merged
merged 2 commits into from
Nov 20, 2023

Conversation

robintown
Copy link
Member

@robintown robintown commented Nov 20, 2023

reorderTiles was programmed to only place a tile in the speaker section if that tile's previous position was off-screen. But for speakers that started off-screen, this would cause them to oscillate in and out of the speaker section on each render, because the speaker section is, of course, on-screen. The solution I've gone with here is to avoid referencing the previous position, and instead go by the computed natural ordering, which ought to be more stable.

Closes #1222

reorderTiles was programmed to only place a tile in the speaker section if that tile's previous position was off-screen. But for speakers that started off-screen, this would cause them to oscillate in and out of the speaker section on each render, because the speaker section is, of course, on-screen. The solution I've gone with here is to avoid referencing the previous position, and instead go by the computed natural ordering, which ought to be more stable.
@codecov-commenter
Copy link

Codecov Report

All modified and coverable lines are covered by tests ✅

Comparison is base (4f17c62) 30.14% compared to head (42c8677) 24.71%.
Report is 1 commits behind head on livekit.

Additional details and impacted files
@@             Coverage Diff             @@
##           livekit    #1906      +/-   ##
===========================================
- Coverage    30.14%   24.71%   -5.44%     
===========================================
  Files           47       48       +1     
  Lines         1874     2375     +501     
  Branches       327      438     +111     
===========================================
+ Hits           565      587      +22     
- Misses        1264     1737     +473     
- Partials        45       51       +6     
Flag Coverage Δ
unittests 24.71% <100.00%> (-5.44%) ⬇️

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@robintown robintown merged commit a31d1a5 into element-hq:livekit Nov 20, 2023
6 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Glitch in tiling, in spotlight mode, when speaker has video muted
4 participants