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

Audio padding issue #83

Open
Geniusssmit opened this issue Nov 14, 2022 · 17 comments
Open

Audio padding issue #83

Geniusssmit opened this issue Nov 14, 2022 · 17 comments

Comments

@Geniusssmit
Copy link

Environment

  1. OS name [e.g. Parabola, Debian] win 10
  2. OS version 1809
  3. mpv version 0.35
  4. Logs
  5. Screenshots, if applicable
    image
    image

Describe the bug
A description of what the bug is.
audio_padding only works when timings for multiple lines are set by pressing "c", and not for shift+s, shift+e

Expected behavior
A description of what you expected to happen.
audio padding should work

@Geniusssmit
Copy link
Author

Motokare no Yuigonjou 2022 S01 1080p WEB-DL AAC H.264-MagicStar.zip
comparison, padding set to 1.0 (1 second)

@Geniusssmit
Copy link
Author

difference is exactly 2 seconds

@tatsumoto-ren
Copy link
Member

Padding is only applied when timings are chosen automatically. When you set them manually, no padding is applied.

@Geniusssmit
Copy link
Author

c - Interactive subtitle selection. is automatic?

@tatsumoto-ren
Copy link
Member

If you want to create a card with padding, you shouldn't use shift+s and shift+e and instead use only c and shift+l,shift+h

@Geniusssmit
Copy link
Author

I see, difference is not obvious tbh, but ok, also do you know why it cuts audio, even if subtitle is still shown. I ended up with 1.0 padding, but thats quite big

@tatsumoto-ren
Copy link
Member

When you override timings set in the subtitles, mpvacious assumes that your subs are incorrectly timed, and disables the padding since applying it would mean potentially grabbing extra parts of the dialogue that you don't want on your card.

@tatsumoto-ren
Copy link
Member

I ended up with 1.0 padding

Could be your subtitle's timings, or the amount of padding you set in subs2srs.conf.

@Geniusssmit
Copy link
Author

When you override timings set in the subtitles, mpvacious assumes that your subs are incorrectly timed, and disables the padding since applying it would mean potentially grabbing extra parts of the dialogue that you don't want on your card.

I understand that. I mean I check, timings are perfect, even without overriding mpvacious cuts before subtitle disappears.

@Geniusssmit
Copy link
Author

that's why I'm using 1.0 padding to compensate it

@Geniusssmit
Copy link
Author

but yeah, anyway "c" key works just fine.

@Geniusssmit
Copy link
Author

Bandicam 2022-11-14 19-57-05-276-1.zip
Please watch, it cuts 4 seconds earlier, even with "c"

@tatsumoto-ren
Copy link
Member

that's why I'm using 1.0 padding to compensate it

You're better off fixing the timings then.

Please watch, it cuts 4 seconds earlier, even with "c"

On the video you still set the timing manually.

@Geniusssmit
Copy link
Author

that's why I'm using 1.0 padding to compensate it

You're better off fixing the timings then.

Please watch, it cuts 4 seconds earlier, even with "c"

On the video you still set the timing manually.

I mean, as you can see, automatically it sets end timing to 07m30s200ms, but when I fix it manually, I set it when the line ends, it ends around 07m34s186ms

@Geniusssmit
Copy link
Author

image
I think there is something wrong with the subtitle file, do you know how to deal with cases like this? 2 exact same lines with different timings
[MagicStar] Motokare no Yuigonjou EP04 [WEBDL] [1080p].zip

@tatsumoto-ren
Copy link
Member

This could help. You can also open the file in vim and remove the redundant lines.

@tomtung
Copy link

tomtung commented Aug 23, 2023

I also found this behavior really confusing: padding is only respected for single-line selection, but somehow not for multiple-line selection. I needed to spend some time debugging to figure out what was going on.

When you override timings set in the subtitles, mpvacious assumes that your subs are incorrectly timed, and disables the padding

I think this behavior is only expected when the user directly sets the timestamps without referencing the exact timing of the current subs. I only use shift+s and shift+e when the subs are already correctly timed, and I need to select a range of them. In this case, this behavior is definitely a surprise for me.

If you want to create a card with padding, you shouldn't use shift+s and shift+e and instead use only c and shift+l,shift+h

This is probably the best option. I didn't try it before because it seemed less intuitive than shift+s and shift+e.

Alternatively, just locally comment out these lines.

mpvacious/subs2srs.lua

Lines 331 to 333 in 178674f

if subs_observer.user_altered() then
return 0.0
end

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants