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

Change video captions #5479

Closed
thumaman opened this issue Apr 25, 2024 · 20 comments · Fixed by #5609
Closed

Change video captions #5479

thumaman opened this issue Apr 25, 2024 · 20 comments · Fixed by #5609
Assignees
Labels
Type: Feature ⚙ Request or idea for a new feature.
Milestone

Comments

@thumaman
Copy link

Is there a way of changing captions of the video with custom buttons. What I mean by that is, I want to make my own button that displays available captions and by selecting them, they get updated in the video player.

I want this so that i can position and style my own buttons and menus with captions and make my application more customizable.

@thumaman thumaman added the Type: Feature ⚙ Request or idea for a new feature. label Apr 25, 2024
@stsrki
Copy link
Collaborator

stsrki commented Apr 25, 2024

This should be possible with the ControlsList parameter, which accepts an array of strings. The strings are, by default, the predefined names of the controls, but you should be able to define a custom name.

Here are some resources online that might help you to grasp it. Note they are for JS version but they should still apply

@thumaman
Copy link
Author

So if I understand correctly I can define a custom control that can then be used to change the captions of the current video?

@thumaman
Copy link
Author

Is it possible to do it all with C# and not use any JS?

@stsrki
Copy link
Collaborator

stsrki commented Apr 30, 2024

At the moment, it is not possible.

@thumaman
Copy link
Author

Then I think it would be a useful feature to have since it is more independent and faster than JS, I would suggest the current player to have a currentTrack field which can then be used to change the video track of the player.

@stsrki
Copy link
Collaborator

stsrki commented Apr 30, 2024

Can you explain the proposed API and how it could be used?

@thumaman
Copy link
Author

thumaman commented Apr 30, 2024

I would have the Video have an attribute called currentTrack which would be initially set to null or the Default value of Tracks array.
Then a user could make a custom menu or use the one currently generated from Tracks which when clicking on a certain subtitle would change the visibility of the desired track from hidden/disabled to showing, thus displaying the track along with the video.

It could be used so the user could create a custom menu outside the video player with which he/she could manipulate the player and create a more customizable environment.

I hope I explained it well, if not let me know :)

image

@thumaman
Copy link
Author

thumaman commented May 8, 2024

Will that functionality ever be supported in the upcoming weeks? :)

@stsrki
Copy link
Collaborator

stsrki commented May 9, 2024

Possibly yes. But it depends on the complexity. We also plan to migrate to the newer version of the video library so we need to be careful with adding too many features. In case they are not supported by this new library.

@stsrki
Copy link
Collaborator

stsrki commented May 9, 2024

Ps. #4914

@thumaman
Copy link
Author

I understand. If possible I would also suggest that the Video has a Volume attribute, enabling a programmer to make a custom button/slider to manipulate with the volume of the player.

@thumaman
Copy link
Author

Is there any more information on updating the video player/having customizable controls such as subtitles?

@stsrki
Copy link
Collaborator

stsrki commented May 30, 2024

Sorry, not yet planned. I could move it to the next milestone but there are still other work to do first.

In case you wish to help we're always open to contributions.

@stsrki stsrki added this to the 1.6 milestone May 30, 2024
@stsrki stsrki self-assigned this May 30, 2024
@thumaman
Copy link
Author

That would be much appreciated.

Unfortunately I am very busy at the moment and probably will not be able to contibute to your project.

@stsrki
Copy link
Collaborator

stsrki commented Jul 4, 2024

#4914 (comment)

@thumaman
Copy link
Author

Hi, are there any updates on the video player and changing the subtitles? Also are there any plans to change the plyr anytime soon to a more modern player?
Thanks for the answes!

@stsrki
Copy link
Collaborator

stsrki commented Jul 12, 2024

We're updating the video to a new version, and we will try to make it by 1.6 release. Regarding this particular feature it all depends on how complex it might be with the new library.

@thumaman
Copy link
Author

That is great to hear!
Do you have any idea approximately when the 1.6 version will be released?

@stsrki
Copy link
Collaborator

stsrki commented Jul 12, 2024

It's planned for July 23rd.

@thumaman
Copy link
Author

Great, thanks for the replies :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Type: Feature ⚙ Request or idea for a new feature.
Projects
Archived in project
Development

Successfully merging a pull request may close this issue.

2 participants