sofie-core
sofie-core copied to clipboard
feat: Implement QuickLoop (SOFIE-2878)
About the Contributor
This pull request is posted on behalf of the BBC.
Type of Contribution
This is a:
Feature
Current Behavior
Currently Sofie allows looping of an entire Rundown Playlist. Whether the playlist should be looping can only be set by the Blueprints (usually done according to properties coming from the NRCS).
New Behavior
What it does:
- The QuickLoop feature enables users to define a looping section within Rundown Playlists using Start and End markers.
- Automatically loops between a designated section.
How to use it:
-
Set Markers:
- Right-click on a part within the Rundown Playlist.
- Choose "Set as QuickLoop Start" or "Set as QuickLoop End" from the context menu.
-
Activate QuickLoop:
- QuickLoop mode will automatically trigger when any part between the Start and End markers is taken.
- If configured, parts within the QuickLoop will progress automatically.
-
Modify the QuickLoop:
- Set new markers (by context-clicking) to extend or shorten the QuickLoop section.
- Execute adlibs without interrupting the QuickLoop.
- Ensure logical marker placement to prevent errors.
-
Exit QuickLoop Mode:
- Clear the markers using the context menu, or set a part outside of the QuickLoop as Next.
- Playback continues seamlessly after exiting QuickLoop Mode.
Deviations from the RFC, and some more details:
- A Rundown Playlist with user-defined QuickLoop has similar indication in the Lobby and Rundown View as a looping Playlist.
- Setting a Start marker on a part after the End marker results in clearing the End marker, and vice versa.
- Clearing/exiting the QuickLoop by the use of a hotkey or AdLib Action is not implemented.
- The following settings are available in the Generic properties of a Studio:
- Enable QuickLoop (enables QuickLoop context menu options, but doesn't affect Playlist looping enabled by the NRCS/blueprints)
-
Force Auto in a Loop, with three available options:
- Disabled (default - consistent with existing Playlist loop behaviour)
- Enabled, but skipping parts with undefined or 0 duration
- Enabled on all Parts, applying QuickLoop Fallback Part Duration if needed
- QuickLoop Fallback Part Duration
- The QuickLoop section is indicated as shown below
Testing Instructions
Setting and Clearing Markers:
- Open Sofie GUI and navigate to a Rundown Playlist that does not have looping enabled by the NRCS.
- Right-click on a Part (as long as it is not marked as invalid) and verify that you can set a Start marker.
- Right-click on another Part (as long as it is not marked as invalid) and set the End marker.
- Ensure that setting a Start marker after the End marker will clear the previous End marker, and vice versa.
- Verify that you can clear the Start and End markers from the context menu.
- Test that setting the Start and End markers on the same Part creates a single-part loop.
Loop Mode Functionality:
- Set the Start and End markers within a Rundown Playlist.
- Take a Part within the defined loop section.
- Verify that the Loop Mode is triggered and subsequent Parts progress automatically.
- Check that Parts within the loop show the AUTO indicator in the GUI.
- Ensure that when the end of the loop is reached, the first item in the loop becomes Next and an Auto Take occurs.
- Test exiting the Loop Mode using the dedicated hotkey, AdLib Action, or context menu item.
- Confirm that played adlibs are removed each time the loop starts over.
- Verify behavior when a dynamic part is inserted while playing the End part of the loop.
- Test for Parts with a duration of 0 seconds or undefined within the looping section and verify the default behavior or any custom settings applied.
- Check that all Parts outside of the loop are dimmed but retain functionality.
- Verify the indication showing that the Loop Mode is active.
Additional Scenarios:
- Test setting Start/End markers on different Parts to modify the looping section in the Loop Mode.
- Verify that setting a Part outside of the looping section as Next and taking it exits the Loop Mode.
- Ensure that ingest operations altering the order of Segments and Parts or removing Parts containing markers stop the Loop Mode and delete the markers.
- Test ingest operations hiding the Segment containing marked parts and verify Loop Mode behavior.
Testing Instructions for Studio Settings:
Enable QuickLoop:
- Verify that enabling QuickLoop in the Studio settings enables corresponding context menu options.
Force Auto in a Loop:
- Test each option for "Force Auto in a Loop" to ensure they behave as described:
- Verify that the "Disabled" option maintains consistency with existing Playlist loop behavior, not applying auto-next.
- Validate the behavior of the "Enabled, but skipping parts with undefined or 0 duration" option.
- Confirm that the "Enabled on all Parts, applying QuickLoop Fallback Part Duration if needed" option functions correctly.
QuickLoop Fallback Part Duration:
- Verify that the QuickLoop Fallback Part Duration setting is applied appropriately in conjunction with corresponding Force Auto in a Loop value.
Regression testing instructions for the existing Playlist Looping Feature:
- Validate that existing Blueprints continue to function without requiring modifications for Playlist looping.
- Verify that Playlist looping enabled by the NRCS/Blueprints functions as expected and is indicated in the GUI as it used to be.
- Confirm that Start and End markers are correctly locked to the Playlist start and end and the user can not override them.
Other Information
Status
- [x] PR is ready to be reviewed.
- [x] The functionality has been tested by the author.
- [x] Relevant unit tests has been added / updated.
- [x] Relevant documentation (code comments, system documentation) has been added / updated.
Codecov Report
Attention: Patch coverage is 41.11628%
with 1266 lines
in your changes missing coverage. Please review.
Project coverage is 57.42%. Comparing base (
fdb4a25
) to head (0d1b890
). Report is 6 commits behind head on release51.
Additional details and impacted files
@@ Coverage Diff @@
## release51 #1112 +/- ##
=============================================
- Coverage 57.89% 57.42% -0.48%
=============================================
Files 526 537 +11
Lines 84953 86584 +1631
Branches 3870 3928 +58
=============================================
+ Hits 49184 49718 +534
- Misses 35745 36835 +1090
- Partials 24 31 +7
:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.
A workshop has been held on 2024/04/12 and the contributor will still address the comments above.