-
Notifications
You must be signed in to change notification settings - Fork 43
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 editor not playing audio due to video order #1376
Conversation
If the editor has multiple videos, it will consider one of them the "primary" video, from which it will play back audio. Even if that "primary" video does not have any audio. This changes the logic so that the first video with audio the editor comes across is made the "primary" video, so that there should always be audio playing if audio is available.
This pull request is deployed at test.editor.opencast.org/1376/2024-06-03_07-55-19/ . |
I tested it with a dual stream recording where I had problems before. I can now hear the audio in the cutting section of the editor, but I still have the problem in the preview player of the subtitles section. |
The video player in the subtitle section should be completely unaffected by this change. The subtitle section only displays one video at a time and thus, only the audio from the currently selected video is played. If the video has no audio, then no audio will be played. Not sure if this can be fixed, but this PR at least is not trying to do anything about it, so I would consider it a separate issue. |
You are right, this makes sense. But I can see how it might be confusing for some of our users. But for now, let's leave it as you suggested (and rethink if there's a better way to handle this, I have opened the following issue for that: #1380). |
I'd love to see this PR merged. Or is there still something preventing it from being merged? |
This still needs a formal review I'd say. |
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.
As GitHub Actions has already discovered, selectVideoURL is no longer used and could be removed from the import.
Otherwise, the code changes look reasonable to me, and my tests with different dual stream recordings were successful.
If the editor has multiple videos, it will consider one of them the "primary" video, from which it will play back audio. Even if that "primary" video does not have any audio.
This changes the logic so that the first video with audio the editor comes across is made the "primary" video, so that there should always be audio playing if audio is available.