Opened 4 months ago
#11140 new defect
Subtitles blended into chroma-subsampled video contain unintended stripes
Reported by: | Oneric | Owned by: | |
---|---|---|---|
Priority: | normal | Component: | avfilter |
Version: | git-master | Keywords: | subtitles ass |
Cc: | Blocked By: | ||
Blocking: | Reproduced by developer: | no | |
Analyzed by developer: | no |
Description
I’m forwarding this from https://github.com/libass/libass/issues/816
I was able to reproduce this myself using ffmpeg 719e46f54c0f3ea557503ec4cd5618332484f78a but it also occured on older versions too; if this is a regression then not a too recent one.
When subs are blended by the subtitles/ass videofilter the sub overlay bitmaps appear to get truncated to the video format’s chroma plane resolution individually. This can cause issues e.g. with neighbouring sub bitmaps whose border lies within a subsampled chroma pixel which will be visible as jarring stripes. Those stripes are not present in video players or authoring tools.
One possible fix is to first blend all subtitles into a single non-subsampled RGBA surface and then convert this overlay as a whole to the video’s format and blended onto the video frame.
Atm users can and must workaround stripes by first forcing the input video to be converted to yuv444 or similar and then later convert back to the desired format, e.g. yuv420
subs_to_be_blended_with_1080p_video_see_at_2s.ass