Eisa01 / mpv-scripts

This repository contain scripts I have made for mpv media player...

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

UndoRedo: Handle more than 1x speed

AziRizvi opened this issue · comments

The behaviour of UndoRedo is very weird. (Not sure if I'm using it wrong, or there are bugs in the script)
Script Version: 2.2
MPV Version: v0.37.0-6-g5220725c (Shinchiro's Build)

By default, all my videos start playing at 2.35x playback speed because I've set that up in my mpv.conf.

Now to the issue.
Let's say I open a video and it starts playing and let's say it was at 19 seconds in the video when I "accidentally" clicked somewhere on the timeline/seekbar.

When I press Ctrl+Z, it should go back to 19 seconds, correct? But it doesn't.

Here's a short clip. (When the video that I was playing at was at 19 seconds, I clicked on the timeline/seekbar at 45 seconds, then I pressed ctrl+z to undo and instead of going back to 19 seconds, it went back to 7 seconds.)

2023-12-02.17-17-23.mp4

Now to the 2nd issue:

Another issue is, If I keep pressing Ctrl+Alt+Z to keep performing undo and redo between the original position and the position that I clicked at, every time I hit ctrl+alt+z it keeps taking the video back a few milliseconds.

When the video was at 17 seconds, I clicked at 41 seconds and then I pressed Ctrl+Alt+Z and every time I press Ctrl+Alt+Z both the "undo" and the "redo" points in the video keep going back a few milliseconds.

2023-12-02.17-23-34.mp4

Ah, seems like the script doesn't handle videos with more than 1x speed.
Try the 1x speed and let me know if the issue is still there.

Also for the milliseconds, it is by design. I need to make it optional in user config.

Ah, seems like the script doesn't handle videos with more than 1x speed. Try the 1x speed and let me know if the issue is still there.

Also for the milliseconds, it is by design. I need to make it optional in user config.

I just tried to undo with 1x playback speed and that worked just fine and it sent it back to the correct position, just doesn't work with higher playback speeds.