-
Notifications
You must be signed in to change notification settings - Fork 2.8k
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
image-based subtitles are stretched to video aspect ratio #14276
Comments
You're using a VOBsub subtitle. Please extract it and attach it here (both |
I'm not sure about the legality of uploading the whole .sub file here, but this is the header of the .idx:
The |
Works fine, in older version. There was logic to fit uncropped subtitles onto cropped video.
This is arguable, because we don't know how much of the video were cropped, we can assume that video should be fitted into subtitle size, but in fairness encoder should crop subtitles the same way as video. I can add an option for this, I find it useful, there are a lot of encodes that have broken subtitles, because people doesn't care. |
I changed the |
Set them to |
They look exactly the same with |
Image subtitles do not work like this. The container only declares the target video dimensions. Changing the width and height fields in the container will not change the coordinates fed to the decoder, nor the transported bitmap data. Anyway, VobSub should only carry valid DVD resolution subtitles. Why would you ever use this format for HD? |
I don't see how this is going to help me solve the issue. I just found these two options in the man page:
However, using Maybe a flag like |
Image subtitles (VobSub, DVB-Bitmap, PGS, TTML-PNG) are always generated for a given target video, out of a handful of possible standardized video formats. They can hardly be mixed with arbitrary videos that differs from the one they were supposed to be used on, or files that do not respect the constrained video format.
Not necessarily! The problem is elsewhere: most VobSub subtitles consist of full-screen, and mostly transparent, bitmaps overlaid onto the video. With non-standard video formats, mpv does not know how to manage these gigantic overlays onto a mismatched video format. The only solution is to stretch them. Image subtitles that use proper screen regions (rectangles) are generally correctly handled by mpv. Hence, the option suggested by @/kasper93 is needed for these "bad" files. |
I see, for some reason I just assumed that all image subtitles would be as small as they could be (i.e. from the top left corner to the bottom right of the subtitle). Thank you for the explanation; I didn't know about this when creating the issue. |
mpv Information
Important Information
1:0.38.0-4
screenshots
using
video-aspect-override=16:9
Reproduction Steps
To reproduce this, simply play any non-16:9 video with image-based subtitles (in my case
dvd_subtitle
) and they will appear stretched. This also happens in VLC and MPC-HC, but not in Infuse. When usingvideo-aspect-override=16:9
the subtitles are displayed correctly.Expected Behavior
Image-based subtitles should be displayed in 16:9, even when the video is a different aspect ratio.
This is what the same file looks like in Infuse:
Actual Behavior
The subtitles are stretched to the same aspect ratio as the video. See the screenshots in
Important Information
Log File
output.txt
Sample Files
No response
I carefully read all instruction and confirm that I did the following:
--log-file=output.txt
.The text was updated successfully, but these errors were encountered: