mpv-player / mpv-player/mpv

A/B Loop range should reset on new file

Open
#17,953 6 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

meta:feature-request
Dominant language
C
Stars
37k
Forks
3.5k
Avg merge
1d 10h
Merged PRs (30d)
22

Description

Expected behavior of the wanted feature

I've discussed this with @kasper93 on irc.

Currently mpv retains A/B loop range, even when a new file starts, I believe this behavior was overlooked, as it doesn't make sense to have the same loop range for different files.

As I've explained on irc, there might be a use case that made the behavior initially like this, I don't use this option often.

This originated from: https://github.com/Samillion/ModernZ/issues/724#issuecomment-4349574387

Alternative behavior of the wanted feature

Instead of plainly resetting A/B loop range on each file start, it can be tied to an option whether to keep it or reset it on file events.

Just in case there is a useful reason why it was kept and not reset between files.

Log File

N/A

Sample Files

N/A

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

The issue names no files or tests. Start by locating the A/B loop state and the file-start event handling, then verify how the range is retained across files. Done means the range resets when a new file starts, with behavior covered by an appropriate regression test; consider the optional-preservation alternative only if existing behavior has a documented use.

Written by the indexing model from the issue text.

Assessment

Tech stack
c
Domain
cli
Issue type
Feature
Difficulty
3/5
Estimated time
1-2 days
Activity status
Quiet
Clarity
Mostly clear
Newbie friendliness
48/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.