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 editor not playing audio due to video order #1376

Merged
merged 1 commit into from
Aug 16, 2024

Conversation

Arnei
Copy link
Member

@Arnei Arnei commented Jun 3, 2024

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.

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.
@Arnei Arnei added the type:bug Something isn't working label Jun 3, 2024
Copy link

github-actions bot commented Jun 3, 2024

This pull request is deployed at test.editor.opencast.org/1376/2024-06-03_07-55-19/ .
It might take a few minutes for it to become available.

@snoesberger
Copy link
Contributor

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.

@Arnei
Copy link
Member Author

Arnei commented Jun 6, 2024

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.

@snoesberger
Copy link
Contributor

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).

@snoesberger
Copy link
Contributor

I'd love to see this PR merged. Or is there still something preventing it from being merged?

@Arnei
Copy link
Member Author

Arnei commented Aug 12, 2024

This still needs a formal review I'd say.

Copy link
Contributor

@snoesberger snoesberger left a 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.

@Arnei Arnei merged commit 2cd2bad into opencast:main Aug 16, 2024
8 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
type:bug Something isn't working
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants