-
Notifications
You must be signed in to change notification settings - Fork 760
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
Voice Broadcast - Some internal improvements related to the player #7478
Voice Broadcast - Some internal improvements related to the player #7478
Conversation
19473b3
to
3fcac09
Compare
SonarCloud Quality Gate failed. |
Do the tests need to be run between 2 real devices? I tried with a physical one and an emulator and I never got it to work in real time. |
Sorry, I did several retries and I found 3 important issues:
|
It seems like issues 1 and 2 were related to long 'buffering' times (2min) before a chunk of voice broadcast is sent from the streaming device to the listeners, the UX could probably be improved, but at least we know it's working properly. I can't reproduce the 3rd issue anymore, so I guess it's quite difficult to trigger. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM. There are some UX issues around the buffering and there is a small duplication that could be addressed, but overall it works great.
It would be great if we could address the 3rd issue I mentioned about 2 streams being played at the same time, but I could only trigger it that time, so I think it's pretty difficult to reproduce.
State.PLAYING -> { | ||
if (nextMediaPlayer == null) { | ||
coroutineScope.launch { nextMediaPlayer = prepareNextMediaPlayer() } | ||
} | ||
} | ||
State.PAUSED -> { | ||
if (nextMediaPlayer == null) { | ||
coroutineScope.launch { nextMediaPlayer = prepareNextMediaPlayer() } | ||
} | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
These 2 cases could probably be merged.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Good catch, I'll change it in a new PR
Thanks for your feedback @jmartinesp 🙏🏻 , I will keep in mind your issue about the stream played twice |
Type of change
Content
Motivation and context
Consolidate the code base of the voice broadcast player
Screenshots / GIFs
Tests
Tested devices
Checklist