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

Region-based Looping (a.k.a. A/B looping) utilizing videojs-abloop plugin #3904

Merged
merged 10 commits into from
Aug 24, 2023

Conversation

chickenwingavalanche
Copy link
Contributor

@chickenwingavalanche chickenwingavalanche commented Jul 11, 2023

Adds A/B looping support to the player, as requested in #3264.

I don't really love the UI elements that the plugin provides, and am open to doing something different if the maintainers have a suggestion.

  • Adds basic a/b looping functionality to the player (currently using a 3rd party plugin, videojs-abloop)
  • Adds UI elements in the player to control the a/b looping (currently, provided by the above plugin)
  • Adds a keyboard shortcut to toggle said functionality:
    • l sets the start time
    • l a second time, sets the end time and starts the looping
    • l a third time, stops the a/b loop

Screenshots of current state:
A/B looping is off, no times have been selected:
image

l has been hit twice, enabling the a/b loop:
image

Resolves #3264

chickenwingavalanche added 6 commits July 8, 2023 01:15
- buttons controlling looping added. neat.
copies mpv behavior:
if a/b loop start not yet set, sets start to current player time
elif a/b loop stop not yet set, sets end to current player time and enables loop
else, disables a/b loop

relates to #3264 (#3264)
@chickenwingavalanche chickenwingavalanche changed the title Region-based Looping (a.k.a. A/B looping) Region-based Looping (a.k.a. A/B looping) utilizing videojs-abloop plugin Jul 11, 2023
@DogmaDragon DogmaDragon added the documentation Instructions and support material label Jul 12, 2023
@WithoutPants WithoutPants added this to the Version 0.23.0 milestone Jul 31, 2023
@WithoutPants WithoutPants added the feature Pull requests that add a new feature label Jul 31, 2023
@ratbastid-1
Copy link

I was really hoping this would make 0.22. What's the chances of that build fail getting fixed by .23?

@WithoutPants
Copy link
Collaborator

I've made the display of the UI elements optional and turned off by default, since - as you mentioned - they are pretty hideous. You can enable them in the Interface settings.

@WithoutPants WithoutPants merged commit 1f3ed07 into stashapp:develop Aug 24, 2023
2 checks passed
@chickenwingavalanche
Copy link
Contributor Author

Apologies for the drive by, and thank you for carrying it over the line @WithoutPants !

halkeye pushed a commit to halkeye/stash that referenced this pull request Sep 1, 2024
…ugin (stashapp#3904)

* yarn add videojs-abloop
* add abLoop plugin to video player
* adding player keyboard shortcut 'l' for toggling a/b looping

copies mpv behavior:
if a/b loop start not yet set, sets start to current player time
elif a/b loop stop not yet set, sets end to current player time and enables loop
else, disables a/b loop

relates to stashapp#3264 (stashapp#3264)

* update help with keyboard shortcut
* Add plugin type definitions
* Make UI elements optional
---------
Co-authored-by: chickenwingavalanche <[email protected]>
Co-authored-by: WithoutPants <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
documentation Instructions and support material feature Pull requests that add a new feature
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[Feature] Region-based Looping (a.k.a. A/B looping)
4 participants